Re: how to decode record correctly

2019-02-19 Thread
done! just because of the bytebuffer usage. 徐建海 于2019年2月19日周二 下午7:57写道: > public class DefaultRecord implements Record { > > // excluding key, value and headers: 5 bytes length + 10 bytes timestamp > + 5 bytes offset + 1 byte attributes > public static final int MAX_

Re: how to decode record correctly

2019-02-19 Thread
As I found, the private final ByteBuffer value; is not what I passed in key/value pair in client, How can I get the the origin Key/Value in kafka server? 徐建海 于2019年2月19日周二 下午6:51写道: > Hello: > I try to add some feature to Kafka, but I encounter a problem: I need > to get the key

Re: how to decode record correctly

2019-02-19 Thread
); private final int sizeInBytes; private final byte attributes; private final long offset; private final long timestamp; private final int sequence; private final ByteBuffer key; private final ByteBuffer value; private final Header[] headers; .. } 徐建海 于

how to decode record correctly

2019-02-19 Thread
Hello: I try to add some feature to Kafka, but I encounter a problem: I need to get the key and value from DefaultRecord, how can I do that?