Remove unused fields from remoteCursor (#1437)

This commit is contained in:
Artem Vorotnikov 2021-01-09 08:29:04 +03:00 committed by GitHub
parent e6f1e43e6f
commit f7c5ac42d2
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -62,9 +62,7 @@ type remoteTx struct {
type remoteCursor struct {
initialized bool
id uint32
prefetch uint32
ctx context.Context
prefix []byte
stream remote.KV_TxClient
tx *remoteTx
bucketName string
@ -268,12 +266,10 @@ func (tx *remoteTx) Rollback() {
}
func (c *remoteCursor) Prefix(v []byte) Cursor {
c.prefix = v
return c
}
func (c *remoteCursor) Prefetch(v uint) Cursor {
c.prefetch = uint32(v)
return c
}
@ -600,11 +596,6 @@ func (tx *remoteTx) CursorDupSort(bucket string) CursorDupSort {
return &remoteCursorDupSort{remoteCursor: tx.Cursor(bucket).(*remoteCursor)}
}
func (c *remoteCursorDupSort) Prefetch(v uint) Cursor {
c.prefetch = uint32(v)
return c
}
//func (c *remoteCursorDupSort) initCursor() error {
// if c.initialized {
// return nil