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 versioning to PoST data directory via postdata_metadata.json file #211

Open
wants to merge 7 commits into
base: develop
Choose a base branch
from

Conversation

fasmat
Copy link
Member

@fasmat fasmat commented Aug 3, 2023

Description

This introduces versioning to PoST data (closes #210 ). The version is stored inside the postdata_metadata.json file. If no version is present Version 0 is assumed which will be migrated to version 1.

Version 1 has the following changes over Version 0:

  • A missing NonceValue is added if Nonce is present.
  • The ScryptParams that were used to generate the PoST data were added to the metadata file.

These additions allow changes to how the data is stored on disk and allow for smooth migrations from an older version of PoST to a newer version.

TODO:

@fasmat fasmat self-assigned this Aug 3, 2023
@fasmat fasmat changed the title Add versioning to PoST data directory via postdata_metadata.json file WiP: Add versioning to PoST data directory via postdata_metadata.json file Aug 3, 2023
@fasmat fasmat force-pushed the 210-introduce-data-migration branch 2 times, most recently from 5e5bed7 to 8546cbf Compare August 4, 2023 09:12
@fasmat fasmat force-pushed the 210-introduce-data-migration branch from 5683089 to 51e58d3 Compare August 12, 2023 15:31
@fasmat fasmat force-pushed the 210-introduce-data-migration branch 3 times, most recently from 9c13377 to 40c62a1 Compare September 7, 2023 15:17
@codecov
Copy link

codecov bot commented Sep 12, 2023

Codecov Report

Merging #211 (2971af2) into develop (fdb2b5b) will decrease coverage by 1.5%.
The diff coverage is 53.7%.

@@            Coverage Diff            @@
##           develop    #211     +/-   ##
=========================================
- Coverage     68.6%   67.2%   -1.5%     
=========================================
  Files           28      29      +1     
  Lines         1862    1974    +112     
=========================================
+ Hits          1279    1328     +49     
- Misses         435     485     +50     
- Partials       148     161     +13     
Files Changed Coverage Δ
shared/post_metadata.go 28.9% <17.2%> (-37.8%) ⬇️
initialization/migrate_metadata.go 57.5% <57.5%> (ø)
initialization/initialization.go 75.7% <81.2%> (-0.4%) ⬇️
config/config.go 58.9% <100.0%> (+1.4%) ⬆️
oracle/oracle.go 78.2% <100.0%> (ø)
verifying/verifying_options.go 48.2% <100.0%> (ø)

@fasmat fasmat requested a review from poszu September 12, 2023 08:44
@fasmat fasmat marked this pull request as ready for review September 12, 2023 08:44
@fasmat fasmat changed the title WiP: Add versioning to PoST data directory via postdata_metadata.json file Add versioning to PoST data directory via postdata_metadata.json file Sep 12, 2023
@fasmat fasmat force-pushed the 210-introduce-data-migration branch 2 times, most recently from 745e3a0 to fbac134 Compare September 19, 2023 10:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant