@zilliz/milvus2-sdk-node 2.4.9 → 2.4.11
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.
- package/dist/milvus/const/client.d.ts +2 -1
- package/dist/milvus/const/client.js +1 -0
- package/dist/milvus/const/client.js.map +1 -1
- package/dist/milvus/const/limits.d.ts +1 -0
- package/dist/milvus/const/limits.js +2 -1
- package/dist/milvus/const/limits.js.map +1 -1
- package/dist/milvus/const/milvus.d.ts +4 -0
- package/dist/milvus/const/milvus.js +6 -1
- package/dist/milvus/const/milvus.js.map +1 -1
- package/dist/milvus/grpc/BaseClient.js +12 -4
- package/dist/milvus/grpc/BaseClient.js.map +1 -1
- package/dist/milvus/grpc/Collection.d.ts +77 -2
- package/dist/milvus/grpc/Collection.js +106 -1
- package/dist/milvus/grpc/Collection.js.map +1 -1
- package/dist/milvus/grpc/Data.js +28 -7
- package/dist/milvus/grpc/Data.js.map +1 -1
- package/dist/milvus/grpc/Database.d.ts +24 -1
- package/dist/milvus/grpc/Database.js +35 -1
- package/dist/milvus/grpc/Database.js.map +1 -1
- package/dist/milvus/grpc/MilvusIndex.d.ts +29 -2
- package/dist/milvus/grpc/MilvusIndex.js +44 -1
- package/dist/milvus/grpc/MilvusIndex.js.map +1 -1
- package/dist/milvus/grpc/User.d.ts +165 -1
- package/dist/milvus/grpc/User.js +229 -0
- package/dist/milvus/grpc/User.js.map +1 -1
- package/dist/milvus/types/Client.d.ts +1 -0
- package/dist/milvus/types/Collection.d.ts +30 -19
- package/dist/milvus/types/Common.d.ts +5 -5
- package/dist/milvus/types/Data.d.ts +23 -6
- package/dist/milvus/types/Database.d.ts +6 -0
- package/dist/milvus/types/MilvusIndex.d.ts +4 -0
- package/dist/milvus/types/User.d.ts +56 -1
- package/dist/milvus/utils/Format.d.ts +56 -31
- package/dist/milvus/utils/Format.js +114 -22
- package/dist/milvus/utils/Format.js.map +1 -1
- package/dist/proto/proto/common.proto +30 -0
- package/dist/proto/proto/google/protobuf/descriptor.proto +68 -1
- package/dist/proto/proto/milvus.proto +133 -6
- package/dist/proto/proto/msg.proto +7 -0
- package/dist/proto/proto/rg.proto +7 -0
- package/dist/proto/proto/schema.proto +28 -0
- package/dist/sdk.json +1 -1
- package/package.json +3 -3
|
@@ -27,7 +27,7 @@ service MilvusService {
|
|
|
27
27
|
rpc GetCollectionStatistics(GetCollectionStatisticsRequest) returns (GetCollectionStatisticsResponse) {}
|
|
28
28
|
rpc ShowCollections(ShowCollectionsRequest) returns (ShowCollectionsResponse) {}
|
|
29
29
|
rpc AlterCollection(AlterCollectionRequest) returns (common.Status) {}
|
|
30
|
-
|
|
30
|
+
rpc AlterCollectionField(AlterCollectionFieldRequest) returns (common.Status) {}
|
|
31
31
|
rpc CreatePartition(CreatePartitionRequest) returns (common.Status) {}
|
|
32
32
|
rpc DropPartition(DropPartitionRequest) returns (common.Status) {}
|
|
33
33
|
rpc HasPartition(HasPartitionRequest) returns (BoolResponse) {}
|
|
@@ -107,6 +107,7 @@ service MilvusService {
|
|
|
107
107
|
rpc SelectRole(SelectRoleRequest) returns (SelectRoleResponse) {}
|
|
108
108
|
rpc SelectUser(SelectUserRequest) returns (SelectUserResponse) {}
|
|
109
109
|
rpc OperatePrivilege(OperatePrivilegeRequest) returns (common.Status) {}
|
|
110
|
+
rpc OperatePrivilegeV2(OperatePrivilegeV2Request) returns (common.Status) {}
|
|
110
111
|
rpc SelectGrant(SelectGrantRequest) returns (SelectGrantResponse) {}
|
|
111
112
|
|
|
112
113
|
rpc GetVersion(GetVersionRequest) returns (GetVersionResponse) {}
|
|
@@ -139,6 +140,11 @@ service MilvusService {
|
|
|
139
140
|
|
|
140
141
|
rpc BackupRBAC(BackupRBACMetaRequest) returns (BackupRBACMetaResponse){}
|
|
141
142
|
rpc RestoreRBAC(RestoreRBACMetaRequest) returns (common.Status){}
|
|
143
|
+
|
|
144
|
+
rpc CreatePrivilegeGroup(CreatePrivilegeGroupRequest) returns (common.Status) {}
|
|
145
|
+
rpc DropPrivilegeGroup(DropPrivilegeGroupRequest) returns (common.Status) {}
|
|
146
|
+
rpc ListPrivilegeGroups(ListPrivilegeGroupsRequest) returns (ListPrivilegeGroupsResponse) {}
|
|
147
|
+
rpc OperatePrivilegeGroup(OperatePrivilegeGroupRequest) returns (common.Status) {}
|
|
142
148
|
}
|
|
143
149
|
|
|
144
150
|
message CreateAliasRequest {
|
|
@@ -282,6 +288,22 @@ message AlterCollectionRequest {
|
|
|
282
288
|
string collection_name = 3;
|
|
283
289
|
int64 collectionID = 4;
|
|
284
290
|
repeated common.KeyValuePair properties = 5;
|
|
291
|
+
repeated string delete_keys = 6;
|
|
292
|
+
}
|
|
293
|
+
|
|
294
|
+
message AlterCollectionFieldRequest {
|
|
295
|
+
option (common.privilege_ext_obj) = {
|
|
296
|
+
object_type: Global
|
|
297
|
+
object_privilege: PrivilegeCreateCollection
|
|
298
|
+
object_name_index: -1
|
|
299
|
+
};
|
|
300
|
+
// Not useful for now
|
|
301
|
+
common.MsgBase base = 1;
|
|
302
|
+
string db_name = 2;
|
|
303
|
+
// The unique collection name in milvus.(Required)
|
|
304
|
+
string collection_name = 3;
|
|
305
|
+
string field_name =4;
|
|
306
|
+
repeated common.KeyValuePair properties = 5;
|
|
285
307
|
}
|
|
286
308
|
|
|
287
309
|
/**
|
|
@@ -736,6 +758,7 @@ message AlterIndexRequest {
|
|
|
736
758
|
string collection_name = 3;
|
|
737
759
|
string index_name = 4;
|
|
738
760
|
repeated common.KeyValuePair extra_params = 5;
|
|
761
|
+
repeated string delete_keys = 6;
|
|
739
762
|
}
|
|
740
763
|
|
|
741
764
|
/*
|
|
@@ -905,6 +928,7 @@ message DeleteRequest {
|
|
|
905
928
|
string expr = 5;
|
|
906
929
|
repeated uint32 hash_keys = 6;
|
|
907
930
|
common.ConsistencyLevel consistency_level = 7;
|
|
931
|
+
map<string, schema.TemplateValue> expr_template_values = 8;
|
|
908
932
|
}
|
|
909
933
|
|
|
910
934
|
|
|
@@ -914,10 +938,10 @@ message SubSearchRequest {
|
|
|
914
938
|
bytes placeholder_group = 2; // must
|
|
915
939
|
common.DslType dsl_type = 3; // must
|
|
916
940
|
repeated common.KeyValuePair search_params = 4; // must
|
|
917
|
-
int64
|
|
941
|
+
int64 nq = 5;
|
|
942
|
+
map<string, schema.TemplateValue> expr_template_values = 6;
|
|
918
943
|
}
|
|
919
944
|
|
|
920
|
-
|
|
921
945
|
message SearchRequest {
|
|
922
946
|
option (common.privilege_ext_obj) = {
|
|
923
947
|
object_type: Collection
|
|
@@ -942,6 +966,7 @@ message SearchRequest {
|
|
|
942
966
|
bool use_default_consistency = 15;
|
|
943
967
|
bool search_by_primary_keys = 16;
|
|
944
968
|
repeated SubSearchRequest sub_reqs = 17;
|
|
969
|
+
map<string, schema.TemplateValue> expr_template_values = 18;
|
|
945
970
|
}
|
|
946
971
|
|
|
947
972
|
message Hits {
|
|
@@ -1015,6 +1040,7 @@ message QueryRequest {
|
|
|
1015
1040
|
bool not_return_all_meta = 10;
|
|
1016
1041
|
common.ConsistencyLevel consistency_level = 11;
|
|
1017
1042
|
bool use_default_consistency = 12;
|
|
1043
|
+
map<string, schema.TemplateValue> expr_template_values = 13;
|
|
1018
1044
|
}
|
|
1019
1045
|
|
|
1020
1046
|
message QueryResults {
|
|
@@ -1022,6 +1048,8 @@ message QueryResults {
|
|
|
1022
1048
|
repeated schema.FieldData fields_data = 2;
|
|
1023
1049
|
string collection_name = 3;
|
|
1024
1050
|
repeated string output_fields = 4;
|
|
1051
|
+
uint64 session_ts = 5; // for session-like operation like iterator
|
|
1052
|
+
string primary_field_name = 6;
|
|
1025
1053
|
}
|
|
1026
1054
|
|
|
1027
1055
|
message VectorIDs {
|
|
@@ -1179,11 +1207,13 @@ message ManualCompactionRequest {
|
|
|
1179
1207
|
option (common.privilege_ext_obj) = {
|
|
1180
1208
|
object_type: Collection
|
|
1181
1209
|
object_privilege: PrivilegeCompaction
|
|
1182
|
-
object_name_index:
|
|
1210
|
+
object_name_index: 4
|
|
1183
1211
|
};
|
|
1184
1212
|
int64 collectionID = 1;
|
|
1185
1213
|
uint64 timetravel = 2;
|
|
1186
1214
|
bool majorCompaction = 3;
|
|
1215
|
+
string collection_name = 4;
|
|
1216
|
+
string db_name = 5;
|
|
1187
1217
|
}
|
|
1188
1218
|
|
|
1189
1219
|
message ManualCompactionResponse {
|
|
@@ -1437,6 +1467,66 @@ message DropRoleRequest {
|
|
|
1437
1467
|
bool force_drop = 3;
|
|
1438
1468
|
}
|
|
1439
1469
|
|
|
1470
|
+
message CreatePrivilegeGroupRequest {
|
|
1471
|
+
option (common.privilege_ext_obj) = {
|
|
1472
|
+
object_type: Global
|
|
1473
|
+
object_privilege: PrivilegeCreatePrivilegeGroup
|
|
1474
|
+
object_name_index: -1
|
|
1475
|
+
};
|
|
1476
|
+
// Not useful for now
|
|
1477
|
+
common.MsgBase base = 1;
|
|
1478
|
+
// group name
|
|
1479
|
+
string group_name = 2;
|
|
1480
|
+
}
|
|
1481
|
+
|
|
1482
|
+
message DropPrivilegeGroupRequest {
|
|
1483
|
+
option (common.privilege_ext_obj) = {
|
|
1484
|
+
object_type: Global
|
|
1485
|
+
object_privilege: PrivilegeDropPrivilegeGroup
|
|
1486
|
+
object_name_index: -1
|
|
1487
|
+
};
|
|
1488
|
+
// Not useful for now
|
|
1489
|
+
common.MsgBase base = 1;
|
|
1490
|
+
// group name
|
|
1491
|
+
string group_name = 2;
|
|
1492
|
+
}
|
|
1493
|
+
|
|
1494
|
+
message ListPrivilegeGroupsRequest {
|
|
1495
|
+
option (common.privilege_ext_obj) = {
|
|
1496
|
+
object_type: Global
|
|
1497
|
+
object_privilege: PrivilegeListPrivilegeGroups
|
|
1498
|
+
object_name_index: -1
|
|
1499
|
+
};
|
|
1500
|
+
// Not useful for now
|
|
1501
|
+
common.MsgBase base = 1;
|
|
1502
|
+
}
|
|
1503
|
+
|
|
1504
|
+
message ListPrivilegeGroupsResponse {
|
|
1505
|
+
common.Status status = 1;
|
|
1506
|
+
repeated PrivilegeGroupInfo privilege_groups = 2;
|
|
1507
|
+
}
|
|
1508
|
+
|
|
1509
|
+
message OperatePrivilegeGroupRequest {
|
|
1510
|
+
option (common.privilege_ext_obj) = {
|
|
1511
|
+
object_type: Global
|
|
1512
|
+
object_privilege: PrivilegeOperatePrivilegeGroup
|
|
1513
|
+
object_name_index: -1
|
|
1514
|
+
};
|
|
1515
|
+
// Not useful for now
|
|
1516
|
+
common.MsgBase base = 1;
|
|
1517
|
+
// group name
|
|
1518
|
+
string group_name = 2;
|
|
1519
|
+
// privileges
|
|
1520
|
+
repeated PrivilegeEntity privileges = 3;
|
|
1521
|
+
// operation type
|
|
1522
|
+
OperatePrivilegeGroupType type = 4;
|
|
1523
|
+
}
|
|
1524
|
+
|
|
1525
|
+
enum OperatePrivilegeGroupType {
|
|
1526
|
+
AddPrivilegesToGroup = 0;
|
|
1527
|
+
RemovePrivilegesFromGroup = 1;
|
|
1528
|
+
}
|
|
1529
|
+
|
|
1440
1530
|
enum OperateUserRoleType {
|
|
1441
1531
|
AddUserToRole = 0;
|
|
1442
1532
|
RemoveUserFromRole = 1;
|
|
@@ -1458,6 +1548,11 @@ message OperateUserRoleRequest {
|
|
|
1458
1548
|
OperateUserRoleType type = 4;
|
|
1459
1549
|
}
|
|
1460
1550
|
|
|
1551
|
+
message PrivilegeGroupInfo {
|
|
1552
|
+
string group_name = 1;
|
|
1553
|
+
repeated PrivilegeEntity privileges = 2;
|
|
1554
|
+
}
|
|
1555
|
+
|
|
1461
1556
|
message SelectRoleRequest {
|
|
1462
1557
|
option (common.privilege_ext_obj) = {
|
|
1463
1558
|
object_type: Global
|
|
@@ -1540,6 +1635,12 @@ message GrantEntity {
|
|
|
1540
1635
|
string db_name = 5;
|
|
1541
1636
|
}
|
|
1542
1637
|
|
|
1638
|
+
enum PrivilegeLevel {
|
|
1639
|
+
Cluster = 0;
|
|
1640
|
+
Database = 1;
|
|
1641
|
+
Collection = 2;
|
|
1642
|
+
}
|
|
1643
|
+
|
|
1543
1644
|
message SelectGrantRequest {
|
|
1544
1645
|
option (common.privilege_ext_obj) = {
|
|
1545
1646
|
object_type: Global
|
|
@@ -1576,6 +1677,29 @@ message OperatePrivilegeRequest {
|
|
|
1576
1677
|
GrantEntity entity = 2;
|
|
1577
1678
|
// operation type
|
|
1578
1679
|
OperatePrivilegeType type = 3;
|
|
1680
|
+
// version
|
|
1681
|
+
string version = 4;
|
|
1682
|
+
}
|
|
1683
|
+
|
|
1684
|
+
|
|
1685
|
+
message OperatePrivilegeV2Request {
|
|
1686
|
+
option (common.privilege_ext_obj) = {
|
|
1687
|
+
object_type: Global
|
|
1688
|
+
object_privilege: PrivilegeManageOwnership
|
|
1689
|
+
object_name_index: -1
|
|
1690
|
+
};
|
|
1691
|
+
// Not useful for now
|
|
1692
|
+
common.MsgBase base = 1;
|
|
1693
|
+
// role
|
|
1694
|
+
RoleEntity role = 2;
|
|
1695
|
+
// privilege
|
|
1696
|
+
GrantorEntity grantor = 3;
|
|
1697
|
+
// operation type
|
|
1698
|
+
OperatePrivilegeType type = 4;
|
|
1699
|
+
// db name
|
|
1700
|
+
string db_name = 5;
|
|
1701
|
+
// collection name
|
|
1702
|
+
string collection_name = 6;
|
|
1579
1703
|
}
|
|
1580
1704
|
|
|
1581
1705
|
message UserInfo {
|
|
@@ -1591,6 +1715,8 @@ message RBACMeta {
|
|
|
1591
1715
|
repeated milvus.RoleEntity roles = 2;
|
|
1592
1716
|
// (role, object, previledge)
|
|
1593
1717
|
repeated milvus.GrantEntity grants = 3;
|
|
1718
|
+
// privilege group info
|
|
1719
|
+
repeated milvus.PrivilegeGroupInfo privilege_groups = 4;
|
|
1594
1720
|
}
|
|
1595
1721
|
|
|
1596
1722
|
message BackupRBACMetaRequest {
|
|
@@ -1892,6 +2018,7 @@ message AlterDatabaseRequest {
|
|
|
1892
2018
|
string db_name = 2;
|
|
1893
2019
|
string db_id = 3;
|
|
1894
2020
|
repeated common.KeyValuePair properties = 4;
|
|
2021
|
+
repeated string delete_keys = 5;
|
|
1895
2022
|
}
|
|
1896
2023
|
|
|
1897
2024
|
message DescribeDatabaseRequest {
|
|
@@ -1931,7 +2058,7 @@ message ImportAuthPlaceholder {
|
|
|
1931
2058
|
option (common.privilege_ext_obj) = {
|
|
1932
2059
|
object_type: Collection
|
|
1933
2060
|
object_privilege: PrivilegeImport
|
|
1934
|
-
object_name_index:
|
|
2061
|
+
object_name_index: 2
|
|
1935
2062
|
};
|
|
1936
2063
|
string db_name = 1;
|
|
1937
2064
|
string collection_name = 2;
|
|
@@ -1942,7 +2069,7 @@ message GetImportProgressAuthPlaceholder {
|
|
|
1942
2069
|
option (common.privilege_ext_obj) = {
|
|
1943
2070
|
object_type: Collection
|
|
1944
2071
|
object_privilege: PrivilegeImport
|
|
1945
|
-
object_name_index: 1
|
|
2072
|
+
object_name_index: -1
|
|
1946
2073
|
};
|
|
1947
2074
|
string db_name = 1;
|
|
1948
2075
|
}
|
|
@@ -10,6 +10,8 @@ option java_generate_equals_and_hash = true;
|
|
|
10
10
|
|
|
11
11
|
option csharp_namespace = "Milvus.Client.Grpc";
|
|
12
12
|
|
|
13
|
+
import "common.proto";
|
|
14
|
+
|
|
13
15
|
message ResourceGroupLimit {
|
|
14
16
|
int32 node_num = 1;
|
|
15
17
|
// preserve for other limit.
|
|
@@ -19,10 +21,15 @@ message ResourceGroupTransfer {
|
|
|
19
21
|
string resource_group = 1; // resource groups can be transfered with current resource group.
|
|
20
22
|
// preserve for other option, such as weight, priority or affinity setup.
|
|
21
23
|
}
|
|
24
|
+
|
|
25
|
+
message ResourceGroupNodeFilter {
|
|
26
|
+
repeated common.KeyValuePair node_labels = 1; // node in resource group must match node labels requirements
|
|
27
|
+
}
|
|
22
28
|
|
|
23
29
|
message ResourceGroupConfig {
|
|
24
30
|
ResourceGroupLimit requests = 1; // requests node num in resource group, if node num is less than requests.nodeNum, it will be transfer from other resource group.
|
|
25
31
|
ResourceGroupLimit limits = 2; // limited node num in resource group, if node num is more than limits.nodeNum, it will be transfer to other resource group.
|
|
26
32
|
repeated ResourceGroupTransfer transfer_from = 3; // missing node should be transfer from given resource group at high priority in repeated list.
|
|
27
33
|
repeated ResourceGroupTransfer transfer_to = 4; // redundant node should be transfer to given resource group at high priority in repeated list.
|
|
34
|
+
ResourceGroupNodeFilter node_filter = 5; // node in resource group must match node filters
|
|
28
35
|
}
|
|
@@ -77,6 +77,7 @@ message CollectionSchema {
|
|
|
77
77
|
repeated FieldSchema fields = 4;
|
|
78
78
|
bool enable_dynamic_field = 5; // mark whether this table has the dynamic field function enabled.
|
|
79
79
|
repeated common.KeyValuePair properties = 6;
|
|
80
|
+
string dbName = 8;
|
|
80
81
|
}
|
|
81
82
|
|
|
82
83
|
message BoolArray { repeated bool data = 1; }
|
|
@@ -175,6 +176,8 @@ message SearchResultData {
|
|
|
175
176
|
FieldData group_by_field_value = 8;
|
|
176
177
|
int64 all_search_count = 9;
|
|
177
178
|
repeated float distances = 10;
|
|
179
|
+
repeated float recalls = 12;
|
|
180
|
+
string primary_field_name = 13;
|
|
178
181
|
}
|
|
179
182
|
|
|
180
183
|
// vector field clustering info
|
|
@@ -195,3 +198,28 @@ message ClusteringInfo {
|
|
|
195
198
|
repeated VectorClusteringInfo vector_clustering_infos = 1;
|
|
196
199
|
repeated ScalarClusteringInfo scalar_clustering_infos = 2;
|
|
197
200
|
}
|
|
201
|
+
|
|
202
|
+
message TemplateValue {
|
|
203
|
+
oneof val {
|
|
204
|
+
bool bool_val = 1;
|
|
205
|
+
int64 int64_val = 2;
|
|
206
|
+
double float_val = 3;
|
|
207
|
+
string string_val = 4;
|
|
208
|
+
TemplateArrayValue array_val = 5;
|
|
209
|
+
};
|
|
210
|
+
}
|
|
211
|
+
|
|
212
|
+
message TemplateArrayValue {
|
|
213
|
+
oneof data {
|
|
214
|
+
BoolArray bool_data = 1;
|
|
215
|
+
LongArray long_data = 2;
|
|
216
|
+
DoubleArray double_data = 3;
|
|
217
|
+
StringArray string_data = 4;
|
|
218
|
+
TemplateArrayValueArray array_data = 5;
|
|
219
|
+
JSONArray json_data = 6;
|
|
220
|
+
}
|
|
221
|
+
}
|
|
222
|
+
|
|
223
|
+
message TemplateArrayValueArray {
|
|
224
|
+
repeated TemplateArrayValue data = 1;
|
|
225
|
+
}
|
package/dist/sdk.json
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":"2.4.
|
|
1
|
+
{"version":"2.4.11","milvusVersion":"v2.4.19"}
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zilliz/milvus2-sdk-node",
|
|
3
3
|
"author": "ued@zilliz.com",
|
|
4
|
-
"version": "2.4.
|
|
5
|
-
"milvusVersion": "v2.4.
|
|
4
|
+
"version": "2.4.11",
|
|
5
|
+
"milvusVersion": "v2.4.19",
|
|
6
6
|
"main": "dist/milvus",
|
|
7
7
|
"files": [
|
|
8
8
|
"dist"
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"doc-json": "npx typedoc milvus --json"
|
|
21
21
|
},
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@grpc/grpc-js": "^1.
|
|
23
|
+
"@grpc/grpc-js": "^1.12.1",
|
|
24
24
|
"@grpc/proto-loader": "^0.7.10",
|
|
25
25
|
"@petamoriken/float16": "^3.8.6",
|
|
26
26
|
"dayjs": "^1.11.7",
|