diff --git a/ingest/op.go b/ingest/op.go index 754d4e4e2..99d47eeed 100644 --- a/ingest/op.go +++ b/ingest/op.go @@ -703,7 +703,7 @@ func (r *Request) ByShard(fields map[string]FieldType) (*ShardedRequest, error) // merge combines the components of a sharded request back into a single // unsharded request, processing shards in numerical order. -func (s *ShardedRequest) Merge() *Request { +func (s *ShardedRequest) merge() *Request { req := &Request{} if s == nil || len(s.Ops) == 0 { return req diff --git a/ingest/op_test.go b/ingest/op_test.go index db3b5981e..1646e8993 100644 --- a/ingest/op_test.go +++ b/ingest/op_test.go @@ -12,30 +12,29 @@ // See the License for the specific language governing permissions and // limitations under the License. -package ingest_test +package ingest import ( "math/rand" "testing" - "github.com/molecula/featurebase/v2/ingest" "github.com/molecula/featurebase/v2/shardwidth" ) type opShardingTestCase struct { name string - input *ingest.Request - output *ingest.ShardedRequest + input *Request + output *ShardedRequest } var opShardingTestCases = []opShardingTestCase{ { name: "sample", - input: &ingest.Request{ - Ops: []*ingest.Operation{ + input: &Request{ + Ops: []*Operation{ { - OpType: ingest.OpSet, - FieldOps: map[string]*ingest.FieldOperation{ + OpType: OpSet, + FieldOps: map[string]*FieldOperation{ "shard0": { RecordIDs: []uint64{0, 1}, }, @@ -54,9 +53,9 @@ var opShardingTestCases = []opShardingTestCase{ }, }, { - OpType: ingest.OpRemove, + OpType: OpRemove, Seq: 1, - FieldOps: map[string]*ingest.FieldOperation{ + FieldOps: map[string]*FieldOperation{ "shard0-2": { RecordIDs: []uint64{1, 2<