Open aaabramov opened 5 years ago
Can you open a PR or put some more details about what you mean?
Sure, sorry.
Currently, op-rabbit-circe serializes JSON to string, and then gets bytes from it (https://github.com/SpinGo/op-rabbit/blob/master/addons/circe/src/main/scala/com/spingo/op_rabbit/CirceSupport.scala#L18):
value.asJson.noSpaces.getBytes(utf8)
But circe is able to generate bytes array directly.
Examples can be found here: https://github.com/circe/circe-jackson/pull/11/files
According to https://github.com/circe/circe/issues/536 there is no need to make transitive string serialization to get UTF-8 bytes array.