@zilliz/milvus2-sdk-node 2.1.2 → 2.2.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (47) hide show
  1. package/README.md +29 -40
  2. package/dist/milvus/Collection.d.ts +65 -11
  3. package/dist/milvus/Collection.js +111 -35
  4. package/dist/milvus/Collection.js.map +1 -1
  5. package/dist/milvus/Data.d.ts +71 -13
  6. package/dist/milvus/Data.js +153 -50
  7. package/dist/milvus/Data.js.map +1 -1
  8. package/dist/milvus/MilvusIndex.d.ts +5 -1
  9. package/dist/milvus/MilvusIndex.js +11 -9
  10. package/dist/milvus/MilvusIndex.js.map +1 -1
  11. package/dist/milvus/Partition.d.ts +10 -6
  12. package/dist/milvus/Partition.js +15 -11
  13. package/dist/milvus/Partition.js.map +1 -1
  14. package/dist/milvus/User.d.ts +3 -3
  15. package/dist/milvus/User.js +10 -10
  16. package/dist/milvus/User.js.map +1 -1
  17. package/dist/milvus/const/ErrorReason.d.ts +4 -1
  18. package/dist/milvus/const/ErrorReason.js +3 -0
  19. package/dist/milvus/const/ErrorReason.js.map +1 -1
  20. package/dist/milvus/index.d.ts +3 -1
  21. package/dist/milvus/index.js +33 -5
  22. package/dist/milvus/index.js.map +1 -1
  23. package/dist/milvus/types/Collection.d.ts +16 -8
  24. package/dist/milvus/types/Common.d.ts +12 -1
  25. package/dist/milvus/types/Common.js +10 -1
  26. package/dist/milvus/types/Common.js.map +1 -1
  27. package/dist/milvus/types/Data.d.ts +22 -8
  28. package/dist/milvus/types/Index.d.ts +7 -6
  29. package/dist/milvus/types/Partition.d.ts +5 -4
  30. package/dist/milvus/types/Response.d.ts +45 -1
  31. package/dist/milvus/types/Response.js.map +1 -1
  32. package/dist/milvus/types/Search.d.ts +13 -10
  33. package/dist/milvus/types/User.d.ts +6 -3
  34. package/dist/milvus/types.js +5 -1
  35. package/dist/milvus/types.js.map +1 -1
  36. package/dist/milvus/utils/Format.js +14 -10
  37. package/dist/milvus/utils/Format.js.map +1 -1
  38. package/dist/milvus/utils/index.d.ts +1 -1
  39. package/dist/proto/proto/common.proto +71 -33
  40. package/dist/proto/proto/google/protobuf/descriptor.proto +17 -19
  41. package/dist/proto/proto/milvus.proto +293 -82
  42. package/dist/proto/proto/schema.proto +10 -2
  43. package/dist/sdk.json +1 -1
  44. package/dist/utils/index.d.ts +1 -1
  45. package/dist/utils/index.js +12 -7
  46. package/dist/utils/index.js.map +1 -1
  47. package/package.json +10 -10
@@ -1,7 +1,7 @@
1
1
  syntax = "proto3";
2
2
  package milvus.proto.common;
3
3
 
4
- option go_package="github.com/milvus-io/milvus/internal/proto/commonpb";
4
+ option go_package="github.com/milvus-io/milvus-proto/go-api/commonpb";
5
5
 
6
6
  option java_multiple_files = true;
7
7
  option java_package = "io.milvus.grpc";
