Hacker News new | ask | show | jobs
by serial_dev 860 days ago
Example: you work on the mobile team, the backend team is large and focuses on serving the web app, they send huge JSON payloads that the mobile app only partially need, and asking the backend team to now also serve msgpack is out of the question as things together with the backend and web teams were proven to be a PITA.

In this scenario, writing a new, or bundling someone else's json library can significantly improve things.

3 comments

Sounds like a dysfunctional organization to be honest. Why couldn't you agree on the contents of the mobile API? If the backend team is slow, why can't the mobile team implement a proxy towards the backend to serve only the data they need?
I totally agree, it was a dysfunctional org, but sometimes fixing the org is extremely hard and you want to make progress today focusing on what you can do to improve the user's experience, instead of focusing on what others should change and do.
I worked at TomTom on the Home application. There was a similar problem with map updates where the payload was XML.

The devices only needed a sub-range of the XML so I used an XML parser to ignore everything until I got the tag needed then read until the end tag arrived.

This avoided a DOM and the huge amount of memory needed to hold that. It was also significantly faster.

That’s an issue with your teams rather than the message format.

Even sending data that the mobile app doesn’t need raises flags.