Skip to content

feat(platform)!: created at updated at from block time - #1780

Merged
QuantumExplorer merged 7 commits into
v1.0-devfrom
feat/createdAtUpdatedAtFromBlockTime
Mar 15, 2024
Merged

QuantumExplorer merged 7 commits into
v1.0-devfrom
feat/createdAtUpdatedAtFromBlockTime

Conversation

@QuantumExplorer

@QuantumExplorer QuantumExplorer commented Mar 15, 2024 •

Copy link
Copy Markdown
Member

Issue being fixed or feature implemented

Previously before this PR, users submitting documents were expected to set the document created at and updated at time on the client side. Then Platform would validate in consensus that these values were close to to the current block time. This approach had a few downsides. First it meant that documents in mempool would expire even though users did nothing wrong. The second is that it required users to have a clock that was very close in time to the network time.

What was done?

Now created at and updated at are set by the block time. Meaning that they are automatic and users have nothing to set manually.

How Has This Been Tested?

Test suite is passing

Breaking Changes

This is a breaking change.

Checklist:

  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added or updated relevant unit/integration/functional/e2e tests
  • I have added "!" to the title and described breaking changes in the corresponding section if my code contains any
  • I have made corresponding changes to the documentation if needed

For repository code-owners and collaborators only

  • I have assigned this pull request to a milestone

@shumkov

shumkov commented Mar 15, 2024

Copy link
Copy Markdown
Collaborator

@QuantumExplorer feel free to merge it when you resolve my comments.

shumkov
shumkov previously approved these changes Mar 15, 2024

@shumkov shumkov left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

@QuantumExplorer My approval in advance if you gonna be a good boy.

@QuantumExplorer
QuantumExplorer merged commit f133e81 into v1.0-dev Mar 15, 2024
@QuantumExplorer
QuantumExplorer deleted the feat/createdAtUpdatedAtFromBlockTime branch March 15, 2024 12:43
@QuantumExplorer QuantumExplorer changed the title feat: created at updated at from block time feat(platform)!: created at updated at from block time Mar 15, 2024
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.

3 participants