Tencent / wcdb

WCDB is a cross-platform database framework developed by WeChat.
Other
10.78k stars 1.41k forks source link

Upgrading to WCDB and Issue with Signal Retry Feature removed #1015

Closed waitianlou closed 11 months ago

waitianlou commented 11 months ago

The language of WCDB

Objective-C

The version of WCDB

will update

The platform of WCDB

iOS

The installation of WCDB

Cocoapods

What's the issue?

Wonder why feature ( wcdb signal retry) was removed

Backgournd:

My project uses a very old version of WCDB,prepare to upgrade the WCDB version to 2.0。 Find a feaure (Remove wcdb signal retry) was removed at January 15, 2019 (9df1efd7fdb150654ee8b93e81426e311e2fea83)。 With old version of WCDB,My App sometimes will wait a long time(may kill by watchdog) at WCDBOsShmWait

Explain what you want by example or code in English.

Although it is a long before submission,I'm curious this commit,Because I haven't been able to figure out why this feature ( wcdb signal retry) Will lead to watchdog for a long long time。 Sincerely Best regards

Qiuwen-chen commented 11 months ago

Signal retry has been changed to a new implementation, which is a mechanism for handling database writes and write conflicts.

In your case, it should be that the UI thread's write database operation is waiting for other threads' write database operations.