fix: [2.6] Increase the random suffix of the import test collection name (#45855)

issue: #45853 
master pr: #45854

---------

Signed-off-by: Cai Zhang <cai.zhang@zilliz.com>
This commit is contained in:
cai.zhang 2025-11-27 10:09:07 +08:00 committed by GitHub
parent cbb79dae8c
commit 1a2c21205d
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
7 changed files with 12 additions and 12 deletions

View File

@ -47,7 +47,7 @@ func (s *BulkInsertSuite) runTestAutoID() {
ctx, cancel := context.WithTimeout(c.GetContext(), 240*time.Second)
defer cancel()
collectionName := "TestBulkInsert" + funcutil.GenRandomStr()
collectionName := "TestBulkInsert" + funcutil.RandomString(8)
var schema *schemapb.CollectionSchema
fieldSchema1 := &schemapb.FieldSchema{FieldID: 100, Name: "id", DataType: s.pkType, TypeParams: []*commonpb.KeyValuePair{{Key: common.MaxLengthKey, Value: "128"}}, IsPrimaryKey: true, AutoID: true}

View File

@ -62,7 +62,7 @@ func (s *BulkInsertSuite) PrepareSourceCollection(dim int, dmlGroup *DMLGroup) *
defer cancel()
c := s.Cluster
collectionName := "TestBinlogImport_A_" + funcutil.GenRandomStr()
collectionName := "TestBinlogImport_A_" + funcutil.RandomString(8)
schema := integration.ConstructSchemaOfVecDataTypeWithStruct(collectionName, dim, true)
marshaledSchema, err := proto.Marshal(schema)
@ -297,7 +297,7 @@ func (s *BulkInsertSuite) runBinlogTest(dmlGroup *DMLGroup) {
return num
})
collectionName := "TestBinlogImport_B_" + funcutil.GenRandomStr()
collectionName := "TestBinlogImport_B_" + funcutil.RandomString(8)
schema := integration.ConstructSchema(collectionName, dim, true)
marshaledSchema, err := proto.Marshal(schema)
@ -482,7 +482,7 @@ func (s *BulkInsertSuite) TestInvalidInput() {
c := s.Cluster
ctx := c.GetContext()
collectionName := "TestBinlogImport_InvalidInput_" + funcutil.GenRandomStr()
collectionName := "TestBinlogImport_InvalidInput_" + funcutil.RandomString(8)
schema := integration.ConstructSchema(collectionName, dim, true)
marshaledSchema, err := proto.Marshal(schema)
s.NoError(err)

View File

@ -48,7 +48,7 @@ func (s *BulkInsertSuite) testImportDynamicField() {
ctx, cancel := context.WithTimeout(c.GetContext(), 240*time.Second)
defer cancel()
collectionName := "TestBulkInsert_B_" + funcutil.GenRandomStr()
collectionName := "TestBulkInsert_B_" + funcutil.RandomString(8)
schema := integration.ConstructSchema(collectionName, dim, true, &schemapb.FieldSchema{
FieldID: 100,

View File

@ -81,7 +81,7 @@ func (s *BulkInsertSuite) run() {
ctx, cancel := context.WithTimeout(c.GetContext(), 240*time.Second)
defer cancel()
collectionName := "TestBulkInsert" + funcutil.GenRandomStr()
collectionName := "TestBulkInsert" + funcutil.RandomString(8)
var schema *schemapb.CollectionSchema
fieldSchema1 := &schemapb.FieldSchema{FieldID: 100, Name: "id", DataType: s.pkType, TypeParams: []*commonpb.KeyValuePair{{Key: common.MaxLengthKey, Value: "128"}}, IsPrimaryKey: true, AutoID: false}
@ -288,7 +288,7 @@ func (s *BulkInsertSuite) TestZeroRowCount() {
ctx, cancel := context.WithTimeout(c.GetContext(), 60*time.Second)
defer cancel()
collectionName := "TestBulkInsert_" + funcutil.GenRandomStr()
collectionName := "TestBulkInsert_" + funcutil.RandomString(8)
schema := integration.ConstructSchema(collectionName, dim, true,
&schemapb.FieldSchema{FieldID: 100, Name: "id", DataType: schemapb.DataType_Int64, IsPrimaryKey: true, AutoID: true},

View File

@ -50,7 +50,7 @@ func (s *BulkInsertSuite) testMultipleVectorFields() {
ctx, cancel := context.WithTimeout(c.GetContext(), 600*time.Second)
defer cancel()
collectionName := "TestBulkInsert_MultipleVectorFields_" + funcutil.GenRandomStr()
collectionName := "TestBulkInsert_MultipleVectorFields_" + funcutil.RandomString(8)
schema := integration.ConstructSchema(collectionName, 0, true, &schemapb.FieldSchema{
FieldID: 100,

View File

@ -48,7 +48,7 @@ func (s *BulkInsertSuite) TestImportWithPartitionKey() {
ctx, cancel := context.WithTimeout(c.GetContext(), 240*time.Second)
defer cancel()
collectionName := "TestBulkInsert_WithPartitionKey_" + funcutil.GenRandomStr()
collectionName := "TestBulkInsert_WithPartitionKey_" + funcutil.RandomString(8)
schema := integration.ConstructSchema(collectionName, dim, true, &schemapb.FieldSchema{
FieldID: 100,
@ -218,7 +218,7 @@ func (s *BulkInsertSuite) TestImportWithAFewRows() {
ctx, cancel := context.WithTimeout(c.GetContext(), 240*time.Second)
defer cancel()
collectionName := "TestBulkInsert_WithPartitionKey_" + funcutil.GenRandomStr()
collectionName := "TestBulkInsert_WithPartitionKey_" + funcutil.RandomString(8)
schema := integration.ConstructSchema(collectionName, dim, true, &schemapb.FieldSchema{
FieldID: 100,

View File

@ -47,7 +47,7 @@ func TestGenerateJsonFileWithVectorArray(t *testing.T) {
maxArrayCapacity = 10
)
collectionName := "TestBulkInsert_VectorArray_" + funcutil.GenRandomStr()
collectionName := "TestBulkInsert_VectorArray_" + funcutil.RandomString(8)
// Create schema with StructArrayField containing vector array
schema := integration.ConstructSchema(collectionName, 0, true, &schemapb.FieldSchema{
@ -127,7 +127,7 @@ func (s *BulkInsertSuite) runForStructArray() {
ctx, cancel := context.WithTimeout(c.GetContext(), 600*time.Second)
defer cancel()
collectionName := "TestBulkInsert_VectorArray_" + funcutil.GenRandomStr()
collectionName := "TestBulkInsert_VectorArray_" + funcutil.RandomString(8)
// Create schema with StructArrayField containing vector array
schema := integration.ConstructSchema(collectionName, 0, true, &schemapb.FieldSchema{