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

add ADR002 to document the storage #57

Merged
merged 3 commits into from
May 16, 2024
Merged

add ADR002 to document the storage #57

merged 3 commits into from
May 16, 2024

Conversation

konnov
Copy link
Contributor

@konnov konnov commented May 16, 2024

This PR documents a simple design for storing the transactions that are to be extracted by the fetcher.

@konnov konnov self-assigned this May 16, 2024
@konnov konnov added the documentation Improvements or additions to documentation label May 16, 2024
@konnov konnov added this to the M1: Transaction extractor milestone May 16, 2024
doc/adr002-storage.md Outdated Show resolved Hide resolved

- It should be relatively easy to order these transactions, e.g., by ledger height.

- Transactions that happen in the same block should not collide.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What do you mean by "collide"? In the database sense, have the same primary key?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yeah, basically, the block number cannot be used as the unique identifier

Copy link
Collaborator

@thpani thpani left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

1 question, otw LGTM

Given all these requirements, we store every contract call in its own file called:

```
${STOR}/${contractId}/${height}/entry-${txHash}.json
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So you want to say anything about the content format of these files?

Even if it's just pointing to the implementation, I think it would be helpful.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added a comment

konnov and others added 2 commits May 16, 2024 14:41
@konnov konnov merged commit f5c62a4 into main May 16, 2024
3 checks passed
@konnov konnov deleted the igor/storage-adr branch May 16, 2024 13:42
This was referenced Jun 19, 2024
Closed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants