iphone - Mobile : one single request or multiple smaller requests? -
on iphone app (or mobile in general) needs send requests web service, better work 1 single requests fetch large amount of data or multiple (possibly simultaneous) requests each element smaller amount of data fetched.
example
i want load list of elements in node. have node's id. 2 ways can fetch elements following :
- send single request node id , information n first elements in node in single response ;
- send first request node id ids of n first elements in node, each 1 send request have 1 response per element.
i'm balanced between that.
- the heavyweight single response may cause more lag , timeouts because of unstable , slow mobile internet connection ;
- the phone may have trouble handling many responses @ same time.
what's opinion ?
since there overhead every request, 1 large request faster several small ones of same size. applies high speed networks too, in mobile networks ratio between transfer speed , latency bigger.
Comments
Post a Comment