Closed stevensJourney closed 2 months ago
Latest commit: cda9e954e301a122d8bfa413adac14d449ee46d8
The changes in this PR will be included in the next version bump.
Not sure what this means? Click here to learn what changesets are.
Click here if you're a maintainer who wants to add another changeset to this PR
Overview
This fixes a bug when using multiple tab functionality where: the Shared sync manager would "hold on" to credentials previously provided to it. This was due to the shared worker previously mainlining a single instance of
AbstractStreamingSyncImplementation
. This implementation would use cached credentials until they expired. This is particularly bad if the tab remains open afterdisconnectAndClear
has been called and the user has "signed out".Most of our SDKs currently create a new instance of the StreamingSync implementation on each
connect
call. This effectively will clear any caches.The shared sync manager now creates the streaming sync implementation when the
connect
call is invoked. This ensures thefetchCredentials
of theBackendConnector
is called for each call toconnect
.