@@ -57,6 +57,14 @@ enum ErrorCode {
57
57
  ListPolicyFailure = 44;
58
58
  NotShardLeader = 45;
59
59
  NoReplicaAvailable = 46;
60
+ SegmentNotFound = 47;
61
+ ForceDeny = 48;
62
+ RateLimit = 49;
63
+ NodeIDNotMatch = 50;
64
+
65
+ // Service availability.
66
+ // NA: Not Available.
67
+ DataCoordNA = 100;
60
68
 
61
69
  // internal error code.
62
70
  DDRequestRace = 1000;
@@ -68,6 +76,7 @@ enum IndexState {
68
76
  InProgress = 2;
69
77
  Finished = 3;
70
78
  Failed = 4;
79
+ Retry = 5;
71
80
  }
72
81
 
73
82
  enum SegmentState {
@@ -101,26 +110,26 @@ message Blob {
101
110
  }
102
111
 
103
112
  enum PlaceholderType {
104
- None = 0;
105
- BinaryVector = 100;
106
- FloatVector = 101;
113
+ None = 0;
114
+ BinaryVector = 100;
115
+ FloatVector = 101;
107
116
  }
108
117
 
109
118
  message PlaceholderValue {
110
- string tag = 1;
111
- PlaceholderType type = 2;
112
- // values is a 2d-array, every array contains a vector
113
- repeated bytes values = 3;
119
+ string tag = 1;
120
+ PlaceholderType type = 2;
121
+ // values is a 2d-array, every array contains a vector
122
+ repeated bytes values = 3;
114
123
  }
115
124
 
116
125
  message PlaceholderGroup {
117
- repeated PlaceholderValue placeholders = 1;
126
+ repeated PlaceholderValue placeholders = 1;
118
127
  }
119
128
 
120
129
 
121
130
  message Address {
122
- string ip = 1;
123
- int64 port = 2;
131
+ string ip = 1;
132
+ int64 port = 2;
124
133
  }
125
134
 
126
135
  enum MsgType {
@@ -137,6 +146,7 @@ enum MsgType {
137
146
  CreateAlias = 108;
138
147
  DropAlias = 109;
139
148
  AlterAlias = 110;
149
+ AlterCollection = 111;
140
150
 
141
151
 
142
152
  /* DEFINITION REQUESTS: PARTITION */
@@ -185,6 +195,9 @@ enum MsgType {
185
195
  WatchDeltaChannels = 513;
186
196
  GetShardLeaders = 514;
187
197
  GetReplicas = 515;
198
+ UnsubDmChannel = 516;
199
+ GetDistribution = 517;
200
+ SyncDistribution = 518;
188
201
 
189
202
  /* DATA SERVICE */
190
203
  SegmentInfo = 600;
@@ -229,6 +242,7 @@ message MsgBase {
229
242
  int64 msgID = 2;
230
243
  uint64 timestamp = 3;
231
244
  int64 sourceID = 4;
245
+ int64 targetID = 5;
232
246
  }
233
247
 
234
248
  enum DslType {
@@ -248,9 +262,9 @@ message DMLMsgHeader {
248
262
  }
249
263
 
250
264
  enum CompactionState {
251
- UndefiedState = 0;
252
- Executing = 1;
253
- Completed = 2;
265
+ UndefiedState = 0;
266
+ Executing = 1;
267
+ Completed = 2;
254
268
  }
255
269
 
256
270
  enum ConsistencyLevel {
@@ -262,39 +276,63 @@ enum ConsistencyLevel {
262
276
  }
263
277
 
264
278
  enum ImportState {
265
- ImportPending = 0;
266
- ImportFailed = 1;
267
- ImportStarted = 2;
268
- ImportDownloaded = 3;
269
- ImportParsed = 4;
270
- ImportPersisted = 5;
271
- ImportCompleted = 6;
272
- ImportAllocSegment = 10;
279
+ ImportPending = 0; // the task in in pending list of rootCoord, waiting to be executed
280
+ ImportFailed = 1; // the task failed for some reason, get detail reason from GetImportStateResponse.infos
281
+ ImportStarted = 2; // the task has been sent to datanode to execute
282
+ ImportPersisted = 5; // all data files have been parsed and data already persisted
283
+ ImportCompleted = 6; // all indexes are successfully built and segments are able to be compacted as normal.
284
+ ImportFailedAndCleaned = 7; // the task failed and all segments it generated are cleaned up.
273
285
  }
274
286
 
275
- enum ResourceType {
287
+ enum ObjectType {
276
288
  Collection = 0;
289
+ Global = 1;
290
+ User = 2;
277
291
  }
278
292
 
279
- enum ResourcePrivilege {
293
+ enum ObjectPrivilege {
280
294
  PrivilegeAll = 0;
281
- PrivilegeCreate = 1;
282
- PrivilegeDrop = 2;
283
- PrivilegeAlter = 3;
284
- PrivilegeRead = 4;
295
+ PrivilegeCreateCollection = 1;
296
+ PrivilegeDropCollection = 2;
297
+ PrivilegeDescribeCollection = 3;
298
+ PrivilegeShowCollections = 4;
285
299
  PrivilegeLoad = 5;
286
300
  PrivilegeRelease = 6;
287
- PrivilegeCompact = 7;
301
+ PrivilegeCompaction = 7;
288
302
  PrivilegeInsert = 8;
289
303
  PrivilegeDelete = 9;
304
+
305
+ PrivilegeGetStatistics = 10;
306
+ PrivilegeCreateIndex = 11;
307
+ PrivilegeIndexDetail = 12;
308
+ PrivilegeDropIndex = 13;
309
+ PrivilegeSearch = 14;
310
+ PrivilegeFlush = 15;
311
+ PrivilegeQuery = 16;
312
+ PrivilegeLoadBalance = 17;
313
+ PrivilegeImport = 18;
314
+ PrivilegeCreateOwnership = 19;
315
+ PrivilegeUpdateUser = 20;
316
+ PrivilegeDropOwnership = 21;
317
+ PrivilegeSelectOwnership = 22;
318
+ PrivilegeManageOwnership = 23;
319
+ PrivilegeSelectUser = 24;
290
320
  }
291
321
 
292
322
  message PrivilegeExt {
293
- ResourceType resource_type = 1;
294
- ResourcePrivilege resource_privilege = 2;
295
- int32 resource_name_index = 3;
323
+ ObjectType object_type = 1;
324
+ ObjectPrivilege object_privilege = 2;
325
+ int32 object_name_index = 3;
326
+ int32 object_name_indexs = 4;
296
327
  }
297
328
 
298
329
  extend google.protobuf.MessageOptions {
299
330
  PrivilegeExt privilege_ext_obj = 1001;
300
- }
331
+ }
332
+
333
+ enum StateCode {
334
+ Initializing = 0;
335
+ Healthy = 1;
336
+ Abnormal = 2;
337
+ StandBy = 3;
338
+ }
@@ -36,7 +36,6 @@
36
36
  // A valid .proto file can be translated directly to a FileDescriptorProto
37
37
  // without any other information (e.g. without reading its imports).
38
38
 
39
-
40
39
  syntax = "proto2";
41
40
 
42
41
  package google.protobuf;
@@ -134,7 +133,6 @@ message ExtensionRangeOptions {
134
133
  // The parser stores options it doesn't recognize here. See above.
135
134
  repeated UninterpretedOption uninterpreted_option = 999;
136
135
 
137
-
138
136
  // Clients can define custom options in extensions of this message. See above.
139
137
  extensions 1000 to max;
140
138
  }
@@ -310,7 +308,6 @@ message MethodDescriptorProto {
310
308
  optional bool server_streaming = 6 [default = false];
311
309
  }
312
310
 
313
-
314
311
  // ===================================================================
315
312
  // Options
316
313
 
@@ -351,7 +348,6 @@ message FileOptions {
351
348
  // domain names.
352
349
  optional string java_package = 1;
353
350
 
354
-
355
351
  // Controls the name of the wrapper Java class generated for the .proto file.
356
352
  // That class will always contain the .proto file's getDescriptor() method as
357
353
  // well as any top-level extensions defined in the .proto file.
@@ -378,7 +374,6 @@ message FileOptions {
378
374
  // This option has no effect on when used with the lite runtime.
379
375
  optional bool java_string_check_utf8 = 27 [default = false];
380
376
 
381
-
382
377
  // Generated classes can be optimized for speed or code size.
383
378
  enum OptimizeMode {
384
379
  SPEED = 1; // Generate complete code for parsing, serialization,
@@ -395,9 +390,6 @@ message FileOptions {
395
390
  // - Otherwise, the basename of the .proto file, without extension.
396
391
  optional string go_package = 11;
397
392
 
398
-
399
-
400
-
401
393
  // Should generic services be generated in each language? "Generic" services
402
394
  // are not specific to any particular RPC system. They are generated by the
403
395
  // main code generators in each language (without additional plugins).
@@ -423,7 +415,6 @@ message FileOptions {
423
415
  // only to generated classes for C++.
424
416
  optional bool cc_enable_arenas = 31 [default = true];
425
417
 
426
-
427
418
  // Sets the objective c class prefix which is prepended to all objective c
428
419
  // generated classes from this .proto. There is no default.
429
420
  optional string objc_class_prefix = 36;
@@ -456,7 +447,6 @@ message FileOptions {
456
447
  // determining the ruby package.
457
448
  optional string ruby_package = 45;
458
449
 
459
-
460
450
  // The parser stores options it doesn't recognize here.
461
451
  // See the documentation for the "Options" section above.
462
452
  repeated UninterpretedOption uninterpreted_option = 999;
@@ -502,6 +492,10 @@ message MessageOptions {
502
492
 
503
493
  reserved 4, 5, 6;
504
494
 
495
+ // NOTE: Do not set the option in .proto files. Always use the maps syntax
496
+ // instead. The option should only be implicitly set by the proto compiler
497
+ // parser.
498
+ //
505
499
  // Whether the message is an automatically generated map entry type for the
506
500
  // maps field.
507
501
  //
@@ -519,16 +513,11 @@ message MessageOptions {
519
513
  // use a native map in the target language to hold the keys and values.
520
514
  // The reflection APIs in such implementations still need to work as
521
515
  // if the field is a repeated message field.
522
- //
523
- // NOTE: Do not set the option in .proto files. Always use the maps syntax
524
- // instead. The option should only be implicitly set by the proto compiler
525
- // parser.
526
516
  optional bool map_entry = 7;
527
517
 
528
518
  reserved 8; // javalite_serializable
529
519
  reserved 9; // javanano_as_lite
530
520
 
531
-
532
521
  // The parser stores options it doesn't recognize here. See above.
533
522
  repeated UninterpretedOption uninterpreted_option = 999;
534
523
 
@@ -597,7 +586,6 @@ message FieldOptions {
597
586
  // call from multiple threads concurrently, while non-const methods continue
598
587
  // to require exclusive access.
599
588
  //
600
- //
601
589
  // Note that implementations may choose not to check required fields within
602
590
  // a lazy sub-message. That is, calling IsInitialized() on the outer message
603
591
  // may return true even if the inner message has missing required fields.
@@ -627,7 +615,6 @@ message FieldOptions {
627
615
  // For Google-internal migration only. Do not use.
628
616
  optional bool weak = 10 [default = false];
629
617
 
630
-
631
618
  // The parser stores options it doesn't recognize here. See above.
632
619
  repeated UninterpretedOption uninterpreted_option = 999;
633
620
 
@@ -731,7 +718,6 @@ message MethodOptions {
731
718
  extensions 1000 to max;
732
719
  }
733
720
 
734
-
735
721
  // A message representing a option the parser does not recognize. This only
736
722
  // appears in options protos created by the compiler::Parser class.
737
723
  // DescriptorPool resolves these when building Descriptor objects. Therefore,
@@ -916,8 +902,20 @@ message GeneratedCodeInfo {
916
902
  optional int32 begin = 3;
917
903
 
918
904
  // Identifies the ending offset in bytes in the generated code that
919
- // relates to the identified offset. The end offset should be one past
905
+ // relates to the identified object. The end offset should be one past
920
906
  // the last relevant byte (so the length of the text = end - begin).
921
907
  optional int32 end = 4;
908
+
909
+ // Represents the identified object's effect on the element in the original
910
+ // .proto file.
911
+ enum Semantic {
912
+ // There is no effect or the effect is indescribable.
913
+ NONE = 0;
914
+ // The element is set or otherwise mutated.
915
+ SET = 1;
916
+ // An alias to the element is returned.
917
+ ALIAS = 2;
918
+ }
919
+ optional Semantic semantic = 5;
922
920
  }
923
921
  }