Estimating JSON size
- π
- π 990 words
- π 5 minutes
- π¦ .NET
- π·οΈ JSON, C#
- π¬ 2 responses
I've been working on a system that heavily uses message queuing (RabbitMQ via MassTransit specifically) and occasionally the system needs to deal with large object graphs that need to be processed different - either broken into smaller pieces of work or serialized to an external source and a pointer put into the message instead.
The first idea was to serialize all messages to a MemoryStream but unfortunately this has some limitations, specifically: