-
Notifications
You must be signed in to change notification settings - Fork 107
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Does DSL-JSON Scale? #257
Comments
Hi, DSL-JSON should work fine with high concurrent workloads. There are even few tweaks you can do to avoid thread locals and gain some additional performance. |
Thanks for the response @zapov. Can you please write down some of the tweaks you think will improve performance? I have done some profiling in which I saw a hotspot/bottleneck in the readContent method in DslJsonConverter class. With 1 TPS, deserialisation speeds are < 100ms, however with 30+ TPS, I see times of 1-3 seconds to deserialise. Note, this is deserilisation of a 40MB byte array. 16GB RAM, 2VCPU. If you wish, I can share further benchmarking statistics. |
You can find various suggestions in the readme but I doubt that will help you.
but nothing from that will help if you if your single deserialization takes too long and produces too much garbage. |
I have added an example of a Profiler CPU Capture. As you can see the read/readContent are the hotspots. As stated above, with 1 or 2 Threads concurrently running and executing deserialise every second, there is excellent performance < 100ms. When increasing this to 30 in running in ECS Fargate, it takes 1-3 seconds for each deserialisation operation. |
If this is 2 CPU machine I would assume 2-4 threads would be optimal size, after that context switching might be hurting you too much. Anyway, good luck with performance profiling... and figuring out where this performance bottleneck is coming from. If you need my further help you can ask for consulting contract via email. |
I am considering using DSL-JSON for my project. I am curious on if DSL-JSON works well with high concurrent workflows?
Specifically, hundreds/thousands of TPS (web server) deserialising a large JSON file (40~MB)?
Are there any load tests available or is anyone using this lib to this scale?
Doing some quick experimentation and looks like at 5-10 concurrent threads DSL JSON struggles to deserialise when all threads are trying to deserialise the 40MB file. Example of JSON object:
The text was updated successfully, but these errors were encountered: