File tree 3 files changed +32
-0
lines changed
main/java/redis/clients/jedis
test/java/redis/clients/jedis/commands/jedis
3 files changed +32
-0
lines changed Original file line number Diff line number Diff line change @@ -4310,6 +4310,20 @@ public String clientNoEvictOff() {
4310
4310
return connection .getBulkReply ();
4311
4311
}
4312
4312
4313
+ @ Override
4314
+ public String clientNoTouchOn () {
4315
+ checkIsInMultiOrPipeline ();
4316
+ connection .sendCommand (CLIENT , "NO-TOUCH" , "ON" );
4317
+ return connection .getStatusCodeReply ();
4318
+ }
4319
+
4320
+ @ Override
4321
+ public String clientNoTouchOff () {
4322
+ checkIsInMultiOrPipeline ();
4323
+ connection .sendCommand (CLIENT , "NO-TOUCH" , "OFF" );
4324
+ return connection .getStatusCodeReply ();
4325
+ }
4326
+
4313
4327
public List <String > time () {
4314
4328
checkIsInMultiOrPipeline ();
4315
4329
connection .sendCommand (Command .TIME );
Original file line number Diff line number Diff line change @@ -158,4 +158,16 @@ public interface ClientCommands {
158
158
* @return OK
159
159
*/
160
160
String clientNoEvictOff ();
161
+
162
+ /**
163
+ * Turn on <a href="https://redis.io/commands/client-no-touch/">CLIENT NO-TOUCH</a>
164
+ * @return OK
165
+ */
166
+ String clientNoTouchOn ();
167
+
168
+ /**
169
+ * Turn off <a href="https://redis.io/commands/client-no-touch/">CLIENT NO-TOUCH</a>
170
+ * @return OK
171
+ */
172
+ String clientNoTouchOff ();
161
173
}
Original file line number Diff line number Diff line change @@ -356,6 +356,12 @@ public void clientNoEvict() {
356
356
assertEquals ("OK" , jedis .clientNoEvictOff ());
357
357
}
358
358
359
+ @ Test
360
+ public void clientNoTouch () {
361
+ assertEquals ("OK" , jedis .clientNoTouchOn ());
362
+ assertEquals ("OK" , jedis .clientNoTouchOff ());
363
+ }
364
+
359
365
@ Test
360
366
public void memoryDoctorString () {
361
367
String memoryInfo = jedis .memoryDoctor ();
You can’t perform that action at this time.
0 commit comments