Skip to content

Move uploader out of acid-state #1394

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

Draft
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

Kleidukos
Copy link
Member

@Kleidukos Kleidukos commented May 12, 2025

Follow-up of #1375 to use a Map rather than storing usernames in acid-state.

Since the datatype used for storage no longer reflects the shape of the API payload, I made a separate DTO for it.

@Kleidukos
Copy link
Member Author

@gbaz I'm still unclear on how to initialise the Map and keep it updated. Shall we pass it in a TVar, and update it in the upload endpoint? Again, I'm very unfamiliar with the usual patterns of this project, but I'm willing to learn! :)

@Kleidukos
Copy link
Member Author

Kleidukos commented May 22, 2025

@gbaz I'd be grateful if you could help me put the last pieces of the puzzle together, when time permits. :)

@gbaz
Copy link
Contributor

gbaz commented May 25, 2025

ok i think i see the confusion. what i mean is why do we need any acid-state for any of this? can't we just compute it on the fly? before i had suggested a better way to cache, but i don't think we need to cache it either. hitting these endpoints should be rare, and all the data is available to query elsewhere. I think we shouldn't need acid-state specific to back this json endpoint at all, much less to migrate it.

@Kleidukos
Copy link
Member Author

@gbaz ok then I must be mis-understanding the role of acid-state. In my head it's the one source of truth to fetch persistent data related to the index, including who has uploaded what. If the data isn't coming from acid-state, where does it come from?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants