iOS CBLite Performance issue on main thread during syncing


#1

Hi guys,

I am currently working on an app which syncs around 15000 objects via sync gateway. The syncing works great but it seems to block the main thread, which makes the UI unresponsive.

Do you have any recommendations or tips about how I can make the syncing process more efficient when I sync large data sets, so that it doesn’t block the main thread?

Cheers,

Marcel


#2

All replications are automatically done on the background thread.

But other queries to the database while the replication is in progress may be the reason. What part of the application is blocking the UI? Results of a live query, database change listener, replication progress notifications?

Are you using the iOS or Android SDK?

See this thread for more info as well https://groups.google.com/forum/#!searchin/mobile-couchbase/blocking$20ui/mobile-couchbase/jeIk08kKIrk/f3V5sPWq79oJ

James


#3

I am using CBLite 2.1 and i am facing same issue ( blocking main thread) , could you help me on this.


#4

Please be specific on the issue and what call is blocking the main thread .


#5

database.addchangelistener added after that there is method which call a method to viewcontroller to upate the screen , this blocking my screen , i tried to add addchangelistener in background thread but it doesn;t work properly