Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
victoriaum committed Feb 6, 2023
1 parent 60b5108 commit 9f339bf
Showing 1 changed file with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,10 @@ public CapacityReport getReport(Integer limit) {
@Override
public Long getRank(Long siteId) {
// START Challenge #4
return -2L;
try(Jedis jedis = jedisPool.getResource()) {
String key = RedisSchema.getCapacityRankingKey();
return jedis.zrevrank(key, String.valueOf(siteId));
}
// END Challenge #4
}
}

0 comments on commit 9f339bf

Please sign in to comment.