[skip e2e]Fix segment manager typo (#13644)

Signed-off-by: godchen0212 <qingxiang.chen@zilliz.com>
This commit is contained in:
godchen 2021-12-17 22:34:42 +08:00 committed by GitHub
parent b7f987ef47
commit f4caa94ea8
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 4 additions and 4 deletions

View File

@ -113,7 +113,7 @@ type allocHelper struct {
afterCreateSegment func(segment *datapb.SegmentInfo) error
}
// allocOption allction option applies to `SegmentManager`
// allocOption allocation option applies to `SegmentManager`
type allocOption interface {
apply(manager *SegmentManager)
}
@ -173,7 +173,7 @@ func defaultCalUpperLimitPolicy() calUpperLimitPolicy {
return calBySchemaPolicy
}
func defaultAlocatePolicy() AllocatePolicy {
func defaultAllocatePolicy() AllocatePolicy {
return AllocatePolicyV1
}
@ -196,7 +196,7 @@ func newSegmentManager(meta *meta, allocator allocator, opts ...allocOption) *Se
helper: defaultAllocHelper(),
segments: make([]UniqueID, 0),
estimatePolicy: defaultCalUpperLimitPolicy(),
allocPolicy: defaultAlocatePolicy(),
allocPolicy: defaultAllocatePolicy(),
segmentSealPolicies: defaultSegmentSealPolicy(), // default only segment size policy
channelSealPolicies: []channelSealPolicy{}, // no default channel seal policy
flushPolicy: defaultFlushPolicy(),

View File

@ -56,7 +56,7 @@ func TestManagerOptions(t *testing.T) {
})
t.Run("test withAllocPolicy", func(t *testing.T) {
opt := withAllocPolicy(defaultAlocatePolicy())
opt := withAllocPolicy(defaultAllocatePolicy())
assert.NotNil(t, opt)
// manual set nil
segmentManager.allocPolicy = nil