diff --git a/src/main/java/org/redisson/client/handler/RedisDecoder.java b/src/main/java/org/redisson/client/handler/RedisDecoder.java index 10e4671b7..3e04b5f19 100644 --- a/src/main/java/org/redisson/client/handler/RedisDecoder.java +++ b/src/main/java/org/redisson/client/handler/RedisDecoder.java @@ -27,6 +27,7 @@ import org.redisson.client.RedisMovedException; import org.redisson.client.RedisPubSubConnection; import org.redisson.client.handler.RedisCommandsQueue.QueueCommands; import org.redisson.client.protocol.Decoder; +import org.redisson.client.protocol.RedisCommand.ValueType; import org.redisson.client.protocol.pubsub.MultiDecoder; import org.redisson.client.protocol.pubsub.PubSubMessage; import org.redisson.client.protocol.pubsub.PubSubPatternMessage; @@ -103,32 +104,37 @@ public class RedisDecoder extends ReplayingDecoder { } Object result = messageDecoder(data, respParts).decode(respParts); - if (data != null) { - if (Arrays.asList("PSUBSCRIBE", "SUBSCRIBE").contains(data.getCommand().getName())) { - for (Object param : data.getParams()) { - messageDecoders.put(param.toString(), data.getMessageDecoder()); - } + handleMultiResult(data, parts, pubSubConnection, result); + } else { + throw new IllegalStateException("Can't decode replay " + (char)code); + } + } + + private void handleMultiResult(RedisData data, List parts, + RedisPubSubConnection pubSubConnection, Object result) { + if (data != null) { + if (Arrays.asList("PSUBSCRIBE", "SUBSCRIBE").contains(data.getCommand().getName())) { + for (Object param : data.getParams()) { + messageDecoders.put(param.toString(), data.getMessageDecoder()); } - if (Arrays.asList("PUNSUBSCRIBE", "UNSUBSCRIBE").contains(data.getCommand().getName())) { - for (Object param : data.getParams()) { - messageDecoders.remove(param.toString()); - } + } + if (Arrays.asList("PUNSUBSCRIBE", "UNSUBSCRIBE").contains(data.getCommand().getName())) { + for (Object param : data.getParams()) { + messageDecoders.remove(param.toString()); } + } - if (parts != null) { - parts.add(result); - } else { - data.getPromise().setSuccess(result); - } + if (parts != null) { + parts.add(result); } else { - if (result instanceof PubSubMessage) { - pubSubConnection.onMessage((PubSubMessage) result); - } else { - pubSubConnection.onMessage((PubSubPatternMessage) result); - } + data.getPromise().setSuccess(result); } } else { - throw new IllegalStateException("Can't decode replay " + (char)code); + if (result instanceof PubSubMessage) { + pubSubConnection.onMessage((PubSubMessage) result); + } else { + pubSubConnection.onMessage((PubSubPatternMessage) result); + } } } @@ -178,7 +184,19 @@ public class RedisDecoder extends ReplayingDecoder { } } if (decoder == null) { - decoder = data.getCodec(); + if (data.getCommand().getOutParamType() == ValueType.MAP) { + if (parts.size() % 2 != 0) { + decoder = data.getCodec().getMapKeyDecoder(); + } else { + decoder = data.getCodec().getMapValueDecoder(); + } + } else if (data.getCommand().getOutParamType() == ValueType.MAP_KEY) { + decoder = data.getCodec().getMapKeyDecoder(); + } else if (data.getCommand().getOutParamType() == ValueType.MAP_VALUE) { + decoder = data.getCodec().getMapValueDecoder(); + } else { + decoder = data.getCodec().getValueDecoder(); + } } return decoder; } diff --git a/src/main/java/org/redisson/client/handler/RedisEncoder.java b/src/main/java/org/redisson/client/handler/RedisEncoder.java index 8bea0feeb..3e53c7939 100644 --- a/src/main/java/org/redisson/client/handler/RedisEncoder.java +++ b/src/main/java/org/redisson/client/handler/RedisEncoder.java @@ -15,7 +15,8 @@ */ package org.redisson.client.handler; -import java.util.Arrays; +import org.redisson.client.protocol.Encoder; +import org.redisson.client.protocol.RedisCommand.ValueType; import io.netty.buffer.ByteBuf; import io.netty.channel.ChannelHandlerContext; @@ -44,11 +45,15 @@ public class RedisEncoder extends MessageToByteEncoder } int i = 1; for (Object param : msg.getParams()) { - if (Arrays.binarySearch(msg.getCommand().getObjectParamIndexes(), i) != -1) { - writeArgument(out, msg.getCodec().encode(i, param)); - } else { - writeArgument(out, msg.getCommand().getParamsEncoder().encode(i, param)); + Encoder encoder = msg.getCommand().getParamsEncoder(); + if (msg.getCommand().getInParamIndex() == i && msg.getCommand().getInParamType() == ValueType.OBJECT) { + encoder = msg.getCodec().getValueEncoder(); + } else if (msg.getCommand().getInParamIndex() <= i && msg.getCommand().getInParamType() != ValueType.OBJECT) { + encoder = encoder(msg, i - msg.getCommand().getInParamIndex()); } + + writeArgument(out, encoder.encode(i, param)); + i++; } @@ -56,6 +61,23 @@ public class RedisEncoder extends MessageToByteEncoder System.out.println(o); } + private Encoder encoder(RedisData msg, int param) { + if (msg.getCommand().getInParamType() == ValueType.MAP) { + if (param % 2 != 0) { + return msg.getCodec().getMapValueEncoder(); + } else { + return msg.getCodec().getMapKeyEncoder(); + } + } + if (msg.getCommand().getInParamType() == ValueType.MAP_KEY) { + return msg.getCodec().getMapKeyEncoder(); + } + if (msg.getCommand().getInParamType() == ValueType.MAP_KEY) { + return msg.getCodec().getMapValueEncoder(); + } + throw new IllegalStateException(); + } + private void writeArgument(ByteBuf out, byte[] arg) { out.writeByte(BYTES_PREFIX); out.writeBytes(toChars(arg.length)); diff --git a/src/main/java/org/redisson/client/protocol/Codec.java b/src/main/java/org/redisson/client/protocol/Codec.java index f8427504c..908dc5d76 100644 --- a/src/main/java/org/redisson/client/protocol/Codec.java +++ b/src/main/java/org/redisson/client/protocol/Codec.java @@ -15,6 +15,18 @@ */ package org.redisson.client.protocol; -public interface Codec extends Encoder, Decoder { +public interface Codec { + + Decoder getMapValueDecoder(); + + Encoder getMapValueEncoder(); + + Decoder getMapKeyDecoder(); + + Encoder getMapKeyEncoder(); + + Decoder getValueDecoder(); + + Encoder getValueEncoder(); } diff --git a/src/main/java/org/redisson/client/protocol/IntegerCodec.java b/src/main/java/org/redisson/client/protocol/IntegerCodec.java index 9044fe688..85fc109b3 100644 --- a/src/main/java/org/redisson/client/protocol/IntegerCodec.java +++ b/src/main/java/org/redisson/client/protocol/IntegerCodec.java @@ -25,20 +25,50 @@ public class IntegerCodec implements Codec { public static final IntegerCodec INSTANCE = new IntegerCodec(); @Override - public byte[] encode(int paramIndex, Object in) { - try { - return in.toString().getBytes("UTF-8"); - } catch (UnsupportedEncodingException e) { - throw new IllegalStateException(e); - } + public Decoder getValueDecoder() { + return new Decoder() { + @Override + public Object decode(ByteBuf buf) { + if (buf == null) { + return null; + } + return Integer.valueOf(buf.toString(CharsetUtil.UTF_8)); + } + }; } @Override - public Object decode(ByteBuf buf) { - if (buf == null) { - return null; - } - return Integer.valueOf(buf.toString(CharsetUtil.UTF_8)); + public Encoder getValueEncoder() { + return new Encoder() { + @Override + public byte[] encode(int paramIndex, Object in) { + try { + return in.toString().getBytes("UTF-8"); + } catch (UnsupportedEncodingException e) { + throw new IllegalStateException(e); + } + } + }; + } + + @Override + public Decoder getMapValueDecoder() { + return getValueDecoder(); + } + + @Override + public Encoder getMapValueEncoder() { + return getValueEncoder(); + } + + @Override + public Decoder getMapKeyDecoder() { + return getValueDecoder(); + } + + @Override + public Encoder getMapKeyEncoder() { + return getValueEncoder(); } } diff --git a/src/main/java/org/redisson/client/protocol/JsonCodec.java b/src/main/java/org/redisson/client/protocol/JsonCodec.java deleted file mode 100644 index 5a381f748..000000000 --- a/src/main/java/org/redisson/client/protocol/JsonCodec.java +++ /dev/null @@ -1,35 +0,0 @@ -package org.redisson.client.protocol; - -import java.io.IOException; - -import com.fasterxml.jackson.core.JsonProcessingException; -import com.fasterxml.jackson.databind.ObjectMapper; - -import io.netty.buffer.ByteBuf; -import io.netty.buffer.ByteBufInputStream; - -public class JsonCodec implements Codec { - - public static final JsonCodec INSTANCE = new JsonCodec(); - - private final ObjectMapper mapper = new ObjectMapper(); - - @Override - public byte[] encode(int paramIndex, Object in) { - try { - return mapper.writeValueAsBytes(in); - } catch (JsonProcessingException e) { - throw new IllegalStateException(e); - } - } - - @Override - public Object decode(ByteBuf buf) { - try { - return mapper.readValue(new ByteBufInputStream(buf), Object.class); - } catch (IOException e) { - throw new IllegalStateException(e); - } - } - -} diff --git a/src/main/java/org/redisson/client/protocol/RedisCommand.java b/src/main/java/org/redisson/client/protocol/RedisCommand.java index fa010d8d9..9b8ddaed5 100644 --- a/src/main/java/org/redisson/client/protocol/RedisCommand.java +++ b/src/main/java/org/redisson/client/protocol/RedisCommand.java @@ -19,53 +19,103 @@ import org.redisson.client.protocol.pubsub.MultiDecoder; public class RedisCommand { + public enum ValueType {OBJECT, MAP_VALUE, MAP_KEY, MAP} + + private ValueType outParamType = ValueType.OBJECT; + private ValueType inParamType = ValueType.OBJECT; + private final int inParamIndex; + private final String name; private final String subName; - private final int[] objectParamIndexes; private Encoder paramsEncoder = new StringParamsEncoder(); private MultiDecoder replayMultiDecoder; private Decoder replayDecoder; private Convertor convertor = new EmptyConvertor(); - public RedisCommand(String name, String subName, int ... encodeParamIndexes) { - this(name, subName, null, null, encodeParamIndexes); + public RedisCommand(String name) { + this(name, (String)null); } - public RedisCommand(String name, int ... encodeParamIndexes) { - this(name, null, null, null, encodeParamIndexes); + public RedisCommand(String name, ValueType outParamType) { + this(name, (String)null); + this.outParamType = outParamType; } - public RedisCommand(String name, Convertor convertor, int ... encodeParamIndexes) { - this.name = name; - this.subName = null; - this.objectParamIndexes = encodeParamIndexes; + public RedisCommand(String name, String subName) { + this(name, subName, null, null, -1); + } + + public RedisCommand(String name, String subName, int objectParamIndex) { + this(name, subName, null, null, objectParamIndex); + } + + public RedisCommand(String name, int encodeParamIndex) { + this(name, null, null, null, encodeParamIndex); + } + + public RedisCommand(String name, int encodeParamIndex, ValueType inParamType, ValueType outParamType) { + this(name, null, null, null, encodeParamIndex); + this.inParamType = inParamType; + this.outParamType = outParamType; + } + + + public RedisCommand(String name, Convertor convertor, int encodeParamIndex, ValueType inParamType) { + this(name, null, null, null, encodeParamIndex); this.convertor = convertor; + this.inParamType = inParamType; } - public RedisCommand(String name, Decoder reponseDecoder, int ... encodeParamIndexes) { - this(name, null, null, reponseDecoder, encodeParamIndexes); + public RedisCommand(String name, Convertor convertor, int encodeParamIndex) { + this(name, null, null, null, encodeParamIndex); + this.convertor = convertor; } - public RedisCommand(String name, MultiDecoder replayMultiDecoder, int ... encodeParamIndexes) { - this.name = name; - this.subName = null; - this.objectParamIndexes = encodeParamIndexes; - this.replayMultiDecoder = replayMultiDecoder; + public RedisCommand(String name, Decoder reponseDecoder) { + this(name, null, null, reponseDecoder, -1); + } + + public RedisCommand(String name, Decoder reponseDecoder, int objectParamIndex, ValueType inParamType) { + this(name, null, null, reponseDecoder, objectParamIndex); + this.inParamType = inParamType; + } + + public RedisCommand(String name, Decoder reponseDecoder, int objectParamIndex) { + this(name, null, null, reponseDecoder, objectParamIndex); + } + + public RedisCommand(String name, MultiDecoder replayMultiDecoder, ValueType outParamType) { + this(name, replayMultiDecoder, -1); + this.outParamType = outParamType; + } + + public RedisCommand(String name, MultiDecoder replayMultiDecoder, int objectParamIndex, ValueType inParamType, ValueType outParamType) { + this(name, replayMultiDecoder, objectParamIndex); + this.outParamType = outParamType; + this.inParamType = inParamType; + } + + public RedisCommand(String name, MultiDecoder replayMultiDecoder) { + this(name, replayMultiDecoder, -1); + } + + public RedisCommand(String name, MultiDecoder replayMultiDecoder, int objectParamIndex) { + this(name, null, replayMultiDecoder, null, objectParamIndex); } public RedisCommand(String name, String subName, MultiDecoder replayMultiDecoder, - int... encodeParamIndexes) { - this(name, subName, replayMultiDecoder, null, encodeParamIndexes); + int objectParamIndex) { + this(name, subName, replayMultiDecoder, null, objectParamIndex); } - public RedisCommand(String name, String subName, MultiDecoder replayMultiDecoder, Decoder reponseDecoder, int ... encodeParamIndexes) { + public RedisCommand(String name, String subName, MultiDecoder replayMultiDecoder, Decoder reponseDecoder, int objectParamIndex) { super(); this.name = name; this.subName = subName; this.replayMultiDecoder = replayMultiDecoder; this.replayDecoder = reponseDecoder; - this.objectParamIndexes = encodeParamIndexes; + this.inParamIndex = objectParamIndex; } public String getSubName() { @@ -80,8 +130,8 @@ public class RedisCommand { return replayDecoder; } - public int[] getObjectParamIndexes() { - return objectParamIndexes; + public int getInParamIndex() { + return inParamIndex; } public MultiDecoder getReplayMultiDecoder() { @@ -96,4 +146,12 @@ public class RedisCommand { return paramsEncoder; } + public ValueType getInParamType() { + return inParamType; + } + + public ValueType getOutParamType() { + return outParamType; + } + } diff --git a/src/main/java/org/redisson/client/protocol/RedisCommands.java b/src/main/java/org/redisson/client/protocol/RedisCommands.java index e32e92378..f095afc9c 100644 --- a/src/main/java/org/redisson/client/protocol/RedisCommands.java +++ b/src/main/java/org/redisson/client/protocol/RedisCommands.java @@ -18,7 +18,9 @@ package org.redisson.client.protocol; import java.util.List; import java.util.Map; +import org.redisson.client.protocol.RedisCommand.ValueType; import org.redisson.client.protocol.decoder.BooleanReplayDecoder; +import org.redisson.client.protocol.decoder.KeyValueObjectDecoder; import org.redisson.client.protocol.decoder.ObjectListReplayDecoder; import org.redisson.client.protocol.decoder.ObjectMapReplayDecoder; import org.redisson.client.protocol.decoder.StringDataDecoder; @@ -48,6 +50,7 @@ public interface RedisCommands { RedisStrictCommand EVAL_INTEGER = new RedisStrictCommand("EVAL"); RedisCommand> EVAL_LIST = new RedisCommand>("EVAL", new ObjectListReplayDecoder()); RedisCommand EVAL_OBJECT = new RedisCommand("EVAL"); + RedisCommand EVAL_MAP_VALUE = new RedisCommand("EVAL", ValueType.MAP_VALUE); RedisStrictCommand INCR = new RedisStrictCommand("INCR"); RedisStrictCommand INCRBY = new RedisStrictCommand("INCRBY"); @@ -61,14 +64,14 @@ public interface RedisCommands { RedisStrictCommand> KEYS = new RedisStrictCommand>("KEYS", new StringListReplayDecoder()); - RedisCommand> HGETALL = new RedisCommand>("HGETALL", new ObjectMapReplayDecoder()); - RedisCommand> HVALS = new RedisCommand>("HVALS", new ObjectListReplayDecoder()); - RedisCommand HEXISTS = new RedisCommand("HEXISTS", new BooleanReplayConvertor(), 1); + RedisCommand> HGETALL = new RedisCommand>("HGETALL", new ObjectMapReplayDecoder(), ValueType.MAP); + RedisCommand> HVALS = new RedisCommand>("HVALS", new ObjectListReplayDecoder(), ValueType.MAP_VALUE); + RedisCommand HEXISTS = new RedisCommand("HEXISTS", new BooleanReplayConvertor(), 1, ValueType.MAP_KEY); RedisStrictCommand HLEN = new RedisStrictCommand("HLEN"); - RedisCommand> HKEYS = new RedisCommand>("HKEYS", new ObjectListReplayDecoder()); - RedisCommand HMSET = new RedisCommand("HMSET", new StringReplayDecoder(), 2, 3); - RedisCommand> HMGET = new RedisCommand>("HMGET", new ObjectListReplayDecoder()); - RedisCommand HGET = new RedisCommand("HMGET", 2); + RedisCommand> HKEYS = new RedisCommand>("HKEYS", new ObjectListReplayDecoder(), ValueType.MAP_KEY); + RedisCommand HMSET = new RedisCommand("HMSET", new StringReplayDecoder(), 1, ValueType.MAP); + RedisCommand> HMGET = new RedisCommand>("HMGET", new ObjectListReplayDecoder(), 1, ValueType.MAP_KEY, ValueType.MAP_VALUE); + RedisCommand HGET = new RedisCommand("HGET", 1, ValueType.MAP_KEY, ValueType.MAP_VALUE); RedisStrictCommand DEL_BOOLEAN = new RedisStrictCommand("DEL", new BooleanReplayConvertor()); diff --git a/src/main/java/org/redisson/client/protocol/RedisStrictCommand.java b/src/main/java/org/redisson/client/protocol/RedisStrictCommand.java index 03b49b241..c98653c21 100644 --- a/src/main/java/org/redisson/client/protocol/RedisStrictCommand.java +++ b/src/main/java/org/redisson/client/protocol/RedisStrictCommand.java @@ -19,34 +19,28 @@ import org.redisson.client.protocol.pubsub.MultiDecoder; public class RedisStrictCommand extends RedisCommand { - public RedisStrictCommand(String name, MultiDecoder replayMultiDecoder, int... encodeParamIndexes) { - super(name, replayMultiDecoder, encodeParamIndexes); + public RedisStrictCommand(String name, MultiDecoder replayMultiDecoder) { + super(name, replayMultiDecoder); } - public RedisStrictCommand(String name, String subName, MultiDecoder replayMultiDecoder, - int... encodeParamIndexes) { - super(name, subName, replayMultiDecoder, encodeParamIndexes); + public RedisStrictCommand(String name, String subName, MultiDecoder replayMultiDecoder) { + super(name, subName, replayMultiDecoder, -1); } - public RedisStrictCommand(String name, int... encodeParamIndexes) { - super(name, encodeParamIndexes); + public RedisStrictCommand(String name) { + super(name); } - public RedisStrictCommand(String name, Convertor convertor, int ... encodeParamIndexes) { - super(name, convertor, encodeParamIndexes); + public RedisStrictCommand(String name, Convertor convertor) { + super(name, convertor, -1); } - public RedisStrictCommand(String name, String subName, Decoder reponseDecoder, - int... encodeParamIndexes) { - super(name, subName, null, reponseDecoder, encodeParamIndexes); + public RedisStrictCommand(String name, String subName, Decoder reponseDecoder) { + super(name, subName, null, reponseDecoder, -1); } - public RedisStrictCommand(String name, String subName, int... encodeParamIndexes) { - super(name, subName, encodeParamIndexes); - } - - public RedisStrictCommand(String name, Decoder reponseDecoder, int... encodeParamIndexes) { - super(name, reponseDecoder, encodeParamIndexes); + public RedisStrictCommand(String name, Decoder reponseDecoder) { + super(name, reponseDecoder); } } diff --git a/src/main/java/org/redisson/client/protocol/StringCodec.java b/src/main/java/org/redisson/client/protocol/StringCodec.java index bcb746fd2..e57669784 100644 --- a/src/main/java/org/redisson/client/protocol/StringCodec.java +++ b/src/main/java/org/redisson/client/protocol/StringCodec.java @@ -25,20 +25,50 @@ public class StringCodec implements Codec { public static final StringCodec INSTANCE = new StringCodec(); @Override - public byte[] encode(int paramIndex, Object in) { - try { - return in.toString().getBytes("UTF-8"); - } catch (UnsupportedEncodingException e) { - throw new IllegalStateException(e); - } + public Decoder getValueDecoder() { + return new Decoder() { + @Override + public Object decode(ByteBuf buf) { + if (buf == null) { + return null; + } + return buf.toString(CharsetUtil.UTF_8); + } + }; } @Override - public Object decode(ByteBuf buf) { - if (buf == null) { - return null; - } - return buf.toString(CharsetUtil.UTF_8); + public Encoder getValueEncoder() { + return new Encoder() { + @Override + public byte[] encode(int paramIndex, Object in) { + try { + return in.toString().getBytes("UTF-8"); + } catch (UnsupportedEncodingException e) { + throw new IllegalStateException(e); + } + } + }; + } + + @Override + public Decoder getMapValueDecoder() { + return getValueDecoder(); + } + + @Override + public Encoder getMapValueEncoder() { + return getValueEncoder(); + } + + @Override + public Decoder getMapKeyDecoder() { + return getValueDecoder(); + } + + @Override + public Encoder getMapKeyEncoder() { + return getValueEncoder(); } } diff --git a/src/main/java/org/redisson/client/protocol/StringIntegerCodec.java b/src/main/java/org/redisson/client/protocol/StringIntegerCodec.java new file mode 100644 index 000000000..846d85505 --- /dev/null +++ b/src/main/java/org/redisson/client/protocol/StringIntegerCodec.java @@ -0,0 +1,82 @@ +/** + * Copyright 2014 Nikita Koksharov, Nickolay Borbit + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.redisson.client.protocol; + +import java.io.UnsupportedEncodingException; + +import io.netty.buffer.ByteBuf; +import io.netty.util.CharsetUtil; + +public class StringIntegerCodec implements Codec { + + public static final StringIntegerCodec INSTANCE = new StringIntegerCodec(); + + @Override + public Decoder getValueDecoder() { + return new Decoder() { + @Override + public Object decode(ByteBuf buf) { + if (buf == null) { + return null; + } + return buf.toString(CharsetUtil.UTF_8); + } + }; + } + + @Override + public Encoder getValueEncoder() { + return new Encoder() { + @Override + public byte[] encode(int paramIndex, Object in) { + try { + return in.toString().getBytes("UTF-8"); + } catch (UnsupportedEncodingException e) { + throw new IllegalStateException(e); + } + } + }; + } + + @Override + public Decoder getMapValueDecoder() { + return new Decoder() { + @Override + public Object decode(ByteBuf buf) { + if (buf == null) { + return null; + } + return Integer.valueOf(buf.toString(CharsetUtil.UTF_8)); + } + }; + } + + @Override + public Encoder getMapValueEncoder() { + return getValueEncoder(); + } + + @Override + public Decoder getMapKeyDecoder() { + return getValueDecoder(); + } + + @Override + public Encoder getMapKeyEncoder() { + return getValueEncoder(); + } + +} diff --git a/src/main/java/org/redisson/client/protocol/KeyValueMessage.java b/src/main/java/org/redisson/client/protocol/decoder/KeyValueMessage.java similarity index 87% rename from src/main/java/org/redisson/client/protocol/KeyValueMessage.java rename to src/main/java/org/redisson/client/protocol/decoder/KeyValueMessage.java index be6312bf3..531d49c85 100644 --- a/src/main/java/org/redisson/client/protocol/KeyValueMessage.java +++ b/src/main/java/org/redisson/client/protocol/decoder/KeyValueMessage.java @@ -1,4 +1,4 @@ -package org.redisson.client.protocol; +package org.redisson.client.protocol.decoder; public class KeyValueMessage { diff --git a/src/main/java/org/redisson/client/protocol/KeyValueObjectDecoder.java b/src/main/java/org/redisson/client/protocol/decoder/KeyValueObjectDecoder.java similarity index 93% rename from src/main/java/org/redisson/client/protocol/KeyValueObjectDecoder.java rename to src/main/java/org/redisson/client/protocol/decoder/KeyValueObjectDecoder.java index 768ad549b..51f07c8e9 100644 --- a/src/main/java/org/redisson/client/protocol/KeyValueObjectDecoder.java +++ b/src/main/java/org/redisson/client/protocol/decoder/KeyValueObjectDecoder.java @@ -1,4 +1,4 @@ -package org.redisson.client.protocol; +package org.redisson.client.protocol.decoder; import java.util.List;