Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

Update lisk-chain to use lisk-db - Closes #5257 #5314

Merged
merged 11 commits into from
May 14, 2020

Conversation

shuse2
Copy link
Collaborator

@shuse2 shuse2 commented May 7, 2020

What was the problem?

This PR resolves #5257

How was it solved?

  • Updated lisk-chain to use the lisk-db instance instead of storage
  • Remove prepare step from transactions

How was it tested?

  • Add integration tests for the dataAccess/storage
  • Update all the tests

@shuse2 shuse2 changed the title Update lisk-chain to use lisk-db Update lisk-chain to use lisk-db - Closes #5357 May 7, 2020
@shuse2 shuse2 changed the title Update lisk-chain to use lisk-db - Closes #5357 Update lisk-chain to use lisk-db - Closes #5257 May 7, 2020
@shuse2 shuse2 self-assigned this May 7, 2020
@shuse2 shuse2 marked this pull request as ready for review May 11, 2020 16:16
elements/lisk-chain/src/chain.ts Show resolved Hide resolved
Comment on lines +420 to +422
const batch = this._db.batch();
stateStore.finalize(batch);
await batch.write();
Copy link
Contributor

Choose a reason for hiding this comment

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

Can we move this logic to dataAccess object?

elements/lisk-chain/src/data_access/constants.ts Outdated Show resolved Hide resolved
elements/lisk-chain/src/data_access/storage.ts Outdated Show resolved Hide resolved
elements/lisk-chain/src/data_access/storage.ts Outdated Show resolved Hide resolved
elements/lisk-chain/src/data_access/storage.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@pablitovicente pablitovicente left a comment

Choose a reason for hiding this comment

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

Just some comments the rest seems ok!

@shuse2 shuse2 requested a review from nazarhussain May 13, 2020 13:11
@shuse2 shuse2 changed the base branch from development to 5243-manage-db-instances May 13, 2020 15:36
@shuse2 shuse2 changed the base branch from 5243-manage-db-instances to development May 13, 2020 19:51
@shuse2 shuse2 merged commit 8fef52a into development May 14, 2020
@shuse2 shuse2 deleted the 5257-update_db_usage branch May 14, 2020 12:49
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Update lisk-chain data_access layer
6 participants