Note: This is a beta version and NOT ready for use in production.
Identity
- Unregister users over WAMP without their password (internal use only)
- Replace the
delete_usercall withuser_exists.delete_userstays for API servers older than this release. - Clear cached tokens by calling each server, instead of publishing a message
- Keep ended sessions' cache keys until their tokens are cleared, so a retried clear can't succeed while revoked tokens still work
Sync
- Delete accounts in the background. The account is marked deleted and unregistered from Identity right away;
UserPurgeJobremoves its data after a grace period. Open sync connections of a deleted user are cut off. - Reset accounts without deleting their data in the request. A reset increments the user's generation in one transaction, so the old data disappears immediately, and
UserPurgeJobdeletes it in the background. Pushes that cross a reset are rejected, and devices that fetch across one still do a full sync. - Log out the other devices before a reset, and after a password change
- Count failed purges for alerting (
users_purge_failures) - Use less memory to send items: fetches send each chunk straight from the stored BSON, and chunks are bounded by stored size (3MB) and count (500)
- Drop the MessagePack hub protocol. Clients have used JSON since 2.6.17.
- Label fetch failures by reason (
disconnected,timeout,client_error,server_error), and count refused sync connections (sync_v2_connection_rejections) instead of logging each one as an error
Upgrading
- Deploy Identity before the API. The API now calls Identity's
user_exists, which older Identity servers don't have. - Don't run API servers from before and after this release side by side. Replace them all at once.
- If you run more than one API replica, set
CACHE_REDIS_CONNECTION_STRING. Without it, each replica keeps its own token cache, and a revoked token keeps working on the replicas that didn't clear it.
Test drive
wget https://raw.githubusercontent.com/streetwriters/notesnook-sync-server/v1.0-beta.45/docker-compose.yml
wget https://raw.githubusercontent.com/streetwriters/notesnook-sync-server/v1.0-beta.45/.env
docker compose upMake sure everything is up and running:
docker psAll the above services must show (healthy) in the output.
Full Changelog: v1.0-beta.44...v1.0-beta.45