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

db: orchestrator count sql query #1180

Merged
merged 1 commit into from
Nov 13, 2019

Conversation

kyriediculous
Copy link
Contributor

What does this pull request do? Explain your changes. (required)
This PR adds an SQL query that gets a count of orchestrators according to the passed in DBOrchFilter

Specific updates (required)

  • Added a new exported method to DB db.OrchCount(filter *DBOrchFilter) (int, error) that returns the number or orchestrators in the db that pass filter
  • Added a helper that creates the sql query used in OrchCount
  • added a unit test for the new query

How did you test each of these updates (required)
ran unit tests

Does this pull request close any open issues?
Fixes #1153

Checklist:

  • README and other documentation updated
  • Node runs in OSX and devenv
  • All tests in ./test.sh pass

common/db.go Outdated Show resolved Hide resolved
common/db_test.go Outdated Show resolved Hide resolved
common/db_test.go Outdated Show resolved Hide resolved
common/db_test.go Outdated Show resolved Hide resolved
common/db.go Outdated Show resolved Hide resolved
@yondonfu
Copy link
Member

Let's rebase

@kyriediculous
Copy link
Contributor Author

kyriediculous commented Nov 13, 2019 via email

@yondonfu
Copy link
Member

yondonfu commented Nov 13, 2019

3cc883f looks like a duplicate commit (already exists in #1171)? Can it be dropped?

@kyriediculous
Copy link
Contributor Author

Hmm not sure what went wrong there, dropped after rebasing again.

Copy link
Member

@yondonfu yondonfu left a comment

Choose a reason for hiding this comment

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

LGTM 🚢

@kyriediculous kyriediculous merged commit 459f1e9 into nv/db-orchestrator-updates Nov 13, 2019
@kyriediculous kyriediculous deleted the nv/orchcount-query branch November 13, 2019 22:26
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.

None yet

2 participants