realm-core icon indicating copy to clipboard operation
realm-core copied to clipboard

Hang in test: "flx: interrupted bootstrap restarts/recovers on reconnect"

Open ironage opened this issue 2 years ago • 1 comments

The hang is waiting on a notification that is never fulfilled here.

Upon investigation, it appears that there is a race on which subscription store instance has the notification added vs which one has handles the commit to change the state to complete. This depends on the timings of shutting down the sync session. To demonstrate this, I have added some prints to the code with the address of the SubscriptionStore instance.

Run demonstrating the hang:

Filters: flx: interrupted bootstrap restarts/recovers on reconnect
SubscriptionStore address: 0x109d166c8 pending: 0
load_from_database: 0, Pending (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 0
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]}]new pk of mutable copy 1
SubscriptionStore address: 0x109d166c8 pending: 0
load_from_database: 1, Uncommitted (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x109d166c8 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x109d166c8 pending: 0
load_from_database: 1, Pending (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 0
SubscriptionStore address: 0x109d166c8 pending: 0
load_from_database: 1, Pending (0x109d166c8)
new notification for version: 1 at: Complete num notifications: 1 for: 0x109d166c8
SubscriptionStore address: 0x109d166c8 pending: 1
load_from_database: 0, Pending (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 1
update state note size: 1
supercede_prior_to: 0
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529d64cbf4ed0bf0b3bae","created_at":"2022-05-18 17:16:06","updated_at":"2022-05-18 17:16:06","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529d64cbf4ed0bf0b3bae","created_at":"2022-05-18 17:16:06","updated_at":"2022-05-18 17:16:06","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x109d166c8 pending: 1
MutableSubscriptionSet::commit() with not size: 1
SubscriptionStore address: 0x109d166c8 pending: 1
process_notifications:  lock with size: 1
skipping notification for version : 1 state: Complete min_outstanding: 0
SubscriptionStore address: 0x109d166c8 pending: 1
load_from_database: 0, Complete (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 1
load_from_database: 1, Pending (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 1
load_from_database: 0, Complete (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 1
update state note size: 1
supercede_prior_to: 0
[{"_key":0,"version":0,"state":3,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529d64cbf4ed0bf0b3bae","created_at":"2022-05-18 17:16:06","updated_at":"2022-05-18 17:16:06","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":0,"version":0,"state":3,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529d64cbf4ed0bf0b3bae","created_at":"2022-05-18 17:16:06","updated_at":"2022-05-18 17:16:06","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x109d166c8 pending: 1
MutableSubscriptionSet::commit() with not size: 1
SubscriptionStore address: 0x109d166c8 pending: 1
process_notifications:  lock with size: 1
skipping notification for version : 1 state: Complete min_outstanding: 0
SubscriptionStore address: 0x109d166c8 pending: 1
load_from_database: 0, Complete (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 1
load_from_database: 1, Pending (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 1
update state note size: 1
supercede_prior_to: 1
[{"_key":0,"version":0,"state":3,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529d64cbf4ed0bf0b3bae","created_at":"2022-05-18 17:16:06","updated_at":"2022-05-18 17:16:06","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529d64cbf4ed0bf0b3bae","created_at":"2022-05-18 17:16:06","updated_at":"2022-05-18 17:16:06","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x109d166c8 pending: 1
MutableSubscriptionSet::commit() with not size: 1
SubscriptionStore address: 0x109d166c8 pending: 1
process_notifications:  lock with size: 1
will finish for version : 1
SubscriptionStore address: 0x109d166c8 pending: 0
load_from_database: 1, Complete (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 0
load_from_database: 1, Complete (0x109d166c8)
SubscriptionStore address: 0x109d166c8 pending: 0
update state note size: 0
supercede_prior_to: 1
[{"_key":1,"version":1,"state":3,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529d64cbf4ed0bf0b3bae","created_at":"2022-05-18 17:16:06","updated_at":"2022-05-18 17:16:06","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":1,"version":1,"state":3,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529d64cbf4ed0bf0b3bae","created_at":"2022-05-18 17:16:06","updated_at":"2022-05-18 17:16:06","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x109d166c8 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x109d166c8 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x109d166c8 pending: 0
load_from_database: 1, Complete (0x109d166c8)
destructing SubscriptionStore 0x109d166c8
SubscriptionStore address: 0x1104204a8 pending: 0
load_from_database: 0, Pending (0x1104204a8)
SubscriptionStore address: 0x1104204a8 pending: 0
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]}]new pk of mutable copy 1
SubscriptionStore address: 0x1104204a8 pending: 0
load_from_database: 1, Uncommitted (0x1104204a8)
SubscriptionStore address: 0x1104204a8 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x1104204a8 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x1104204a8 pending: 0
load_from_database: 1, Pending (0x1104204a8)
SubscriptionStore address: 0x1104204a8 pending: 0
load_from_database: 0, Pending (0x1104204a8)
SubscriptionStore address: 0x1104204a8 pending: 0
update state note size: 0
supercede_prior_to: 0
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529de4cbf4ed0bf0b3bb4","created_at":"2022-05-18 17:16:14","updated_at":"2022-05-18 17:16:14","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529de4cbf4ed0bf0b3bb4","created_at":"2022-05-18 17:16:14","updated_at":"2022-05-18 17:16:14","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x1104204a8 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x1104204a8 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x1104204a8 pending: 0
load_from_database: 0, Complete (0x1104204a8)
SubscriptionStore address: 0x1104204a8 pending: 0
load_from_database: 1, Pending (0x1104204a8)
SubscriptionStore address: 0x1104204a8 pending: 0
load_from_database: 1, Pending (0x1104204a8)
SubscriptionStore address: 0x1104204a8 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x1104204a8 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x1104204a8 pending: 0
load_from_database: 1, Bootstrapping (0x1104204a8)
SubscriptionStore address: 0x109d0c808 pending: 0
load_from_database: 1, Bootstrapping (0x109d0c808)
destructing SubscriptionStore 0x109d0c808
SubscriptionStore address: 0x109e6f958 pending: 0
load_from_database: 1, Bootstrapping (0x109e6f958)
SubscriptionStore address: 0x109e6f958 pending: 0
SubscriptionStore address: 0x109e6f958 pending: 0
load_from_database: 1, Bootstrapping (0x109e6f958)
new notification for version: 1 at: Complete num notifications: 1 for: 0x109e6f958
SubscriptionStore address: 0x1104204a8 pending: 0
load_from_database: 1, Bootstrapping (0x1104204a8)
SubscriptionStore address: 0x1104204a8 pending: 0
update state note size: 0
supercede_prior_to: 1
[{"_key":0,"version":0,"state":3,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":2,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529de4cbf4ed0bf0b3bb4","created_at":"2022-05-18 17:16:14","updated_at":"2022-05-18 17:16:14","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":1,"version":1,"state":2,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"628529de4cbf4ed0bf0b3bb4","created_at":"2022-05-18 17:16:14","updated_at":"2022-05-18 17:16:14","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x1104204a8 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x1104204a8 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x1104204a8 pending: 0
load_from_database: 1, Complete (0x1104204a8)
destructing SubscriptionStore 0x1104204a8
SubscriptionStore address: 0x109e6f958 pending: 1
load_from_database: 1, Complete (0x109e6f958)

Run that is successful:

Filters: flx: interrupted bootstrap restarts/recovers on reconnect
SubscriptionStore address: 0x109f46548 pending: 0
load_from_database: 0, Pending (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 0
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]}]new pk of mutable copy 1
SubscriptionStore address: 0x109f46548 pending: 0
load_from_database: 1, Uncommitted (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x109f46548 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x109f46548 pending: 0
load_from_database: 1, Pending (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 0
SubscriptionStore address: 0x109f46548 pending: 0
load_from_database: 1, Pending (0x109f46548)
new notification for version: 1 at: Complete num notifications: 1
SubscriptionStore address: 0x109f46548 pending: 1
load_from_database: 0, Pending (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 1
update state note size: 1
supercede_prior_to: 0
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285251b15f1fafff88e6805","created_at":"2022-05-18 16:55:55","updated_at":"2022-05-18 16:55:55","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285251b15f1fafff88e6805","created_at":"2022-05-18 16:55:55","updated_at":"2022-05-18 16:55:55","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x109f46548 pending: 1
MutableSubscriptionSet::commit() with not size: 1
SubscriptionStore address: 0x109f46548 pending: 1
process_notifications:  lock with size: 1
skipping notification for version : 1 state: Complete min_outstanding: 0
SubscriptionStore address: 0x109f46548 pending: 1
load_from_database: 0, Complete (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 1
load_from_database: 1, Pending (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 1
load_from_database: 0, Complete (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 1
update state note size: 1
supercede_prior_to: 0
[{"_key":0,"version":0,"state":3,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285251b15f1fafff88e6805","created_at":"2022-05-18 16:55:55","updated_at":"2022-05-18 16:55:55","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":0,"version":0,"state":3,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285251b15f1fafff88e6805","created_at":"2022-05-18 16:55:55","updated_at":"2022-05-18 16:55:55","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x109f46548 pending: 1
MutableSubscriptionSet::commit() with not size: 1
SubscriptionStore address: 0x109f46548 pending: 1
process_notifications:  lock with size: 1
skipping notification for version : 1 state: Complete min_outstanding: 0
SubscriptionStore address: 0x109f46548 pending: 1
load_from_database: 0, Complete (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 1
load_from_database: 1, Pending (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 1
update state note size: 1
supercede_prior_to: 1
[{"_key":0,"version":0,"state":3,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285251b15f1fafff88e6805","created_at":"2022-05-18 16:55:55","updated_at":"2022-05-18 16:55:55","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285251b15f1fafff88e6805","created_at":"2022-05-18 16:55:55","updated_at":"2022-05-18 16:55:55","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x109f46548 pending: 1
MutableSubscriptionSet::commit() with not size: 1
SubscriptionStore address: 0x109f46548 pending: 1
process_notifications:  lock with size: 1
will finish for version : 1
SubscriptionStore address: 0x109f46548 pending: 0
load_from_database: 1, Complete (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 0
load_from_database: 1, Complete (0x109f46548)
SubscriptionStore address: 0x109f46548 pending: 0
update state note size: 0
supercede_prior_to: 1
[{"_key":1,"version":1,"state":3,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285251b15f1fafff88e6805","created_at":"2022-05-18 16:55:55","updated_at":"2022-05-18 16:55:55","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":1,"version":1,"state":3,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285251b15f1fafff88e6805","created_at":"2022-05-18 16:55:55","updated_at":"2022-05-18 16:55:55","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x109f46548 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x109f46548 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x109f46548 pending: 0
load_from_database: 1, Complete (0x109f46548)
destructing SubscriptionStore 0x109f46548
SubscriptionStore address: 0x10ba17268 pending: 0
load_from_database: 0, Pending (0x10ba17268)
SubscriptionStore address: 0x10ba17268 pending: 0
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]}]new pk of mutable copy 1
SubscriptionStore address: 0x10ba17268 pending: 0
load_from_database: 1, Uncommitted (0x10ba17268)
SubscriptionStore address: 0x10ba17268 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x10ba17268 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x10ba17268 pending: 0
load_from_database: 1, Pending (0x10ba17268)
SubscriptionStore address: 0x10ba17268 pending: 0
load_from_database: 0, Pending (0x10ba17268)
SubscriptionStore address: 0x10ba17268 pending: 0
update state note size: 0
supercede_prior_to: 0
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285253515f1fafff88e680b","created_at":"2022-05-18 16:56:21","updated_at":"2022-05-18 16:56:21","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":0,"version":0,"state":1,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285253515f1fafff88e680b","created_at":"2022-05-18 16:56:21","updated_at":"2022-05-18 16:56:21","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x10ba17268 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x10ba17268 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x10ba17268 pending: 0
load_from_database: 0, Complete (0x10ba17268)
SubscriptionStore address: 0x10ba17268 pending: 0
load_from_database: 1, Pending (0x10ba17268)
SubscriptionStore address: 0x10ba17268 pending: 0
load_from_database: 0, Complete (0x10ba17268)
SubscriptionStore address: 0x10ba17268 pending: 0
update state note size: 0
supercede_prior_to: 0
[{"_key":0,"version":0,"state":3,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285253515f1fafff88e680b","created_at":"2022-05-18 16:56:21","updated_at":"2022-05-18 16:56:21","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":0,"version":0,"state":3,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":1,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285253515f1fafff88e680b","created_at":"2022-05-18 16:56:21","updated_at":"2022-05-18 16:56:21","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x10ba17268 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x10ba17268 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x10ba17268 pending: 0
load_from_database: 0, Complete (0x10ba17268)
SubscriptionStore address: 0x10ba17268 pending: 0
load_from_database: 1, Pending (0x10ba17268)
SubscriptionStore address: 0x10ba17268 pending: 0
MutableSubscriptionSet::commit() with not size: 0
SubscriptionStore address: 0x10ba17268 pending: 0
process_notifications:  lock with size: 0
SubscriptionStore address: 0x10ba17268 pending: 0
load_from_database: 1, Bootstrapping (0x10ba17268)
SubscriptionStore address: 0x109f47b08 pending: 0
load_from_database: 1, Bootstrapping (0x109f47b08)
destructing SubscriptionStore 0x109f47b08
SubscriptionStore address: 0x109f49c78 pending: 0
load_from_database: 1, Bootstrapping (0x109f49c78)
SubscriptionStore address: 0x109f49c78 pending: 0
SubscriptionStore address: 0x109f49c78 pending: 0
load_from_database: 1, Bootstrapping (0x109f49c78)
new notification for version: 1 at: Complete num notifications: 1
destructing SubscriptionStore 0x10ba17268
SubscriptionStore address: 0x109f49c78 pending: 1
load_from_database: 0, Complete (0x109f49c78)
SubscriptionStore address: 0x109f49c78 pending: 1
load_from_database: 1, Bootstrapping (0x109f49c78)
SubscriptionStore address: 0x109f49c78 pending: 1
load_from_database: 1, Bootstrapping (0x109f49c78)
SubscriptionStore address: 0x109f49c78 pending: 1
MutableSubscriptionSet::commit() with not size: 1
SubscriptionStore address: 0x109f49c78 pending: 1
process_notifications:  lock with size: 1
skipping notification for version : 1 state: Bootstrapping min_outstanding: 0
SubscriptionStore address: 0x109f49c78 pending: 1
load_from_database: 1, Bootstrapping (0x109f49c78)
SubscriptionStore address: 0x109f49c78 pending: 1
load_from_database: 1, Bootstrapping (0x109f49c78)
SubscriptionStore address: 0x109f49c78 pending: 1
update state note size: 1
supercede_prior_to: 1
[{"_key":0,"version":0,"state":3,"snapshot_version":3,"error":null,"subscriptions":[]},{"_key":1,"version":1,"state":2,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285253515f1fafff88e680b","created_at":"2022-05-18 16:56:21","updated_at":"2022-05-18 16:56:21","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]before <<<<<
[{"_key":1,"version":1,"state":2,"snapshot_version":5,"error":null,"subscriptions":[{"_key":0,"id":"6285253515f1fafff88e680b","created_at":"2022-05-18 16:56:21","updated_at":"2022-05-18 16:56:21","name":null,"object_class":"TopLevel","query":"TRUEPREDICATE"}]}]after supercede <<<<
SubscriptionStore address: 0x109f49c78 pending: 1
MutableSubscriptionSet::commit() with not size: 1
SubscriptionStore address: 0x109f49c78 pending: 1
process_notifications:  lock with size: 1
will finish for version : 1
SubscriptionStore address: 0x109f49c78 pending: 0
load_from_database: 1, Complete (0x109f49c78)
SubscriptionStore address: 0x109f49c78 pending: 0
load_from_database: 1, Complete (0x109f49c78)
SubscriptionStore address: 0x109f49c78 pending: 0
load_from_database: 1, Complete (0x109f49c78)
destructing SubscriptionStore 0x109f49c78
76.660 s: flx: interrupted bootstrap restarts/recovers on reconnect
===============================================================================
All tests passed (16 assertions in 1 test case)

ironage avatar May 18 '22 18:05 ironage

The prints can be found in this branch: https://github.com/realm/realm-core/tree/js/debug-hang-prints

ironage avatar May 18 '22 18:05 ironage

➤ Jonathan Reams commented:

I haven't seen this hang in months, so I am going to close this for now. If we see this test hanging again in a similar way, we can re-open this.

sync-by-unito[bot] avatar Sep 20 '22 21:09 sync-by-unito[bot]