-
Notifications
You must be signed in to change notification settings - Fork 80
feat(cluster-state-service): add ping endpoint #195
Conversation
I'm having trouble getting this to build locally on my fork because of dependency issues. It looks like go isn't playing nicely with the This is also my first contribution to the project, so I may need some help getting this all together. |
Tests pass on Travis though! So I think this is in pretty good shape |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nitpick changes requested.
"github.com/blox/blox/cluster-state-service/handler/store" | ||
) | ||
|
||
// TaskAPIs encapsulates the backend datastore with which the task APIs interact |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you fix this comment, since this isn't TaskAPIs?
|
||
// TaskAPIs encapsulates the backend datastore with which the task APIs interact | ||
type GeneralAPIs struct { | ||
taskStore store.TaskStore |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This probably doesn't need a taskStore object.
taskStore store.TaskStore | ||
} | ||
|
||
// NewTaskAPIs initializes the TaskAPIs struct |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same fix request for this comment.
suite.router = suite.getRouter() | ||
} | ||
|
||
// TODO - Add the following test cases once implementation is in place |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you remove this comment block?
Looks good @dominicbarnes, thanks for the commit. I've requested a couple nitpick changes though before I merge it in. Can you update your pull request with the changes requested? Confirmed unit tests pass. Also verified
|
Closing due to inactivity. Please feel free to re-open after addressing PR comments. |
Summary
Adds a "ping" endpoint to
cluster-state-service
at/v1/ping
which behaves exactly like the same endpoint indaemon-scheduler
. (fixes #194)Implementation details
I copy-pasta'd a lot over from
daemon-scheduler
.Testing
cd cluster-state-service; make; cd ../
)cd cluster-state-service; make release; cd ../
)cd daemon-scheduler; make; cd ../
)cd daemon-scheduler; make release; cd ../
)New tests cover the changes: yes
Description for the changelog
added a health check endpoint
Licensing
This contribution is under the terms of the Apache 2.0 License: Yes
Before merging