Move ModifyAncients together with other AncientWriter methods
This commit is contained in:
parent
ff4f8d9115
commit
0a5d3bf5ec
@ -31,10 +31,6 @@ type DatabaseClient struct {
|
|||||||
client *rpc.Client
|
client *rpc.Client
|
||||||
}
|
}
|
||||||
|
|
||||||
func (d *DatabaseClient) ModifyAncients(f func(ethdb.AncientWriteOp) error) (int64, error) {
|
|
||||||
return 0, errNotSupported
|
|
||||||
}
|
|
||||||
|
|
||||||
// NewDatabase returns a ethdb.Database interface
|
// NewDatabase returns a ethdb.Database interface
|
||||||
func NewDatabaseClient(url string) (ethdb.Database, error) {
|
func NewDatabaseClient(url string) (ethdb.Database, error) {
|
||||||
rpcClient, err := rpc.Dial(url)
|
rpcClient, err := rpc.Dial(url)
|
||||||
@ -208,6 +204,12 @@ func (d *DatabaseClient) ReadAncients(fn func(ethdb.AncientReader) error) (err e
|
|||||||
return fn(d)
|
return fn(d)
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// ModifyAncients satisfies the ethdb.AncientWriter interface.
|
||||||
|
// ModifyAncients runs a write operation on the ancient store.
|
||||||
|
func (d *DatabaseClient) ModifyAncients(f func(ethdb.AncientWriteOp) error) (int64, error) {
|
||||||
|
return 0, errNotSupported
|
||||||
|
}
|
||||||
|
|
||||||
// TruncateHead satisfies the ethdb.AncientWriter interface.
|
// TruncateHead satisfies the ethdb.AncientWriter interface.
|
||||||
// TruncateHead discards all but the first n ancient data from the ancient store.
|
// TruncateHead discards all but the first n ancient data from the ancient store.
|
||||||
func (d *DatabaseClient) TruncateHead(n uint64) error {
|
func (d *DatabaseClient) TruncateHead(n uint64) error {
|
||||||
|
Loading…
Reference in New Issue
Block a user