Hi,
I have an application where one thread (A) is executing various statements
and another thread (B) is performing an online backup. These two threads
share the same source database connection; the SQLite threading mode is set
to serialized.

I wish to stop the online backup from another thread as quickly and safely
as possible. In particular, I want to interrupt a potentially time
consuming sqlite3_backup_step call. I thought calling sqlite3_interrupt on
the online backup destination database would be ideal, since I do not want
to potentially stop A's execution by calling interrupt on the source
database. However the online backup documentation (
http://www.sqlite.org/c3ref/backup_finish.html) states that an application
"must guarantee that the destination database connection is not passed to
any other API (by any thread) after sqlite3_backup_init() is called."

So, my question is: is it safe to call sqlite3_interrupt on the destination
database connection of an online backup?

Thank you!
_______________________________________________
sqlite-users mailing list
sqlite-users@sqlite.org
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to