I am attempting to use Restlet for Android to query an OData data source. However, I am not impressed with its performance in both the emulator as well on a real device. I have the requests made in a wrapper AsyncTask to make the UI responsive but it still takes over 1 minute to finally return the objects.
I get plenty of these in the LogCat window:
10-04 18:20:41.667: DEBUG/dalvikvm(278): GC freed 7872 objects / 523928 bytes in 279ms
What can I do to speed up the queries?
Check out odata4j – http://odata4j.org This is an alternative odata library for java, including an android-compatible client api.
We just released a simple android client example in our 0.3 release. This example demonstrates an efficient way of parsing/paging an arbitrary odata service.
Along with service driven paging (mentioned by Alex), we use the efficient xml pull parser implementation to parse the odata payload (we found heap activity/GCs to be the biggest perf bottleneck on android).