Receiving Singleton result is super slow
DB (Singleton):
private static Bar getFoo() {
db.query()... // whole method takes 10 ms to return
}
MyAsyncTask:
doInBackground(Void... v) {
Singleton.getInstance().getFoo() // takes 160 ms to receive
}
Why dose it take 16x times longer to receive the result in
doInBackground() and what can I do to make it faster?
No comments:
Post a Comment