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

Order messages by creation date, not indexing date #7

Open
AvivRubys opened this issue Aug 6, 2023 · 0 comments
Open

Order messages by creation date, not indexing date #7

AvivRubys opened this issue Aug 6, 2023 · 0 comments
Labels
good first issue Good for newcomers

Comments

@AvivRubys
Copy link
Owner

Right now, we only save the indexing timestamp of each post, i.e. the timestamp that we received the firehose message in:

return {
uri: create.uri,
author: create.author,
cid: create.cid,
replyTo: create.record.reply?.parent.uri,
replyRoot: create.record.reply?.root.uri,
indexedAt: new Date().toISOString(),
language,
};

That's maybe interesting to save, but why would we display posts by indexing date rather than by actual creation date? The CreateOp record also has a createdAt field, why don't we use it instead? This boils down to -

  1. Add a new column for the new timestamp and populate it in the firehose subscription
  2. Figure out a backfill strategy - take the existing indexedAt value? access the api and get the real value?
  3. Change the feeds to order based on the new creation date column
@AvivRubys AvivRubys added the good first issue Good for newcomers label Aug 6, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

1 participant