APISonar


io.lettuce.core.cluster.api.sync.RedisAdvancedClusterCommands.time

> io > lettuce > core > cluster > api > sync > RedisAdvancedClusterCommands > time
io APIs lettuce APIs core APIs cluster APIs api APIs sync APIs RedisAdvancedClusterCommands APIs time APIs

Example 1
void closeConnection() {

        RedisAdvancedClusterCommands<String, String> connection = clusterClient.connect().sync();

        List<String> time = connection.time();
        assertThat(time).hasSize(2);

        connection.getStatefulConnection().close();

        assertThatThrownBy(connection::time).isInstanceOf(RedisException.class);
    }