Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Dirty cache on update of profile information in Ceramic #921

Closed
dysbulic opened this issue Nov 12, 2021 · 1 comment · Fixed by #943
Closed

Dirty cache on update of profile information in Ceramic #921

dysbulic opened this issue Nov 12, 2021 · 1 comment · Fixed by #943
Labels
backend Backend related issues feature request Feature Requests

Comments

@dysbulic
Copy link
Member

What would you like to be added?

The Hasura updateSingle action should be triggered when profile information is updated in Ceramic (#920).

There are two separate documents used to store the profile information. Both could be retrieved when the cache is invalidated, but it would be more efficient to only pull the one that was changed.

This will be slightly more important when, eventually, the cache needs to be invalidated when a user adds a verified account.

Why is this needed?

The cache should be as up to date as reasonably possible, and invalidating it when changes are known is one way of doing that.

It is theoretically possible to update the cache with the values inputted for the profile, and not have to query the Ceramic network, but in practice this is error prone.

@dysbulic dysbulic added backend Backend related issues feature request Feature Requests labels Nov 12, 2021
@dysbulic dysbulic linked a pull request Dec 27, 2021 that will close this issue
@dysbulic
Copy link
Member Author

Currently when the cache reloads, it loads the contents of three streams: the basic profile, the extended profile, & the account attestations. Theoretically, when the cache is dirtied, the specific keys affected could be passed to the caching system & only the needed streams could be loaded.

This complexity is left to some future developer and for the time being we'll simply load all three.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backend Backend related issues feature request Feature Requests
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant