Posting multiple events with http and reading with tcp.

We have some services that post events via http and others that read via tcp.

The issue i’m having is http posts ( vnd.eventstore.events+json ) encode the byte[] metadata as uuencoded64 as per standard json.

However event store then seems to store it as uuencoded64 bytes and tcp clients dont see it as a plain byte [] .

Am i doing something wrong ?

Ben

[
    {
      "eventId"    : "string",
      "eventType"  : "string",
      "data"       : "object"
      "metadata"   : "object"
    }
]

Should this be created as an issue ?

The behavior i would expect is a uuencoded metadata in the json post gets converted to a non uuencoded sequence and stored
When the caller is using .net / tcp the raw bytes are returned … When the caller uses json then the encoded metadata is returned. Im not sure this is the case but my initial test shows it is .

Obviously this is a pain for an upgrade because it is sometimes stored as uuencoded and sometimes as raw bytes with no indicator and trivially implementing the above would break current http users.

Hi,

Can you please provide an example of http Post and an example of how you decode the metadata using the C# ClientApi?

Riccardo