Such code throws an error “The RawBinaryTranscoder can only decode byte arrays.”. It causes because RawBinaryTranscoder is getting DataFormat.Reserved instead of DataFormat.Binary.
var result1 = collection.InsertAsync("testId", byteArray, options => options
var result2 = collection.GetAsync("testId", options => options
var bytes = result2.ContentAs<byte>();
@Ramirag what is the Transcoder object you are passing in ?
Instead can you explicitly specify RawBinaryTranscoder if thats what you intend to use ?
Oh sorry. It’s RawBinaryTranscoder. I’ve played with your sources and have forgotten to change a name before coping here.
ah ok, no worries totally understand - can you also let us know what you pass in as byteArray
are you converting to byteArray or are you receiving a stream
Just looking at the tests everything seems to be looking good and so asking.
Thanks for reporting @Ramirag; this is indeed a bug. Ticket can be found here.