本文整理了Java中redis.clients.jedis.Jedis.zrangeWithScores()
方法的一些代码示例,展示了Jedis.zrangeWithScores()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Jedis.zrangeWithScores()
方法的具体详情如下:
包路径:redis.clients.jedis.Jedis
类名称:Jedis
方法名:zrangeWithScores
暂无
代码示例来源:origin: sohutv/cachecloud
@Override
public Set<Tuple> execute(Jedis connection) {
return connection.zrangeWithScores(key, start, end);
}
}.runBinary(key);
代码示例来源:origin: sohutv/cachecloud
@Override
public Set<Tuple> execute(Jedis connection) {
return connection.zrangeWithScores(key, start, end);
}
}.run(key);
代码示例来源:origin: sohutv/cachecloud
@Override
public Set<Tuple> execute(Jedis connection) {
return connection.zrangeWithScores(keyByte, start, end);
}
}.runBinary(keyByte);
代码示例来源:origin: sohutv/cachecloud
@Override
public Set<Tuple> zrangeWithScores(byte[] key, long start, long end) {
Jedis j = getShard(key);
return j.zrangeWithScores(key, start, end);
}
代码示例来源:origin: sohutv/cachecloud
@Override
public Set<Tuple> zrangeWithScores(String key, long start, long end) {
Jedis j = getShard(key);
return j.zrangeWithScores(key, start, end);
}
代码示例来源:origin: caoxinyu/RedisClient
@Override
protected void command() {
jedis.select(db);
page = jedis.zrangeWithScores(key, start, end);
}
代码示例来源:origin: caoxinyu/RedisClient
@Override
protected void command() {
jedis.select(db);
values = jedis.zrangeWithScores(key, 0, -1);
}
代码示例来源:origin: Netflix/conductor
@Override
public Set<Tuple> zrangeWithScores(String key, long start, long end) {
Jedis jedis = null;
try {
jedis = jedisPool.getResource();
return jedis.zrangeWithScores(key, start, end);
} finally {
if (jedis != null)
jedis.close();
}
}
代码示例来源:origin: signalapp/Signal-Server
private void persistQueue(ReplicatedJedisPool jedisPool, Key key) throws IOException {
Timer.Context timer = persistQueueTimer.time();
int messagesPersistedCount = 0;
try (Jedis jedis = jedisPool.getWriteResource()) {
while (true) {
jedis.setex(key.getUserMessageQueuePersistInProgress(), 30, "1".getBytes());
Set<Tuple> messages = jedis.zrangeWithScores(key.getUserMessageQueue(), 0, CHUNK_SIZE);
for (Tuple message : messages) {
persistMessage(key, (long)message.getScore(), message.getBinaryElement());
messagesPersistedCount++;
}
if (messages.size() < CHUNK_SIZE) {
jedis.del(key.getUserMessageQueuePersistInProgress());
return;
}
}
} finally {
timer.stop();
queueSizeHistogram.update(messagesPersistedCount);
}
}
代码示例来源:origin: spring-projects/spring-data-redis
@Override
public Set<Tuple> zRangeWithScores(byte[] key, long start, long end) {
Assert.notNull(key, "Key must not be null!");
try {
if (isPipelined()) {
pipeline(connection.newJedisResult(connection.getRequiredPipeline().zrangeWithScores(key, start, end),
JedisConverters.tupleSetToTupleSet()));
return null;
}
if (isQueueing()) {
transaction(connection.newJedisResult(connection.getRequiredTransaction().zrangeWithScores(key, start, end),
JedisConverters.tupleSetToTupleSet()));
return null;
}
return JedisConverters.toTupleSet(connection.getJedis().zrangeWithScores(key, start, end));
} catch (Exception ex) {
throw convertJedisAccessException(ex);
}
}
代码示例来源:origin: tangyanbo/springmore
@Override
public Set<Tuple> action(Jedis jedis) {
return jedis.zrangeWithScores(key, start, end);
}
});
代码示例来源:origin: com.github.sogyf/goja-mvt
@Override
public Set<Tuple> action(Jedis jedis) {
return jedis.zrangeWithScores(key, start, end);
}
});
代码示例来源:origin: io.leopard/leopard-redis
@Override
public Object execute(Jedis jedis) {
return jedis.zrangeWithScores(key, start, end);
}
});
代码示例来源:origin: com.netflix.spinnaker.kork/kork-jedis
@Override
public Set<Tuple> zrangeWithScores(String key, long start, long end) {
String command = "zrangeWithScores";
return instrumented(command, () -> delegated.zrangeWithScores(key, start, end));
}
代码示例来源:origin: mindwind/craft-atom
private Map<String, Double> zrangewithscores0(Jedis j, String key, long start, long stop) {
Set<Tuple> set = j.zrangeWithScores(key, start, stop);
Map<String, Double> map = convert4zrangewithscores(set);
return map;
}
代码示例来源:origin: com.netflix.spinnaker.kork/kork-jedis
@Override
public Set<Tuple> zrangeWithScores(byte[] key, long start, long end) {
String command = "zrangeWithScores";
return instrumented(command, () -> delegated.zrangeWithScores(key, start, end));
}
代码示例来源:origin: org.nutz/nutz-integration-jedis
public Set<Tuple> zrangeWithScores(String key, long start, long end) {
Jedis jedis = getJedis();
try {
return jedis.zrangeWithScores(key, start, end);
} finally {Streams.safeClose(jedis);}
}
代码示例来源:origin: com.netflix.conductor/conductor-redis-persistence
@Override
public Set<Tuple> zrangeWithScores(String key, long start, long end) {
Jedis jedis = null;
try {
jedis = jedisPool.getResource();
return jedis.zrangeWithScores(key, start, end);
} finally {
if (jedis != null)
jedis.close();
}
}
代码示例来源:origin: org.nutz/nutz-integration-jedis
public Set<Tuple> zrangeWithScores(byte[] key, long start, long end) {
Jedis jedis = getJedis();
try {
return jedis.zrangeWithScores(key, start, end);
} finally {Streams.safeClose(jedis);}
}
代码示例来源:origin: Baqend/Orestes-Bloomfilter
@Override
public TimeMap<String> getExpirationMap() {
try (Jedis jedis = pool.getResource()) {
return jedis.zrangeWithScores(keys.EXPIRATION_QUEUE_KEY.getBytes(), 0, -1)
.stream()
.collect(TimeMap.collectMillis(
tuple -> msgPack.decodeItem(tuple.getBinaryElement()),
tuple -> (long) tuple.getScore()
));
}
}
内容来源于网络,如有侵权,请联系作者删除!