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

Implement Sqlite backends for Contacts service and Wallet peer db #1071

Merged
merged 1 commit into from
Nov 29, 2019

Conversation

philipr-za
Copy link
Contributor

@philipr-za philipr-za commented Nov 26, 2019

Description

This PR adds a Sqlite backend for the Contacts Service and the Peer database for the wallet

It also update the respective integration tests to test using both the sqlite and memory db’s

Motivation and Context

Closes #938

How Has This Been Tested?

test provided

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Feature refactor (No new feature or functional changes, but performance or technical debt improvements)
  • New Tests
  • Documentation

Checklist:

  • I'm merging against the development branch
  • I ran cargo-fmt --all before pushing
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.

@philipr-za philipr-za added this to the TestNet Release milestone Nov 26, 2019
@philipr-za philipr-za force-pushed the philip-contacts-wallet-sqlite branch 3 times, most recently from 36d11f8 to f02a5a0 Compare November 27, 2019 07:10
This PR adds a Sqlite backend for the Contacts Service and the Peer database for the wallet

It also update the respective integration tests to test using both the sqlite and memory db’s
Copy link
Collaborator

@CjS77 CjS77 left a comment

Choose a reason for hiding this comment

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

LGTM, one nit

is_read INTEGER NOT NULL DEFAULT 0,
FOREIGN KEY(dest_pub_key) REFERENCES contacts(pub_key)
);
-- CREATE TABLE sent_messages (
Copy link
Collaborator

Choose a reason for hiding this comment

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

Shouldn't you just nuke these rather than comment them out, since you delete the diesel table definitions in schema.rs?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

schema.rs is generated from these migrations and these will come back in if we do text messaging so I thought best to leave them here for the future.

Copy link
Member

@sdbondi sdbondi left a comment

Choose a reason for hiding this comment

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

LGTM

CjS77 added a commit that referenced this pull request Nov 29, 2019
)

Merge pull request #1071

This PR adds a Sqlite backend for the Contacts Service and the Peer
database for the wallet

It also update the respective integration tests to test using both the
sqlite and memory db’s
@CjS77 CjS77 merged commit 4accd2a into development Nov 29, 2019
@CjS77 CjS77 deleted the philip-contacts-wallet-sqlite branch November 29, 2019 06:14
CjS77 added a commit that referenced this pull request Dec 2, 2019
)

Merge pull request #1071

This PR adds a Sqlite backend for the Contacts Service and the Peer
database for the wallet

It also update the respective integration tests to test using both the
sqlite and memory db’s
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.

Implement Sqlite backend for Wallet
3 participants