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

Market decentralized - database models #269

Merged
merged 25 commits into from
Jun 4, 2020

Conversation

nieznanysprawiciel
Copy link
Contributor

@nieznanysprawiciel nieznanysprawiciel commented May 19, 2020

  • Database models (Offer, Demand)
  • Endpoints for subscribe and unsubscribe (for both Offers and Demands)
  • Unimplemented empty functions for remaining market endpoints
  • Yagna service has separate database for each service
    • Identity uses db named yagna to keep compatibility with previous keys
    • Service::rest gets ServiceContext in parameter instead of DbExecutor directly
  • Offers and Demands Ids uniqueness - random part + content hash

Postponed for later:

  • Unsubscribe endpoints caller authorization

core/serv/Cargo.toml Outdated Show resolved Hide resolved
@nieznanysprawiciel nieznanysprawiciel marked this pull request as ready for review May 26, 2020 11:21
@tworec tworec force-pushed the market-decentralized/db-models branch from 4117c4b to 51d9269 Compare May 26, 2020 16:43
@tworec tworec force-pushed the market-decentralized/db-models branch from 51d9269 to ad74b00 Compare May 26, 2020 16:54
@tworec tworec force-pushed the market-decentralized/db-models branch from ad74b00 to 30edee1 Compare May 26, 2020 17:13
@tworec tworec changed the base branch from master to service-ctx-sep-dbs May 26, 2020 20:25
Base automatically changed from service-ctx-sep-dbs to master May 27, 2020 10:45
core/market/decentralized/src/api.rs Outdated Show resolved Hide resolved
core/market/decentralized/src/api.rs Outdated Show resolved Hide resolved
core/market/decentralized/src/api.rs Outdated Show resolved Hide resolved
core/market/decentralized/src/db/models/subscription.rs Outdated Show resolved Hide resolved
core/market/decentralized/src/market.rs Outdated Show resolved Hide resolved
core/market/decentralized/src/market.rs Outdated Show resolved Hide resolved
// TODO: Run matching to find local matching demands. We shouldn't wait here.
// TODO: Handle broadcast errors. Maybe we should retry if it failed.
self.discovery
.broadcast_offer(model_offer.into_client_offer()?)
Copy link
Contributor

Choose a reason for hiding this comment

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

diesel.toml Outdated Show resolved Hide resolved
core/market/decentralized/src/api/provider.rs Outdated Show resolved Hide resolved
core/market/decentralized/src/db/models/demand.rs Outdated Show resolved Hide resolved
core/market/decentralized/src/matcher/matcher.rs Outdated Show resolved Hide resolved
tworec
tworec previously approved these changes Jun 3, 2020
@nieznanysprawiciel nieznanysprawiciel merged commit c5fc1d3 into master Jun 4, 2020
@nieznanysprawiciel nieznanysprawiciel linked an issue Jun 4, 2020 that may be closed by this pull request
3 tasks
@tworec tworec deleted the market-decentralized/db-models branch June 4, 2020 17:42
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.

Network Offer Discovery
2 participants