Skip to content

Commit

Permalink
Improve codecs #70
Browse files Browse the repository at this point in the history
  • Loading branch information
mp911de committed Jun 7, 2015
1 parent dcb2736 commit 86fdaf9
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 6 deletions.
3 changes: 1 addition & 2 deletions src/main/java/com/lambdaworks/redis/RedisClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,6 @@
*/
public class RedisClient extends AbstractRedisClient {

private final RedisCodec<String, String> codec = newStringStringCodec();
private final RedisURI redisURI;

/**
Expand Down Expand Up @@ -342,7 +341,7 @@ private <K, V> void connectAsync(CommandHandler<K, V> handler, RedisAsyncConnect
* @return A new connection.
*/
public RedisPubSubConnection<String, String> connectPubSub() {
return connectPubSub(codec);
return connectPubSub(newStringStringCodec());
}

/**
Expand Down
6 changes: 2 additions & 4 deletions src/main/java/com/lambdaworks/redis/codec/RedisCodec.java
Original file line number Diff line number Diff line change
Expand Up @@ -5,11 +5,9 @@
import java.nio.ByteBuffer;

/**
* A RedisCodec encodes keys and values sent to redis, and decodes keys
* and values in the command output.
* A RedisCodec encodes keys and values sent to redis, and decodes keys and values in the command output.
*
* The encode methods will be called by multiple threads and must be thread-safe,
* however the decode methods will only be called by one thread.
* The methods will be called by multiple threads and must be thread-safe.
*
* @param <K> Key type.
* @param <V> Value type.
Expand Down

0 comments on commit 86fdaf9

Please sign in to comment.