@zilliz/milvus2-sdk-node 2.2.0 → 2.2.2
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/README.md +21 -13
- package/dist/milvus/Collection.d.ts +2 -0
- package/dist/milvus/Collection.js +6 -4
- package/dist/milvus/Collection.js.map +1 -1
- package/dist/milvus/Data.d.ts +1 -0
- package/dist/milvus/Data.js +6 -7
- package/dist/milvus/Data.js.map +1 -1
- package/dist/milvus/User.d.ts +316 -28
- package/dist/milvus/User.js +565 -26
- package/dist/milvus/User.js.map +1 -1
- package/dist/milvus/types/Common.d.ts +164 -1
- package/dist/milvus/types/Common.js +218 -1
- package/dist/milvus/types/Common.js.map +1 -1
- package/dist/milvus/types/Index.d.ts +1 -1
- package/dist/milvus/types/Response.d.ts +47 -1
- package/dist/milvus/types/Response.js.map +1 -1
- package/dist/milvus/types/User.d.ts +37 -1
- package/dist/proto/proto/common.proto +19 -1
- package/dist/proto/proto/google/protobuf/descriptor.proto +24 -0
- package/dist/proto/proto/milvus.proto +43 -2
- package/dist/proto/proto/schema.proto +2 -0
- package/dist/sdk.json +1 -1
- package/package.json +2 -2
package/dist/milvus/User.js
CHANGED
|
@@ -55,10 +55,8 @@ exports.User = void 0;
|
|
|
55
55
|
var utils_1 = require("../utils");
|
|
56
56
|
var Client_1 = require("./Client");
|
|
57
57
|
var ErrorReason_1 = require("./const/ErrorReason");
|
|
58
|
+
var Common_1 = require("./types/Common");
|
|
58
59
|
var Format_1 = require("./utils/Format");
|
|
59
|
-
/**
|
|
60
|
-
* See all [collection operation examples](https://github.com/milvus-io/milvus-sdk-node/blob/main/example/Collection.ts).
|
|
61
|
-
*/
|
|
62
60
|
var User = /** @class */ (function (_super) {
|
|
63
61
|
__extends(User, _super);
|
|
64
62
|
function User() {
|
|
@@ -68,17 +66,17 @@ var User = /** @class */ (function (_super) {
|
|
|
68
66
|
* Create user in milvus
|
|
69
67
|
*
|
|
70
68
|
* @param data
|
|
71
|
-
* | Property
|
|
72
|
-
* | :-------------- | :---- |
|
|
73
|
-
* | username
|
|
74
|
-
* | password
|
|
69
|
+
* | Property | Type | Description |
|
|
70
|
+
* | :-------------- | :---- | :---- |
|
|
71
|
+
* | username | String | username |
|
|
72
|
+
* | password | String | user password |
|
|
75
73
|
*
|
|
76
74
|
*
|
|
77
75
|
* @return
|
|
78
|
-
* | Property
|
|
76
|
+
* | Property | Description |
|
|
79
77
|
* | :-------------| :-------- |
|
|
80
|
-
* | error_code
|
|
81
|
-
* | reason
|
|
78
|
+
* | error_code | Error code number |
|
|
79
|
+
* | reason | Error cause|
|
|
82
80
|
*
|
|
83
81
|
* #### Example
|
|
84
82
|
*
|
|
@@ -114,17 +112,17 @@ var User = /** @class */ (function (_super) {
|
|
|
114
112
|
* Update user in milvus
|
|
115
113
|
*
|
|
116
114
|
* @param data
|
|
117
|
-
* | Property
|
|
118
|
-
* | :-------------- | :---- |
|
|
119
|
-
* | username
|
|
120
|
-
* | password
|
|
115
|
+
* | Property | Type | Description |
|
|
116
|
+
* | :-------------- | :---- | :------ |
|
|
117
|
+
* | username | String | username |
|
|
118
|
+
* | password | String | user password |
|
|
121
119
|
*
|
|
122
120
|
*
|
|
123
121
|
* @return
|
|
124
|
-
* | Property
|
|
122
|
+
* | Property | Description |
|
|
125
123
|
* | :-------------| :-------- |
|
|
126
|
-
* | error_code
|
|
127
|
-
* | reason
|
|
124
|
+
* | error_code | Error code number |
|
|
125
|
+
* | reason | Error cause|
|
|
128
126
|
*
|
|
129
127
|
* #### Example
|
|
130
128
|
*
|
|
@@ -164,16 +162,16 @@ var User = /** @class */ (function (_super) {
|
|
|
164
162
|
* Delete user in milvus
|
|
165
163
|
*
|
|
166
164
|
* @param data
|
|
167
|
-
* | Property
|
|
168
|
-
* | :-------------- | :---- |
|
|
169
|
-
* | username
|
|
165
|
+
* | Property | Type | Description |
|
|
166
|
+
* | :-------------- | :---- | :-- |
|
|
167
|
+
* | username | String | username |
|
|
170
168
|
*
|
|
171
169
|
*
|
|
172
170
|
* @return
|
|
173
|
-
* | Property
|
|
171
|
+
* | Property | Description |
|
|
174
172
|
* | :-------------| :-------- |
|
|
175
|
-
* | error_code
|
|
176
|
-
* | reason
|
|
173
|
+
* | error_code | Error code number |
|
|
174
|
+
* | reason | Error cause|
|
|
177
175
|
*
|
|
178
176
|
* #### Example
|
|
179
177
|
*
|
|
@@ -206,10 +204,10 @@ var User = /** @class */ (function (_super) {
|
|
|
206
204
|
* List user in milvus
|
|
207
205
|
*
|
|
208
206
|
* @return
|
|
209
|
-
* | Property
|
|
207
|
+
* | Property | Description |
|
|
210
208
|
* | :-------------| :-------- |
|
|
211
|
-
* | status
|
|
212
|
-
* | usernames
|
|
209
|
+
* | status | { error_code: number, reason: string }|
|
|
210
|
+
* | usernames | string[] |
|
|
213
211
|
*
|
|
214
212
|
* #### Example
|
|
215
213
|
*
|
|
@@ -230,6 +228,547 @@ var User = /** @class */ (function (_super) {
|
|
|
230
228
|
});
|
|
231
229
|
});
|
|
232
230
|
};
|
|
231
|
+
/**
|
|
232
|
+
* Create user role
|
|
233
|
+
*
|
|
234
|
+
* @return
|
|
235
|
+
* | Property | Description |
|
|
236
|
+
* | :-------------| :-------- |
|
|
237
|
+
* | status | { error_code: number, reason: string }|
|
|
238
|
+
* | reason | '' |
|
|
239
|
+
*
|
|
240
|
+
* #### Example
|
|
241
|
+
*
|
|
242
|
+
* ```
|
|
243
|
+
* milvusClient.userManager.createRole({roleName: 'myrole'});
|
|
244
|
+
* ```
|
|
245
|
+
*/
|
|
246
|
+
User.prototype.createRole = function (data) {
|
|
247
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
248
|
+
var promise;
|
|
249
|
+
return __generator(this, function (_a) {
|
|
250
|
+
switch (_a.label) {
|
|
251
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'CreateRole', {
|
|
252
|
+
entity: { name: data.roleName },
|
|
253
|
+
}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
254
|
+
case 1:
|
|
255
|
+
promise = _a.sent();
|
|
256
|
+
return [2 /*return*/, promise];
|
|
257
|
+
}
|
|
258
|
+
});
|
|
259
|
+
});
|
|
260
|
+
};
|
|
261
|
+
/**
|
|
262
|
+
* Drop user role
|
|
263
|
+
*
|
|
264
|
+
* @return
|
|
265
|
+
* | Property | Description |
|
|
266
|
+
* | :-------------| :-------- |
|
|
267
|
+
* | status | { error_code: number, reason: string }|
|
|
268
|
+
* | reason | '' |
|
|
269
|
+
*
|
|
270
|
+
* #### Example
|
|
271
|
+
*
|
|
272
|
+
* ```
|
|
273
|
+
* milvusClient.userManager.dropRole({roleName: 'myrole'});
|
|
274
|
+
* ```
|
|
275
|
+
*/
|
|
276
|
+
User.prototype.dropRole = function (data) {
|
|
277
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
278
|
+
var promise;
|
|
279
|
+
return __generator(this, function (_a) {
|
|
280
|
+
switch (_a.label) {
|
|
281
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'DropRole', {
|
|
282
|
+
role_name: data.roleName,
|
|
283
|
+
}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
284
|
+
case 1:
|
|
285
|
+
promise = _a.sent();
|
|
286
|
+
return [2 /*return*/, promise];
|
|
287
|
+
}
|
|
288
|
+
});
|
|
289
|
+
});
|
|
290
|
+
};
|
|
291
|
+
/**
|
|
292
|
+
* add user to role
|
|
293
|
+
*
|
|
294
|
+
* @return
|
|
295
|
+
* | Property | Description |
|
|
296
|
+
* | :-------------| :-------- |
|
|
297
|
+
* | status | { error_code: number, reason: string }|
|
|
298
|
+
* | reason | '' |
|
|
299
|
+
*
|
|
300
|
+
* #### Example
|
|
301
|
+
*
|
|
302
|
+
* ```
|
|
303
|
+
* milvusClient.userManager.addUserToRole({username: 'my', roleName: 'myrole'});
|
|
304
|
+
* ```
|
|
305
|
+
*/
|
|
306
|
+
User.prototype.addUserToRole = function (data) {
|
|
307
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
308
|
+
var promise;
|
|
309
|
+
return __generator(this, function (_a) {
|
|
310
|
+
switch (_a.label) {
|
|
311
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'OperateUserRole', {
|
|
312
|
+
username: data.username,
|
|
313
|
+
role_name: data.roleName,
|
|
314
|
+
type: Common_1.OperateUserRoleType.AddUserToRole,
|
|
315
|
+
}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
316
|
+
case 1:
|
|
317
|
+
promise = _a.sent();
|
|
318
|
+
return [2 /*return*/, promise];
|
|
319
|
+
}
|
|
320
|
+
});
|
|
321
|
+
});
|
|
322
|
+
};
|
|
323
|
+
/**
|
|
324
|
+
* remove user from role
|
|
325
|
+
*
|
|
326
|
+
* @return
|
|
327
|
+
* | Property | Description |
|
|
328
|
+
* | :-------------| :-------- |
|
|
329
|
+
* | status | { error_code: number, reason: string }|
|
|
330
|
+
* | reason | '' |
|
|
331
|
+
*
|
|
332
|
+
* #### Example
|
|
333
|
+
*
|
|
334
|
+
* ```
|
|
335
|
+
* milvusClient.userManager.removeUserFromRole({username: 'my', roleName: 'myrole'});
|
|
336
|
+
* ```
|
|
337
|
+
*/
|
|
338
|
+
User.prototype.removeUserFromRole = function (data) {
|
|
339
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
340
|
+
var promise;
|
|
341
|
+
return __generator(this, function (_a) {
|
|
342
|
+
switch (_a.label) {
|
|
343
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'OperateUserRole', {
|
|
344
|
+
username: data.username,
|
|
345
|
+
role_name: data.roleName,
|
|
346
|
+
type: Common_1.OperateUserRoleType.RemoveUserFromRole,
|
|
347
|
+
}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
348
|
+
case 1:
|
|
349
|
+
promise = _a.sent();
|
|
350
|
+
return [2 /*return*/, promise];
|
|
351
|
+
}
|
|
352
|
+
});
|
|
353
|
+
});
|
|
354
|
+
};
|
|
355
|
+
/**
|
|
356
|
+
* gets all users that belong to a specified role
|
|
357
|
+
*
|
|
358
|
+
* @param data
|
|
359
|
+
* | Property | Type | Description |
|
|
360
|
+
* | :------- | :----- | :------------ |
|
|
361
|
+
* | roleName | String | role name |
|
|
362
|
+
* | includeUserInfo? | boolean | should result including user info, by default: true |
|
|
363
|
+
* | timeout | number | An optional duration of time in millisecond to allow for the RPC. If it is set to undefined, the client keeps waiting until the server responds or error occurs. Default is undefined |
|
|
364
|
+
|
|
365
|
+
* @return
|
|
366
|
+
* | Property | Description |
|
|
367
|
+
* | :-------------| :-------- |
|
|
368
|
+
* | status | { error_code: number, reason: string }|
|
|
369
|
+
* | results | { users: {name: string}[]; role: {name: string} }[] |
|
|
370
|
+
*
|
|
371
|
+
* #### Example
|
|
372
|
+
*
|
|
373
|
+
* ```
|
|
374
|
+
* milvusClient.userManager.selectRole({roleName: 'myrole'});
|
|
375
|
+
* ```
|
|
376
|
+
*/
|
|
377
|
+
User.prototype.selectRole = function (data) {
|
|
378
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
379
|
+
var promise;
|
|
380
|
+
return __generator(this, function (_a) {
|
|
381
|
+
switch (_a.label) {
|
|
382
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'SelectRole', {
|
|
383
|
+
role: { name: data.roleName },
|
|
384
|
+
include_user_info: data.includeUserInfo || true,
|
|
385
|
+
}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
386
|
+
case 1:
|
|
387
|
+
promise = _a.sent();
|
|
388
|
+
return [2 /*return*/, promise];
|
|
389
|
+
}
|
|
390
|
+
});
|
|
391
|
+
});
|
|
392
|
+
};
|
|
393
|
+
/**
|
|
394
|
+
* list all roles
|
|
395
|
+
*
|
|
396
|
+
* @param data
|
|
397
|
+
* | Property | Type | Description |
|
|
398
|
+
* | :------- | :----- | :------------ |
|
|
399
|
+
* | timeout | number | An optional duration of time in millisecond to allow for the RPC. If it is set to undefined, the client keeps waiting until the server responds or error occurs. Default is undefined |
|
|
400
|
+
*
|
|
401
|
+
* @return
|
|
402
|
+
* | Property | Description |
|
|
403
|
+
* | :-------------| :-------- |
|
|
404
|
+
* | status | { error_code: number, reason: string }|
|
|
405
|
+
* | reason | '' |
|
|
406
|
+
*
|
|
407
|
+
* #### Example
|
|
408
|
+
*
|
|
409
|
+
* ```
|
|
410
|
+
* milvusClient.userManager.listRoles();
|
|
411
|
+
* ```
|
|
412
|
+
*/
|
|
413
|
+
User.prototype.listRoles = function (data) {
|
|
414
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
415
|
+
var promise;
|
|
416
|
+
return __generator(this, function (_a) {
|
|
417
|
+
switch (_a.label) {
|
|
418
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'SelectRole', {}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
419
|
+
case 1:
|
|
420
|
+
promise = _a.sent();
|
|
421
|
+
return [2 /*return*/, promise];
|
|
422
|
+
}
|
|
423
|
+
});
|
|
424
|
+
});
|
|
425
|
+
};
|
|
426
|
+
/**
|
|
427
|
+
* gets all users that belong to a specified role
|
|
428
|
+
*
|
|
429
|
+
* @param data
|
|
430
|
+
* | Property | Type | Description |
|
|
431
|
+
* | :------- | :----- | :------------ |
|
|
432
|
+
* | userName | String | user name |
|
|
433
|
+
* | includeUserInfo? | boolean | should result including user info, by default: true |
|
|
434
|
+
* | timeout | number | An optional duration of time in millisecond to allow for the RPC. If it is set to undefined, the client keeps waiting until the server responds or error occurs. Default is undefined |
|
|
435
|
+
*
|
|
436
|
+
* @return
|
|
437
|
+
* | Property | Description |
|
|
438
|
+
* | :-------------| :-------- |
|
|
439
|
+
* | status | { error_code: number, reason: string }|
|
|
440
|
+
* | results | user: {name: string}; roles: {name: string}[] |
|
|
441
|
+
*
|
|
442
|
+
* #### Example
|
|
443
|
+
*
|
|
444
|
+
* ```
|
|
445
|
+
* milvusClient.userManager.selectUser({username: 'name'});
|
|
446
|
+
* ```
|
|
447
|
+
*/
|
|
448
|
+
User.prototype.selectUser = function (data) {
|
|
449
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
450
|
+
var promise;
|
|
451
|
+
return __generator(this, function (_a) {
|
|
452
|
+
switch (_a.label) {
|
|
453
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'SelectUser', {
|
|
454
|
+
user: { name: data.username },
|
|
455
|
+
include_role_info: data.includeRoleInfo || true,
|
|
456
|
+
}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
457
|
+
case 1:
|
|
458
|
+
promise = _a.sent();
|
|
459
|
+
return [2 /*return*/, promise];
|
|
460
|
+
}
|
|
461
|
+
});
|
|
462
|
+
});
|
|
463
|
+
};
|
|
464
|
+
/**
|
|
465
|
+
* grant privileges to a role
|
|
466
|
+
*
|
|
467
|
+
* @param data
|
|
468
|
+
* | Property | Type | Description |
|
|
469
|
+
* | :------- | :----- | :------------ |
|
|
470
|
+
* | roleName | String | role name |
|
|
471
|
+
* | object | string | Type of the operational object to which the specified privilege belongs, such as Collection, Index, Partition, etc. This parameter is case-sensitive.|
|
|
472
|
+
* | objectName | string | Name of the object to which the role is granted the specified prvilege. |
|
|
473
|
+
* | privilegeName | string | Name of the privilege to be granted to the role. This parameter is case-sensitive. |
|
|
474
|
+
* | timeout | number | An optional duration of time in millisecond to allow for the RPC. If it is set to undefined, the client keeps waiting until the server responds or error occurs. Default is undefined |
|
|
475
|
+
*
|
|
476
|
+
* @return
|
|
477
|
+
* | Property | Description |
|
|
478
|
+
* | :-------------| :-------- |
|
|
479
|
+
* | status | { error_code: number, reason: string }|
|
|
480
|
+
* | reason | '' |
|
|
481
|
+
*
|
|
482
|
+
* #### Example
|
|
483
|
+
*
|
|
484
|
+
* ```
|
|
485
|
+
* milvusClient.userManager.grantRolePrivilege({
|
|
486
|
+
* roleName: 'roleName',
|
|
487
|
+
* object: '*',
|
|
488
|
+
* objectName: 'Collection',
|
|
489
|
+
* privilegeName: 'CreateIndex'
|
|
490
|
+
* });
|
|
491
|
+
* ```
|
|
492
|
+
*/
|
|
493
|
+
User.prototype.grantRolePrivilege = function (data) {
|
|
494
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
495
|
+
var promise;
|
|
496
|
+
return __generator(this, function (_a) {
|
|
497
|
+
switch (_a.label) {
|
|
498
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'OperatePrivilege', {
|
|
499
|
+
entity: {
|
|
500
|
+
role: { name: data.roleName },
|
|
501
|
+
object: { name: data.object },
|
|
502
|
+
object_name: data.objectName,
|
|
503
|
+
grantor: {
|
|
504
|
+
privilege: { name: data.privilegeName },
|
|
505
|
+
},
|
|
506
|
+
},
|
|
507
|
+
type: Common_1.OperatePrivilegeType.Grant,
|
|
508
|
+
}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
509
|
+
case 1:
|
|
510
|
+
promise = _a.sent();
|
|
511
|
+
return [2 /*return*/, promise];
|
|
512
|
+
}
|
|
513
|
+
});
|
|
514
|
+
});
|
|
515
|
+
};
|
|
516
|
+
/**
|
|
517
|
+
* revoke privileges to a role
|
|
518
|
+
*
|
|
519
|
+
* @param data
|
|
520
|
+
* | Property | Type | Description |
|
|
521
|
+
* | :------- | :----- | :------------ |
|
|
522
|
+
* | roleName | String | role name |
|
|
523
|
+
* | object | string | Type of the operational object to which the specified privilege belongs, such as Collection, Index, Partition, etc. This parameter is case-sensitive.|
|
|
524
|
+
* | objectName | string | Name of the object to which the role is granted the specified prvilege. |
|
|
525
|
+
* | privilegeName | string | Name of the privilege to be granted to the role. This parameter is case-sensitive. |
|
|
526
|
+
* | timeout | number | An optional duration of time in millisecond to allow for the RPC. If it is set to undefined, the client keeps waiting until the server responds or error occurs. Default is undefined |
|
|
527
|
+
*
|
|
528
|
+
* @return
|
|
529
|
+
* | Property | Description |
|
|
530
|
+
* | :------------- | :-------- |
|
|
531
|
+
* | status | { error_code: number, reason: string }|
|
|
532
|
+
* | reason | '' |
|
|
533
|
+
*
|
|
534
|
+
* #### Example
|
|
535
|
+
*
|
|
536
|
+
* ```
|
|
537
|
+
* milvusClient.userManager.grantRolePrivilege({
|
|
538
|
+
* roleName: 'roleName',
|
|
539
|
+
* object: '*',
|
|
540
|
+
* objectName: 'Collection',
|
|
541
|
+
* privilegeName: 'CreateIndex'
|
|
542
|
+
* });
|
|
543
|
+
* ```
|
|
544
|
+
*/
|
|
545
|
+
User.prototype.revokeRolePrivilege = function (data) {
|
|
546
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
547
|
+
var promise;
|
|
548
|
+
return __generator(this, function (_a) {
|
|
549
|
+
switch (_a.label) {
|
|
550
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'OperatePrivilege', {
|
|
551
|
+
entity: {
|
|
552
|
+
role: { name: data.roleName },
|
|
553
|
+
object: { name: data.object },
|
|
554
|
+
object_name: data.objectName,
|
|
555
|
+
grantor: {
|
|
556
|
+
privilege: { name: data.privilegeName },
|
|
557
|
+
},
|
|
558
|
+
},
|
|
559
|
+
type: Common_1.OperatePrivilegeType.Revoke,
|
|
560
|
+
}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
561
|
+
case 1:
|
|
562
|
+
promise = _a.sent();
|
|
563
|
+
return [2 /*return*/, promise];
|
|
564
|
+
}
|
|
565
|
+
});
|
|
566
|
+
});
|
|
567
|
+
};
|
|
568
|
+
/**
|
|
569
|
+
* revoke all roles priviledges
|
|
570
|
+
* @param data
|
|
571
|
+
* | Property | Type | Description |
|
|
572
|
+
* | :------- | :----- | :------------ |
|
|
573
|
+
* | roleName | String | role name |
|
|
574
|
+
* | object | string | Type of the operational object to which the specified privilege belongs, such as Collection, Index, Partition, etc. This parameter is case-sensitive.|
|
|
575
|
+
* | objectName | string | Name of the object to which the role is granted the specified prvilege. |
|
|
576
|
+
* | privilegeName | string | Name of the privilege to be granted to the role. This parameter is case-sensitive. |
|
|
577
|
+
* | timeout | number | An optional duration of time in millisecond to allow for the RPC. If it is set to undefined, the client keeps waiting until the server responds or error occurs. Default is undefined |
|
|
578
|
+
*
|
|
579
|
+
* @return
|
|
580
|
+
* | Property | Description |
|
|
581
|
+
* | :-------------| :-------- |
|
|
582
|
+
* | status | { error_code: number, reason: string }|
|
|
583
|
+
* | reason | '' |
|
|
584
|
+
*
|
|
585
|
+
* #### Example
|
|
586
|
+
*
|
|
587
|
+
* ```
|
|
588
|
+
* milvusClient.userManager.revokeAllRolesPrivileges({});
|
|
589
|
+
* ```
|
|
590
|
+
*/
|
|
591
|
+
User.prototype.revokeAllRolesPrivileges = function (data) {
|
|
592
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
593
|
+
var res, promises, i, r, grants, j, entity, _a, _b;
|
|
594
|
+
return __generator(this, function (_c) {
|
|
595
|
+
switch (_c.label) {
|
|
596
|
+
case 0: return [4 /*yield*/, this.listRoles({ timeout: data === null || data === void 0 ? void 0 : data.timeout })];
|
|
597
|
+
case 1:
|
|
598
|
+
res = _c.sent();
|
|
599
|
+
promises = [];
|
|
600
|
+
i = 0;
|
|
601
|
+
_c.label = 2;
|
|
602
|
+
case 2:
|
|
603
|
+
if (!(i < res.results.length)) return [3 /*break*/, 10];
|
|
604
|
+
r = res.results[i];
|
|
605
|
+
return [4 /*yield*/, this.listGrants({
|
|
606
|
+
roleName: r.role.name,
|
|
607
|
+
})];
|
|
608
|
+
case 3:
|
|
609
|
+
grants = _c.sent();
|
|
610
|
+
j = 0;
|
|
611
|
+
_c.label = 4;
|
|
612
|
+
case 4:
|
|
613
|
+
if (!(j < grants.entities.length)) return [3 /*break*/, 7];
|
|
614
|
+
entity = grants.entities[j];
|
|
615
|
+
return [4 /*yield*/, this.revokeRolePrivilege({
|
|
616
|
+
roleName: entity.role.name,
|
|
617
|
+
object: entity.object.name,
|
|
618
|
+
objectName: entity.object_name,
|
|
619
|
+
privilegeName: entity.grantor.privilege.name,
|
|
620
|
+
timeout: data === null || data === void 0 ? void 0 : data.timeout,
|
|
621
|
+
})];
|
|
622
|
+
case 5:
|
|
623
|
+
_c.sent();
|
|
624
|
+
_c.label = 6;
|
|
625
|
+
case 6:
|
|
626
|
+
j++;
|
|
627
|
+
return [3 /*break*/, 4];
|
|
628
|
+
case 7:
|
|
629
|
+
_b = (_a = promises).push;
|
|
630
|
+
return [4 /*yield*/, this.dropRole({
|
|
631
|
+
roleName: r.role.name,
|
|
632
|
+
timeout: data === null || data === void 0 ? void 0 : data.timeout,
|
|
633
|
+
})];
|
|
634
|
+
case 8:
|
|
635
|
+
_b.apply(_a, [_c.sent()]);
|
|
636
|
+
_c.label = 9;
|
|
637
|
+
case 9:
|
|
638
|
+
i++;
|
|
639
|
+
return [3 /*break*/, 2];
|
|
640
|
+
case 10: return [2 /*return*/, promises];
|
|
641
|
+
}
|
|
642
|
+
});
|
|
643
|
+
});
|
|
644
|
+
};
|
|
645
|
+
/**
|
|
646
|
+
* select a grant
|
|
647
|
+
* @param data
|
|
648
|
+
* | Property | Type | Description |
|
|
649
|
+
* | :------- | :----- | :------------ |
|
|
650
|
+
* | roleName | String | role name |
|
|
651
|
+
* | object | string | Type of the operational object to which the specified privilege belongs, such as Collection, Index, Partition, etc. This parameter is case-sensitive.|
|
|
652
|
+
* | objectName | string | Name of the object to which the role is granted the specified prvilege. |
|
|
653
|
+
* | privilegeName | string | Name of the privilege to be granted to the role. This parameter is case-sensitive. |
|
|
654
|
+
* | timeout | number | An optional duration of time in millisecond to allow for the RPC. If it is set to undefined, the client keeps waiting until the server responds or error occurs. Default is undefined |
|
|
655
|
+
*
|
|
656
|
+
* @return
|
|
657
|
+
* | Property | Description |
|
|
658
|
+
* | :-------------| :-------- |
|
|
659
|
+
* | status | { error_code: number, reason: string }|
|
|
660
|
+
* | reason | '' |
|
|
661
|
+
*
|
|
662
|
+
* #### Example
|
|
663
|
+
*
|
|
664
|
+
* ```
|
|
665
|
+
* milvusClient.userManager.selectGrant({
|
|
666
|
+
* roleName: 'roleName',
|
|
667
|
+
* object: '*',
|
|
668
|
+
* objectName: 'Collection',
|
|
669
|
+
* privilegeName: 'CreateIndex'
|
|
670
|
+
* });
|
|
671
|
+
* ```
|
|
672
|
+
*/
|
|
673
|
+
User.prototype.selectGrant = function (data) {
|
|
674
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
675
|
+
var promise;
|
|
676
|
+
return __generator(this, function (_a) {
|
|
677
|
+
switch (_a.label) {
|
|
678
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'SelectGrant', {
|
|
679
|
+
entity: {
|
|
680
|
+
role: { name: data.roleName },
|
|
681
|
+
object: { name: data.object },
|
|
682
|
+
object_name: data.objectName,
|
|
683
|
+
grantor: {
|
|
684
|
+
privilege: { name: data.privilegeName },
|
|
685
|
+
},
|
|
686
|
+
},
|
|
687
|
+
}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
688
|
+
case 1:
|
|
689
|
+
promise = _a.sent();
|
|
690
|
+
return [2 /*return*/, promise];
|
|
691
|
+
}
|
|
692
|
+
});
|
|
693
|
+
});
|
|
694
|
+
};
|
|
695
|
+
/**
|
|
696
|
+
* list all grants for a role
|
|
697
|
+
* @param data
|
|
698
|
+
* | Property | Type | Description |
|
|
699
|
+
* | :------- | :----- | :------------ |
|
|
700
|
+
* | roleName | String | role name |
|
|
701
|
+
* | timeout | number | An optional duration of time in millisecond to allow for the RPC. If it is set to undefined, the client keeps waiting until the server responds or error occurs. Default is undefined |
|
|
702
|
+
*
|
|
703
|
+
* @return
|
|
704
|
+
* | Property | Description |
|
|
705
|
+
* | :-------------| :-------- |
|
|
706
|
+
* | status | { error_code: number, reason: string }|
|
|
707
|
+
* | reason | '' |
|
|
708
|
+
*
|
|
709
|
+
* #### Example
|
|
710
|
+
*
|
|
711
|
+
* ```
|
|
712
|
+
* milvusClient.userManager.listGrants({
|
|
713
|
+
* roleName: 'roleName',
|
|
714
|
+
* });
|
|
715
|
+
* ```
|
|
716
|
+
*/
|
|
717
|
+
User.prototype.listGrants = function (data) {
|
|
718
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
719
|
+
var promise;
|
|
720
|
+
return __generator(this, function (_a) {
|
|
721
|
+
switch (_a.label) {
|
|
722
|
+
case 0: return [4 /*yield*/, (0, utils_1.promisify)(this.client, 'SelectGrant', {
|
|
723
|
+
entity: {
|
|
724
|
+
role: { name: data.roleName },
|
|
725
|
+
},
|
|
726
|
+
}, data === null || data === void 0 ? void 0 : data.timeout)];
|
|
727
|
+
case 1:
|
|
728
|
+
promise = _a.sent();
|
|
729
|
+
return [2 /*return*/, promise];
|
|
730
|
+
}
|
|
731
|
+
});
|
|
732
|
+
});
|
|
733
|
+
};
|
|
734
|
+
/**
|
|
735
|
+
* check if the role is existing
|
|
736
|
+
* @param data
|
|
737
|
+
* | Property | Type | Description |
|
|
738
|
+
* | :------- | :----- | :------------ |
|
|
739
|
+
* | roleName | String | role name |
|
|
740
|
+
* | timeout | number | An optional duration of time in millisecond to allow for the RPC. If it is set to undefined, the client keeps waiting until the server responds or error occurs. Default is undefined |
|
|
741
|
+
*
|
|
742
|
+
* @return
|
|
743
|
+
* | Property | Description |
|
|
744
|
+
* | :-------------| :-------- |
|
|
745
|
+
* | status | { error_code: number, reason: string }|
|
|
746
|
+
* | reason | '' |
|
|
747
|
+
*
|
|
748
|
+
* #### Example
|
|
749
|
+
*
|
|
750
|
+
* ```
|
|
751
|
+
* milvusClient.userManager.hasRole({
|
|
752
|
+
* roleName: 'roleName',
|
|
753
|
+
* });
|
|
754
|
+
* ```
|
|
755
|
+
*/
|
|
756
|
+
User.prototype.hasRole = function (data) {
|
|
757
|
+
return __awaiter(this, void 0, void 0, function () {
|
|
758
|
+
var result;
|
|
759
|
+
return __generator(this, function (_a) {
|
|
760
|
+
switch (_a.label) {
|
|
761
|
+
case 0: return [4 /*yield*/, this.listRoles()];
|
|
762
|
+
case 1:
|
|
763
|
+
result = _a.sent();
|
|
764
|
+
return [2 /*return*/, {
|
|
765
|
+
status: result.status,
|
|
766
|
+
hasRole: result.results.map(function (r) { return r.role.name; }).includes(data.roleName),
|
|
767
|
+
}];
|
|
768
|
+
}
|
|
769
|
+
});
|
|
770
|
+
});
|
|
771
|
+
};
|
|
233
772
|
return User;
|
|
234
773
|
}(Client_1.Client));
|
|
235
774
|
exports.User = User;
|
package/dist/milvus/User.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"User.js","sourceRoot":"","sources":["../../milvus/User.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,kCAAqC;AACrC,mCAAkC;AAClC,mDAAoD;
|
|
1
|
+
{"version":3,"file":"User.js","sourceRoot":"","sources":["../../milvus/User.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAAA,kCAAqC;AACrC,mCAAkC;AAClC,mDAAoD;AAyBpD,yCAKwB;AACxB,yCAAgD;AAEhD;IAA0B,wBAAM;IAAhC;;IAsnBA,CAAC;IArnBC;;;;;;;;;;;;;;;;;;;;;;;;OAwBG;IACG,yBAAU,GAAhB,UAAiB,IAAmB;;;;;;wBAClC,IAAI,IAAI,CAAC,QAAQ,KAAK,SAAS,IAAI,IAAI,CAAC,QAAQ,KAAK,SAAS,EAAE;4BAC9D,MAAM,IAAI,KAAK,CAAC,2BAAa,CAAC,yBAAyB,CAAC,CAAC;yBAC1D;wBACK,iBAAiB,GAAG,IAAA,uBAAc,EAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;wBACxC,qBAAM,IAAA,iBAAS,EAAC,IAAI,CAAC,MAAM,EAAE,kBAAkB,EAAE;gCAC/D,QAAQ,EAAE,IAAI,CAAC,QAAQ;gCACvB,QAAQ,EAAE,iBAAiB;6BAC5B,CAAC,EAAA;;wBAHI,OAAO,GAAG,SAGd;wBACF,sBAAO,OAAO,EAAC;;;;KAChB;IAED;;;;;;;;;;;;;;;;;;;;;;;;OAwBG;IACG,yBAAU,GAAhB,UAAiB,IAAmB;;;;;;wBACl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