@valkey/valkey-glide 2.1.1 → 2.2.0-rc1
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/build-ts/BaseClient.d.ts +58 -2
- package/build-ts/BaseClient.js +111 -14
- package/build-ts/Batch.d.ts +4 -0
- package/build-ts/Batch.js +4 -0
- package/build-ts/Commands.d.ts +2 -1
- package/build-ts/Commands.js +9 -4
- package/build-ts/GlideClient.d.ts +3 -1
- package/build-ts/GlideClient.js +50 -49
- package/build-ts/GlideClusterClient.d.ts +17 -2
- package/build-ts/GlideClusterClient.js +59 -51
- package/build-ts/ProtobufMessage.d.ts +193 -1
- package/build-ts/ProtobufMessage.js +436 -5
- package/package.json +8 -8
|
@@ -4,8 +4,10 @@
|
|
|
4
4
|
*/
|
|
5
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
6
|
exports.GlideClusterClient = exports.GlideClusterClientConfiguration = void 0;
|
|
7
|
-
const
|
|
7
|
+
const native_1 = require("../build-ts/native");
|
|
8
8
|
const ProtobufMessage_1 = require("../build-ts/ProtobufMessage");
|
|
9
|
+
const BaseClient_1 = require("./BaseClient");
|
|
10
|
+
const Commands_1 = require("./Commands");
|
|
9
11
|
/* eslint-disable-next-line @typescript-eslint/no-namespace */
|
|
10
12
|
var GlideClusterClientConfiguration;
|
|
11
13
|
(function (GlideClusterClientConfiguration) {
|
|
@@ -46,7 +48,7 @@ function convertClusterGlideRecord(res, isRoutedToSingleNodeByDefault, route) {
|
|
|
46
48
|
(Boolean(route) && route !== "allPrimaries" && route !== "allNodes");
|
|
47
49
|
return isSingleNodeResponse
|
|
48
50
|
? res
|
|
49
|
-
: (0,
|
|
51
|
+
: (0, BaseClient_1.convertGlideRecordToRecord)(res);
|
|
50
52
|
}
|
|
51
53
|
/**
|
|
52
54
|
* Client used for connection to cluster servers.
|
|
@@ -54,7 +56,7 @@ function convertClusterGlideRecord(res, isRoutedToSingleNodeByDefault, route) {
|
|
|
54
56
|
*
|
|
55
57
|
* @see For full documentation refer to {@link https://github.com/valkey-io/valkey-glide/wiki/NodeJS-wrapper#cluster | Valkey Glide Wiki}.
|
|
56
58
|
*/
|
|
57
|
-
class GlideClusterClient extends
|
|
59
|
+
class GlideClusterClient extends BaseClient_1.BaseClient {
|
|
58
60
|
/**
|
|
59
61
|
* @internal
|
|
60
62
|
*/
|
|
@@ -78,6 +80,12 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
78
80
|
this.configurePubsub(options, configuration);
|
|
79
81
|
if (options.advancedConfiguration) {
|
|
80
82
|
this.configureAdvancedConfigurationBase(options.advancedConfiguration, configuration);
|
|
83
|
+
// Set refresh topology from initial nodes
|
|
84
|
+
if (options.advancedConfiguration
|
|
85
|
+
.refreshTopologyFromInitialNodes !== undefined) {
|
|
86
|
+
configuration.refreshTopologyFromInitialNodes =
|
|
87
|
+
options.advancedConfiguration.refreshTopologyFromInitialNodes;
|
|
88
|
+
}
|
|
81
89
|
}
|
|
82
90
|
return configuration;
|
|
83
91
|
}
|
|
@@ -183,7 +191,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
183
191
|
(resolveAns) => {
|
|
184
192
|
try {
|
|
185
193
|
resolve([
|
|
186
|
-
new
|
|
194
|
+
new native_1.ClusterScanCursor(resolveAns[0].toString()),
|
|
187
195
|
resolveAns[1],
|
|
188
196
|
]);
|
|
189
197
|
}
|
|
@@ -287,7 +295,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
287
295
|
* ```
|
|
288
296
|
*/
|
|
289
297
|
async customCommand(args, options) {
|
|
290
|
-
const command = (0,
|
|
298
|
+
const command = (0, Commands_1.createCustomCommand)(args);
|
|
291
299
|
return super.createWritePromise(command, options);
|
|
292
300
|
}
|
|
293
301
|
/**
|
|
@@ -384,7 +392,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
384
392
|
* ```
|
|
385
393
|
*/
|
|
386
394
|
async ping(options) {
|
|
387
|
-
return this.createWritePromise((0,
|
|
395
|
+
return this.createWritePromise((0, Commands_1.createPing)(options?.message), options);
|
|
388
396
|
}
|
|
389
397
|
/**
|
|
390
398
|
* Gets information and statistics about the server.
|
|
@@ -411,7 +419,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
411
419
|
* ```
|
|
412
420
|
*/
|
|
413
421
|
async info(options) {
|
|
414
|
-
return this.createWritePromise((0,
|
|
422
|
+
return this.createWritePromise((0, Commands_1.createInfo)(options?.sections), { decoder: BaseClient_1.Decoder.String, ...options }).then((res) => convertClusterGlideRecord(res, false, options?.route));
|
|
415
423
|
}
|
|
416
424
|
/**
|
|
417
425
|
* Gets the name of the connection to which the request is routed.
|
|
@@ -441,7 +449,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
441
449
|
* ```
|
|
442
450
|
*/
|
|
443
451
|
async clientGetName(options) {
|
|
444
|
-
return this.createWritePromise((0,
|
|
452
|
+
return this.createWritePromise((0, Commands_1.createClientGetName)(), options).then((res) => convertClusterGlideRecord(res, true, options?.route));
|
|
445
453
|
}
|
|
446
454
|
/**
|
|
447
455
|
* Rewrites the configuration file with the current configuration.
|
|
@@ -461,8 +469,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
461
469
|
* ```
|
|
462
470
|
*/
|
|
463
471
|
async configRewrite(options) {
|
|
464
|
-
return this.createWritePromise((0,
|
|
465
|
-
decoder:
|
|
472
|
+
return this.createWritePromise((0, Commands_1.createConfigRewrite)(), {
|
|
473
|
+
decoder: BaseClient_1.Decoder.String,
|
|
466
474
|
...options,
|
|
467
475
|
});
|
|
468
476
|
}
|
|
@@ -484,8 +492,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
484
492
|
* ```
|
|
485
493
|
*/
|
|
486
494
|
async configResetStat(options) {
|
|
487
|
-
return this.createWritePromise((0,
|
|
488
|
-
decoder:
|
|
495
|
+
return this.createWritePromise((0, Commands_1.createConfigResetStat)(), {
|
|
496
|
+
decoder: BaseClient_1.Decoder.String,
|
|
489
497
|
...options,
|
|
490
498
|
});
|
|
491
499
|
}
|
|
@@ -507,7 +515,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
507
515
|
* ```
|
|
508
516
|
*/
|
|
509
517
|
async clientId(options) {
|
|
510
|
-
return this.createWritePromise((0,
|
|
518
|
+
return this.createWritePromise((0, Commands_1.createClientId)(), options).then((res) => convertClusterGlideRecord(res, true, options?.route));
|
|
511
519
|
}
|
|
512
520
|
/**
|
|
513
521
|
* Reads the configuration parameters of the running server.
|
|
@@ -538,7 +546,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
538
546
|
* ```
|
|
539
547
|
*/
|
|
540
548
|
async configGet(parameters, options) {
|
|
541
|
-
return this.createWritePromise((0,
|
|
549
|
+
return this.createWritePromise((0, Commands_1.createConfigGet)(parameters), options).then((res) => (0, BaseClient_1.convertGlideRecordToRecord)(res));
|
|
542
550
|
}
|
|
543
551
|
/**
|
|
544
552
|
* Sets configuration parameters to the specified values.
|
|
@@ -560,8 +568,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
560
568
|
* ```
|
|
561
569
|
*/
|
|
562
570
|
async configSet(parameters, options) {
|
|
563
|
-
return this.createWritePromise((0,
|
|
564
|
-
decoder:
|
|
571
|
+
return this.createWritePromise((0, Commands_1.createConfigSet)(parameters), {
|
|
572
|
+
decoder: BaseClient_1.Decoder.String,
|
|
565
573
|
...options,
|
|
566
574
|
});
|
|
567
575
|
}
|
|
@@ -591,7 +599,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
591
599
|
* ```
|
|
592
600
|
*/
|
|
593
601
|
async echo(message, options) {
|
|
594
|
-
return this.createWritePromise((0,
|
|
602
|
+
return this.createWritePromise((0, Commands_1.createEcho)(message), options).then((res) => convertClusterGlideRecord(res, true, options?.route));
|
|
595
603
|
}
|
|
596
604
|
/**
|
|
597
605
|
* Returns the server time.
|
|
@@ -624,7 +632,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
624
632
|
* ```
|
|
625
633
|
*/
|
|
626
634
|
async time(options) {
|
|
627
|
-
return this.createWritePromise((0,
|
|
635
|
+
return this.createWritePromise((0, Commands_1.createTime)(), options).then((res) => convertClusterGlideRecord(res, true, options?.route));
|
|
628
636
|
}
|
|
629
637
|
/**
|
|
630
638
|
* Displays a piece of generative computer art and the server version.
|
|
@@ -643,7 +651,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
643
651
|
* ```
|
|
644
652
|
*/
|
|
645
653
|
async lolwut(options) {
|
|
646
|
-
return this.createWritePromise((0,
|
|
654
|
+
return this.createWritePromise((0, Commands_1.createLolwut)(options), options).then((res) => convertClusterGlideRecord(res, true, options?.route));
|
|
647
655
|
}
|
|
648
656
|
/**
|
|
649
657
|
* Invokes a previously loaded function.
|
|
@@ -665,7 +673,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
665
673
|
* ```
|
|
666
674
|
*/
|
|
667
675
|
async fcallWithRoute(func, args, options) {
|
|
668
|
-
return this.createWritePromise((0,
|
|
676
|
+
return this.createWritePromise((0, Commands_1.createFCall)(func, [], args), options).then((res) => convertClusterGlideRecord(res, true, options?.route));
|
|
669
677
|
}
|
|
670
678
|
/**
|
|
671
679
|
* Invokes a previously loaded read-only function.
|
|
@@ -688,7 +696,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
688
696
|
* ```
|
|
689
697
|
*/
|
|
690
698
|
async fcallReadonlyWithRoute(func, args, options) {
|
|
691
|
-
return this.createWritePromise((0,
|
|
699
|
+
return this.createWritePromise((0, Commands_1.createFCallReadOnly)(func, [], args), options).then((res) => convertClusterGlideRecord(res, true, options?.route));
|
|
692
700
|
}
|
|
693
701
|
/**
|
|
694
702
|
* Deletes a library and all its functions.
|
|
@@ -708,8 +716,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
708
716
|
* ```
|
|
709
717
|
*/
|
|
710
718
|
async functionDelete(libraryCode, options) {
|
|
711
|
-
return this.createWritePromise((0,
|
|
712
|
-
decoder:
|
|
719
|
+
return this.createWritePromise((0, Commands_1.createFunctionDelete)(libraryCode), {
|
|
720
|
+
decoder: BaseClient_1.Decoder.String,
|
|
713
721
|
...options,
|
|
714
722
|
});
|
|
715
723
|
}
|
|
@@ -735,7 +743,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
735
743
|
* ```
|
|
736
744
|
*/
|
|
737
745
|
async functionLoad(libraryCode, options) {
|
|
738
|
-
return this.createWritePromise((0,
|
|
746
|
+
return this.createWritePromise((0, Commands_1.createFunctionLoad)(libraryCode, options?.replace), options);
|
|
739
747
|
}
|
|
740
748
|
/**
|
|
741
749
|
* Deletes all function libraries.
|
|
@@ -755,8 +763,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
755
763
|
* ```
|
|
756
764
|
*/
|
|
757
765
|
async functionFlush(options) {
|
|
758
|
-
return this.createWritePromise((0,
|
|
759
|
-
decoder:
|
|
766
|
+
return this.createWritePromise((0, Commands_1.createFunctionFlush)(options?.mode), {
|
|
767
|
+
decoder: BaseClient_1.Decoder.String,
|
|
760
768
|
...options,
|
|
761
769
|
});
|
|
762
770
|
}
|
|
@@ -791,13 +799,13 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
791
799
|
* ```
|
|
792
800
|
*/
|
|
793
801
|
async functionList(options) {
|
|
794
|
-
return this.createWritePromise((0,
|
|
802
|
+
return this.createWritePromise((0, Commands_1.createFunctionList)(options), options).then((res) => res.length == 0
|
|
795
803
|
? res // no libs
|
|
796
804
|
: (Array.isArray(res[0])
|
|
797
805
|
? // single node response
|
|
798
|
-
res.map(
|
|
806
|
+
res.map(BaseClient_1.convertGlideRecordToRecord)
|
|
799
807
|
: // multi node response
|
|
800
|
-
(0,
|
|
808
|
+
(0, BaseClient_1.convertGlideRecordToRecord)(res)));
|
|
801
809
|
}
|
|
802
810
|
/**
|
|
803
811
|
* Returns information about the function that's currently running and information about the
|
|
@@ -849,7 +857,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
849
857
|
* ```
|
|
850
858
|
*/
|
|
851
859
|
async functionStats(options) {
|
|
852
|
-
return this.createWritePromise((0,
|
|
860
|
+
return this.createWritePromise((0, Commands_1.createFunctionStats)(), options).then((res) => (0, BaseClient_1.convertGlideRecordToRecord)(res));
|
|
853
861
|
}
|
|
854
862
|
/**
|
|
855
863
|
* Kills a function that is currently executing.
|
|
@@ -867,8 +875,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
867
875
|
* ```
|
|
868
876
|
*/
|
|
869
877
|
async functionKill(options) {
|
|
870
|
-
return this.createWritePromise((0,
|
|
871
|
-
decoder:
|
|
878
|
+
return this.createWritePromise((0, Commands_1.createFunctionKill)(), {
|
|
879
|
+
decoder: BaseClient_1.Decoder.String,
|
|
872
880
|
...options,
|
|
873
881
|
});
|
|
874
882
|
}
|
|
@@ -888,7 +896,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
888
896
|
* ```
|
|
889
897
|
*/
|
|
890
898
|
async functionDump(options) {
|
|
891
|
-
return this.createWritePromise((0,
|
|
899
|
+
return this.createWritePromise((0, Commands_1.createFunctionDump)(), { decoder: BaseClient_1.Decoder.Bytes, ...options }).then((res) => convertClusterGlideRecord(res, true, options?.route));
|
|
892
900
|
}
|
|
893
901
|
/**
|
|
894
902
|
* Restores libraries from the serialized payload returned by {@link functionDump}.
|
|
@@ -909,7 +917,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
909
917
|
* ```
|
|
910
918
|
*/
|
|
911
919
|
async functionRestore(payload, options) {
|
|
912
|
-
return this.createWritePromise((0,
|
|
920
|
+
return this.createWritePromise((0, Commands_1.createFunctionRestore)(payload, options?.policy), { decoder: BaseClient_1.Decoder.String, ...options });
|
|
913
921
|
}
|
|
914
922
|
/**
|
|
915
923
|
* Deletes all the keys of all the existing databases. This command never fails.
|
|
@@ -930,8 +938,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
930
938
|
* ```
|
|
931
939
|
*/
|
|
932
940
|
async flushall(options) {
|
|
933
|
-
return this.createWritePromise((0,
|
|
934
|
-
decoder:
|
|
941
|
+
return this.createWritePromise((0, Commands_1.createFlushAll)(options?.mode), {
|
|
942
|
+
decoder: BaseClient_1.Decoder.String,
|
|
935
943
|
...options,
|
|
936
944
|
});
|
|
937
945
|
}
|
|
@@ -954,8 +962,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
954
962
|
* ```
|
|
955
963
|
*/
|
|
956
964
|
async flushdb(options) {
|
|
957
|
-
return this.createWritePromise((0,
|
|
958
|
-
decoder:
|
|
965
|
+
return this.createWritePromise((0, Commands_1.createFlushDB)(options?.mode), {
|
|
966
|
+
decoder: BaseClient_1.Decoder.String,
|
|
959
967
|
...options,
|
|
960
968
|
});
|
|
961
969
|
}
|
|
@@ -977,7 +985,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
977
985
|
* ```
|
|
978
986
|
*/
|
|
979
987
|
async dbsize(options) {
|
|
980
|
-
return this.createWritePromise((0,
|
|
988
|
+
return this.createWritePromise((0, Commands_1.createDBSize)(), options);
|
|
981
989
|
}
|
|
982
990
|
/** Publish a message on pubsub channel.
|
|
983
991
|
* This command aggregates PUBLISH and SPUBLISH commands functionalities.
|
|
@@ -1006,7 +1014,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
1006
1014
|
* ```
|
|
1007
1015
|
*/
|
|
1008
1016
|
async publish(message, channel, sharded = false) {
|
|
1009
|
-
return this.createWritePromise((0,
|
|
1017
|
+
return this.createWritePromise((0, Commands_1.createPublish)(message, channel, sharded));
|
|
1010
1018
|
}
|
|
1011
1019
|
/**
|
|
1012
1020
|
* Lists the currently active shard channels.
|
|
@@ -1031,7 +1039,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
1031
1039
|
* ```
|
|
1032
1040
|
*/
|
|
1033
1041
|
async pubsubShardChannels(options) {
|
|
1034
|
-
return this.createWritePromise((0,
|
|
1042
|
+
return this.createWritePromise((0, Commands_1.createPubsubShardChannels)(options?.pattern), options);
|
|
1035
1043
|
}
|
|
1036
1044
|
/**
|
|
1037
1045
|
* Returns the number of subscribers (exclusive of clients subscribed to patterns) for the specified shard channels.
|
|
@@ -1054,7 +1062,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
1054
1062
|
* ```
|
|
1055
1063
|
*/
|
|
1056
1064
|
async pubsubShardNumSub(channels, options) {
|
|
1057
|
-
return this.createWritePromise((0,
|
|
1065
|
+
return this.createWritePromise((0, Commands_1.createPubSubShardNumSub)(channels), options).then((res) => res.map((r) => {
|
|
1058
1066
|
return { channel: r.key, numSub: r.value };
|
|
1059
1067
|
}));
|
|
1060
1068
|
}
|
|
@@ -1076,7 +1084,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
1076
1084
|
* ```
|
|
1077
1085
|
*/
|
|
1078
1086
|
async lastsave(options) {
|
|
1079
|
-
return this.createWritePromise((0,
|
|
1087
|
+
return this.createWritePromise((0, Commands_1.createLastSave)(), options).then((res) => convertClusterGlideRecord(res, true, options?.route));
|
|
1080
1088
|
}
|
|
1081
1089
|
/**
|
|
1082
1090
|
* Returns a random existing key name.
|
|
@@ -1095,7 +1103,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
1095
1103
|
* ```
|
|
1096
1104
|
*/
|
|
1097
1105
|
async randomKey(options) {
|
|
1098
|
-
return this.createWritePromise((0,
|
|
1106
|
+
return this.createWritePromise((0, Commands_1.createRandomKey)(), options);
|
|
1099
1107
|
}
|
|
1100
1108
|
/**
|
|
1101
1109
|
* Flushes all the previously watched keys for a transaction. Executing a transaction will
|
|
@@ -1115,8 +1123,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
1115
1123
|
* ```
|
|
1116
1124
|
*/
|
|
1117
1125
|
async unwatch(options) {
|
|
1118
|
-
return this.createWritePromise((0,
|
|
1119
|
-
decoder:
|
|
1126
|
+
return this.createWritePromise((0, Commands_1.createUnWatch)(), {
|
|
1127
|
+
decoder: BaseClient_1.Decoder.String,
|
|
1120
1128
|
...options,
|
|
1121
1129
|
});
|
|
1122
1130
|
}
|
|
@@ -1186,7 +1194,7 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
1186
1194
|
* ```
|
|
1187
1195
|
*/
|
|
1188
1196
|
async scriptExists(sha1s, options) {
|
|
1189
|
-
return this.createWritePromise((0,
|
|
1197
|
+
return this.createWritePromise((0, Commands_1.createScriptExists)(sha1s), options);
|
|
1190
1198
|
}
|
|
1191
1199
|
/**
|
|
1192
1200
|
* Flushes the Lua scripts cache.
|
|
@@ -1205,8 +1213,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
1205
1213
|
* ```
|
|
1206
1214
|
*/
|
|
1207
1215
|
async scriptFlush(options) {
|
|
1208
|
-
return this.createWritePromise((0,
|
|
1209
|
-
decoder:
|
|
1216
|
+
return this.createWritePromise((0, Commands_1.createScriptFlush)(options?.mode), {
|
|
1217
|
+
decoder: BaseClient_1.Decoder.String,
|
|
1210
1218
|
...options,
|
|
1211
1219
|
});
|
|
1212
1220
|
}
|
|
@@ -1226,8 +1234,8 @@ class GlideClusterClient extends _1.BaseClient {
|
|
|
1226
1234
|
* ```
|
|
1227
1235
|
*/
|
|
1228
1236
|
async scriptKill(options) {
|
|
1229
|
-
return this.createWritePromise((0,
|
|
1230
|
-
decoder:
|
|
1237
|
+
return this.createWritePromise((0, Commands_1.createScriptKill)(), {
|
|
1238
|
+
decoder: BaseClient_1.Decoder.String,
|
|
1231
1239
|
...options,
|
|
1232
1240
|
});
|
|
1233
1241
|
}
|
|
@@ -1338,6 +1338,69 @@ export namespace command_request {
|
|
|
1338
1338
|
public static getTypeUrl(typeUrlPrefix?: string): string;
|
|
1339
1339
|
}
|
|
1340
1340
|
|
|
1341
|
+
/** Properties of a RefreshIamToken. */
|
|
1342
|
+
interface IRefreshIamToken {
|
|
1343
|
+
}
|
|
1344
|
+
|
|
1345
|
+
/** Represents a RefreshIamToken. */
|
|
1346
|
+
class RefreshIamToken implements IRefreshIamToken {
|
|
1347
|
+
|
|
1348
|
+
/**
|
|
1349
|
+
* Constructs a new RefreshIamToken.
|
|
1350
|
+
* @param [properties] Properties to set
|
|
1351
|
+
*/
|
|
1352
|
+
constructor(properties?: command_request.IRefreshIamToken);
|
|
1353
|
+
|
|
1354
|
+
/**
|
|
1355
|
+
* Creates a new RefreshIamToken instance using the specified properties.
|
|
1356
|
+
* @param [properties] Properties to set
|
|
1357
|
+
* @returns RefreshIamToken instance
|
|
1358
|
+
*/
|
|
1359
|
+
public static create(properties?: command_request.IRefreshIamToken): command_request.RefreshIamToken;
|
|
1360
|
+
|
|
1361
|
+
/**
|
|
1362
|
+
* Encodes the specified RefreshIamToken message. Does not implicitly {@link command_request.RefreshIamToken.verify|verify} messages.
|
|
1363
|
+
* @param message RefreshIamToken message or plain object to encode
|
|
1364
|
+
* @param [writer] Writer to encode to
|
|
1365
|
+
* @returns Writer
|
|
1366
|
+
*/
|
|
1367
|
+
public static encode(message: command_request.IRefreshIamToken, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
1368
|
+
|
|
1369
|
+
/**
|
|
1370
|
+
* Encodes the specified RefreshIamToken message, length delimited. Does not implicitly {@link command_request.RefreshIamToken.verify|verify} messages.
|
|
1371
|
+
* @param message RefreshIamToken message or plain object to encode
|
|
1372
|
+
* @param [writer] Writer to encode to
|
|
1373
|
+
* @returns Writer
|
|
1374
|
+
*/
|
|
1375
|
+
public static encodeDelimited(message: command_request.IRefreshIamToken, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
1376
|
+
|
|
1377
|
+
/**
|
|
1378
|
+
* Decodes a RefreshIamToken message from the specified reader or buffer.
|
|
1379
|
+
* @param reader Reader or buffer to decode from
|
|
1380
|
+
* @param [length] Message length if known beforehand
|
|
1381
|
+
* @returns RefreshIamToken
|
|
1382
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
1383
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
1384
|
+
*/
|
|
1385
|
+
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): command_request.RefreshIamToken;
|
|
1386
|
+
|
|
1387
|
+
/**
|
|
1388
|
+
* Decodes a RefreshIamToken message from the specified reader or buffer, length delimited.
|
|
1389
|
+
* @param reader Reader or buffer to decode from
|
|
1390
|
+
* @returns RefreshIamToken
|
|
1391
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
1392
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
1393
|
+
*/
|
|
1394
|
+
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): command_request.RefreshIamToken;
|
|
1395
|
+
|
|
1396
|
+
/**
|
|
1397
|
+
* Gets the default type url for RefreshIamToken
|
|
1398
|
+
* @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
|
1399
|
+
* @returns The default type url
|
|
1400
|
+
*/
|
|
1401
|
+
public static getTypeUrl(typeUrlPrefix?: string): string;
|
|
1402
|
+
}
|
|
1403
|
+
|
|
1341
1404
|
/** Properties of a CommandRequest. */
|
|
1342
1405
|
interface ICommandRequest {
|
|
1343
1406
|
|
|
@@ -1362,6 +1425,9 @@ export namespace command_request {
|
|
|
1362
1425
|
/** CommandRequest updateConnectionPassword */
|
|
1363
1426
|
updateConnectionPassword?: (command_request.IUpdateConnectionPassword|null);
|
|
1364
1427
|
|
|
1428
|
+
/** CommandRequest refreshIamToken */
|
|
1429
|
+
refreshIamToken?: (command_request.IRefreshIamToken|null);
|
|
1430
|
+
|
|
1365
1431
|
/** CommandRequest route */
|
|
1366
1432
|
route?: (command_request.IRoutes|null);
|
|
1367
1433
|
|
|
@@ -1399,6 +1465,9 @@ export namespace command_request {
|
|
|
1399
1465
|
/** CommandRequest updateConnectionPassword. */
|
|
1400
1466
|
public updateConnectionPassword?: (command_request.IUpdateConnectionPassword|null);
|
|
1401
1467
|
|
|
1468
|
+
/** CommandRequest refreshIamToken. */
|
|
1469
|
+
public refreshIamToken?: (command_request.IRefreshIamToken|null);
|
|
1470
|
+
|
|
1402
1471
|
/** CommandRequest route. */
|
|
1403
1472
|
public route?: (command_request.IRoutes|null);
|
|
1404
1473
|
|
|
@@ -1406,7 +1475,7 @@ export namespace command_request {
|
|
|
1406
1475
|
public rootSpanPtr?: (number|Long|null);
|
|
1407
1476
|
|
|
1408
1477
|
/** CommandRequest command. */
|
|
1409
|
-
public command?: ("singleCommand"|"batch"|"scriptInvocation"|"scriptInvocationPointers"|"clusterScan"|"updateConnectionPassword");
|
|
1478
|
+
public command?: ("singleCommand"|"batch"|"scriptInvocation"|"scriptInvocationPointers"|"clusterScan"|"updateConnectionPassword"|"refreshIamToken");
|
|
1410
1479
|
|
|
1411
1480
|
/** CommandRequest _rootSpanPtr. */
|
|
1412
1481
|
public _rootSpanPtr?: "rootSpanPtr";
|
|
@@ -1564,6 +1633,9 @@ export namespace connection_request {
|
|
|
1564
1633
|
|
|
1565
1634
|
/** AuthenticationInfo username */
|
|
1566
1635
|
username?: (string|null);
|
|
1636
|
+
|
|
1637
|
+
/** AuthenticationInfo iamCredentials */
|
|
1638
|
+
iamCredentials?: (connection_request.IIamCredentials|null);
|
|
1567
1639
|
}
|
|
1568
1640
|
|
|
1569
1641
|
/** Represents an AuthenticationInfo. */
|
|
@@ -1581,6 +1653,12 @@ export namespace connection_request {
|
|
|
1581
1653
|
/** AuthenticationInfo username. */
|
|
1582
1654
|
public username: string;
|
|
1583
1655
|
|
|
1656
|
+
/** AuthenticationInfo iamCredentials. */
|
|
1657
|
+
public iamCredentials?: (connection_request.IIamCredentials|null);
|
|
1658
|
+
|
|
1659
|
+
/** AuthenticationInfo _iamCredentials. */
|
|
1660
|
+
public _iamCredentials?: "iamCredentials";
|
|
1661
|
+
|
|
1584
1662
|
/**
|
|
1585
1663
|
* Creates a new AuthenticationInfo instance using the specified properties.
|
|
1586
1664
|
* @param [properties] Properties to set
|
|
@@ -1631,6 +1709,102 @@ export namespace connection_request {
|
|
|
1631
1709
|
public static getTypeUrl(typeUrlPrefix?: string): string;
|
|
1632
1710
|
}
|
|
1633
1711
|
|
|
1712
|
+
/** ServiceType enum. */
|
|
1713
|
+
enum ServiceType {
|
|
1714
|
+
ELASTICACHE = 0,
|
|
1715
|
+
MEMORYDB = 1
|
|
1716
|
+
}
|
|
1717
|
+
|
|
1718
|
+
/** Properties of an IamCredentials. */
|
|
1719
|
+
interface IIamCredentials {
|
|
1720
|
+
|
|
1721
|
+
/** IamCredentials clusterName */
|
|
1722
|
+
clusterName?: (string|null);
|
|
1723
|
+
|
|
1724
|
+
/** IamCredentials region */
|
|
1725
|
+
region?: (string|null);
|
|
1726
|
+
|
|
1727
|
+
/** IamCredentials serviceType */
|
|
1728
|
+
serviceType?: (connection_request.ServiceType|null);
|
|
1729
|
+
|
|
1730
|
+
/** IamCredentials refreshIntervalSeconds */
|
|
1731
|
+
refreshIntervalSeconds?: (number|null);
|
|
1732
|
+
}
|
|
1733
|
+
|
|
1734
|
+
/** Represents an IamCredentials. */
|
|
1735
|
+
class IamCredentials implements IIamCredentials {
|
|
1736
|
+
|
|
1737
|
+
/**
|
|
1738
|
+
* Constructs a new IamCredentials.
|
|
1739
|
+
* @param [properties] Properties to set
|
|
1740
|
+
*/
|
|
1741
|
+
constructor(properties?: connection_request.IIamCredentials);
|
|
1742
|
+
|
|
1743
|
+
/** IamCredentials clusterName. */
|
|
1744
|
+
public clusterName: string;
|
|
1745
|
+
|
|
1746
|
+
/** IamCredentials region. */
|
|
1747
|
+
public region: string;
|
|
1748
|
+
|
|
1749
|
+
/** IamCredentials serviceType. */
|
|
1750
|
+
public serviceType: connection_request.ServiceType;
|
|
1751
|
+
|
|
1752
|
+
/** IamCredentials refreshIntervalSeconds. */
|
|
1753
|
+
public refreshIntervalSeconds?: (number|null);
|
|
1754
|
+
|
|
1755
|
+
/** IamCredentials _refreshIntervalSeconds. */
|
|
1756
|
+
public _refreshIntervalSeconds?: "refreshIntervalSeconds";
|
|
1757
|
+
|
|
1758
|
+
/**
|
|
1759
|
+
* Creates a new IamCredentials instance using the specified properties.
|
|
1760
|
+
* @param [properties] Properties to set
|
|
1761
|
+
* @returns IamCredentials instance
|
|
1762
|
+
*/
|
|
1763
|
+
public static create(properties?: connection_request.IIamCredentials): connection_request.IamCredentials;
|
|
1764
|
+
|
|
1765
|
+
/**
|
|
1766
|
+
* Encodes the specified IamCredentials message. Does not implicitly {@link connection_request.IamCredentials.verify|verify} messages.
|
|
1767
|
+
* @param message IamCredentials message or plain object to encode
|
|
1768
|
+
* @param [writer] Writer to encode to
|
|
1769
|
+
* @returns Writer
|
|
1770
|
+
*/
|
|
1771
|
+
public static encode(message: connection_request.IIamCredentials, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
1772
|
+
|
|
1773
|
+
/**
|
|
1774
|
+
* Encodes the specified IamCredentials message, length delimited. Does not implicitly {@link connection_request.IamCredentials.verify|verify} messages.
|
|
1775
|
+
* @param message IamCredentials message or plain object to encode
|
|
1776
|
+
* @param [writer] Writer to encode to
|
|
1777
|
+
* @returns Writer
|
|
1778
|
+
*/
|
|
1779
|
+
public static encodeDelimited(message: connection_request.IIamCredentials, writer?: $protobuf.Writer): $protobuf.Writer;
|
|
1780
|
+
|
|
1781
|
+
/**
|
|
1782
|
+
* Decodes an IamCredentials message from the specified reader or buffer.
|
|
1783
|
+
* @param reader Reader or buffer to decode from
|
|
1784
|
+
* @param [length] Message length if known beforehand
|
|
1785
|
+
* @returns IamCredentials
|
|
1786
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
1787
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
1788
|
+
*/
|
|
1789
|
+
public static decode(reader: ($protobuf.Reader|Uint8Array), length?: number): connection_request.IamCredentials;
|
|
1790
|
+
|
|
1791
|
+
/**
|
|
1792
|
+
* Decodes an IamCredentials message from the specified reader or buffer, length delimited.
|
|
1793
|
+
* @param reader Reader or buffer to decode from
|
|
1794
|
+
* @returns IamCredentials
|
|
1795
|
+
* @throws {Error} If the payload is not a reader or valid buffer
|
|
1796
|
+
* @throws {$protobuf.util.ProtocolError} If required fields are missing
|
|
1797
|
+
*/
|
|
1798
|
+
public static decodeDelimited(reader: ($protobuf.Reader|Uint8Array)): connection_request.IamCredentials;
|
|
1799
|
+
|
|
1800
|
+
/**
|
|
1801
|
+
* Gets the default type url for IamCredentials
|
|
1802
|
+
* @param [typeUrlPrefix] your custom typeUrlPrefix(default "type.googleapis.com")
|
|
1803
|
+
* @returns The default type url
|
|
1804
|
+
*/
|
|
1805
|
+
public static getTypeUrl(typeUrlPrefix?: string): string;
|
|
1806
|
+
}
|
|
1807
|
+
|
|
1634
1808
|
/** ProtocolVersion enum. */
|
|
1635
1809
|
enum ProtocolVersion {
|
|
1636
1810
|
RESP3 = 0,
|
|
@@ -1967,6 +2141,15 @@ export namespace connection_request {
|
|
|
1967
2141
|
|
|
1968
2142
|
/** ConnectionRequest lazyConnect */
|
|
1969
2143
|
lazyConnect?: (boolean|null);
|
|
2144
|
+
|
|
2145
|
+
/** ConnectionRequest refreshTopologyFromInitialNodes */
|
|
2146
|
+
refreshTopologyFromInitialNodes?: (boolean|null);
|
|
2147
|
+
|
|
2148
|
+
/** ConnectionRequest libName */
|
|
2149
|
+
libName?: (string|null);
|
|
2150
|
+
|
|
2151
|
+
/** ConnectionRequest rootCerts */
|
|
2152
|
+
rootCerts?: (Uint8Array[]|null);
|
|
1970
2153
|
}
|
|
1971
2154
|
|
|
1972
2155
|
/** Represents a ConnectionRequest. */
|
|
@@ -2029,6 +2212,15 @@ export namespace connection_request {
|
|
|
2029
2212
|
/** ConnectionRequest lazyConnect. */
|
|
2030
2213
|
public lazyConnect: boolean;
|
|
2031
2214
|
|
|
2215
|
+
/** ConnectionRequest refreshTopologyFromInitialNodes. */
|
|
2216
|
+
public refreshTopologyFromInitialNodes: boolean;
|
|
2217
|
+
|
|
2218
|
+
/** ConnectionRequest libName. */
|
|
2219
|
+
public libName: string;
|
|
2220
|
+
|
|
2221
|
+
/** ConnectionRequest rootCerts. */
|
|
2222
|
+
public rootCerts: Uint8Array[];
|
|
2223
|
+
|
|
2032
2224
|
/** ConnectionRequest periodicChecks. */
|
|
2033
2225
|
public periodicChecks?: ("periodicChecksManualInterval"|"periodicChecksDisabled");
|
|
2034
2226
|
|