JSON steps on the gas!

11.10.2007 -

I recently came across a nice tool from James Ward for measuring the speed of different data transmission paths. James Ward calls himself the RIA Cowboy (RIA = Rich Internet Application). His tool can be used to measure typical transmission paths for web applications such as classic HTML, SOAP or JSON. The time measurement takes four aspects into account: The server execution time, the transmission time, the time for parsing and the time for rendering. The quantity structure can also be varied.

ria_speed.png

The screenshot above shows the result for 500 rows of data. The individual differences can be clearly seen. In my test, JSON performs with a minimal advantage over direct HTML transmission. The clear loser is transmission via SOAP. Ultimately, however, the result is not really surprising in my eyes.

Is faster always better?

However, in the end, the question arises as to whether "faster" is always the better choice in all cases! In principle, performance is a decisive criterion for assessing the quality of web applications. Therefore, from this point of view, the answer is more likely to be YES. On the other hand, however, there is a risk that if you rely too much on JSON, the flexibility and maintainability of the code is likely to suffer. This is because the JavaScript code created is generally oriented towards the transferred JSON structure. If something changes within the structure, a whole series of code must also be adapted. So, as is so often the case, it is important to find the happy medium.

Back to overview

Write a comment

Your e-mail address will not be published. Required fields are marked with *

*Mandatory fields

*