pjfanning / pekko-http-json

Integrate some of the best JSON libs in Scala with Pekko HTTP
Apache License 2.0
25 stars 2 forks source link

use ByteString.toArrayUnsafe to avoid copying the array #17

Closed pjfanning closed 3 months ago

pjfanning commented 3 months ago

ByteString does not mutate its underling array(s). As long as the JSON libs don't mess with the byte array, then 'unsafe' is ok.