-
Notifications
You must be signed in to change notification settings - Fork 2.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Asynchronously perform database operations on queue, using transactions. #469
base: master
Are you sure you want to change the base?
Conversation
What's the advantage of putting this in FMDB, vs just throwing it in a background block? (PS- what's the point of the FMDBRetain & FMDBRelease outside the block?) |
FWIW, I second the vote that there should be an asynchronous rendition of My only question (setting aside the |
I'm actually for an async method as well (as it's planned for 3.0: https://github.com/ccgus/fmdb/blob/three/FUTURE_PLANS.markdown ) I asked the question because I was curious. 3.0 has taken a backseat in my free time lately though. I had hoped to get something going last Dec, but it just didn't happen. Maybe this should be part of 2.x, because I don't know when 3 will happen? |
My intention to add asynchronous method is to provide non blocking database operation even when working with large records.
I put the
It will be more appropriate to give both option to perform database operations either synchronously or asynchronously.Let the developer to choose which one is better for the task. |
FWIW, I've just added async transactions to the three branch: Discussion on it here: |
Synchronous transaction on queue hangs ui if some insertion/updation is performed on large no of rows.
To avoid ui hang because of synchronous transaction I have added a method named "inTransactionAsync" which perform database operations asynchronously.