Skip to content

Commit

Permalink
Deprecate BasicCommands from JedisCluster since it has no meaning
Browse files Browse the repository at this point in the history
  • Loading branch information
HeartSaVioR committed Mar 4, 2015
1 parent 3d9a0ec commit b0e1fc2
Showing 1 changed file with 80 additions and 0 deletions.
80 changes: 80 additions & 0 deletions src/main/java/redis/clients/jedis/JedisCluster.java
Original file line number Diff line number Diff line change
Expand Up @@ -1158,6 +1158,10 @@ public Long execute(Jedis connection) {
}.run(key);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String ping() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1168,6 +1172,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String quit() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1178,6 +1186,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String flushDB() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1188,6 +1200,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public Long dbSize() {
return new JedisClusterCommand<Long>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1198,6 +1214,10 @@ public Long execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String select(final int index) {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1208,6 +1228,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String flushAll() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1218,6 +1242,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String auth(final String password) {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1228,6 +1256,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String save() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1238,6 +1270,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String bgsave() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1248,6 +1284,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String bgrewriteaof() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1258,6 +1298,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public Long lastsave() {
return new JedisClusterCommand<Long>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1268,6 +1312,10 @@ public Long execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String shutdown() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1278,6 +1326,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String info() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1288,6 +1340,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String info(final String section) {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1298,6 +1354,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String slaveof(final String host, final int port) {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1308,6 +1368,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String slaveofNoOne() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1318,6 +1382,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public int getDB() {
return new JedisClusterCommand<Integer>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1328,6 +1396,10 @@ public Integer execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String debug(final DebugParams params) {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1338,6 +1410,10 @@ public String execute(Jedis connection) {
}.run(null);
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public String configResetStat() {
return new JedisClusterCommand<String>(connectionHandler, timeout, maxRedirections) {
Expand All @@ -1352,6 +1428,10 @@ public Map<String, JedisPool> getClusterNodes() {
return connectionHandler.getNodes();
}

/**
* Deprecated, BasicCommands is not fit to JedisCluster, so it'll be removed
*/
@Deprecated
@Override
public Long waitReplicas(int replicas, long timeout) {
// TODO Auto-generated method stub
Expand Down

0 comments on commit b0e1fc2

Please sign in to comment.