Closed yukim closed 10 years ago
I believe that switch is made in master. The non-thread safe version shouldn't really exist anymore, but I think its removal was lost in one of my local branches or left in for a test or some other reason of expedience.
https://github.com/addthis/stream-lib/commit/5a9e9cc7f71e1eb49635df29bba67d905903f1b8 is the commit that should fix it.
You are right. I will try 2.6.0-rc0.
Since HLLP#getBytes uses Varint.writeUnsignedVarInt(int) which is not thread safe I see corruption in returned byte array when serializing different HLLP objects from multiple threads. (stream-lib version is 2.5.1)
I think one way is to switch to Varint.writeUnsignedVarInt(int, DataOutput).