-
Notifications
You must be signed in to change notification settings - Fork 1.6k
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
Add event API v2 server handler #5622
Add event API v2 server handler #5622
Conversation
Codecov Report
@@ Coverage Diff @@
## master #5622 +/- ##
==========================================
- Coverage 70.79% 70.68% -0.12%
==========================================
Files 406 407 +1
Lines 15461 15554 +93
==========================================
+ Hits 10946 10994 +48
- Misses 3711 3752 +41
- Partials 804 808 +4
Continue to review full report at Codecov.
|
Still need to add tests, but putting this up here in case anyone wants to take a look :) |
@@ -190,6 +241,19 @@ func emptyStatusCheckState() *proto.StatusCheckState { | |||
} | |||
} | |||
|
|||
func AutoTriggerDiff(name string, val bool) (bool, error) { | |||
switch name { | |||
case "build": |
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.
we could reuse pkg/errors.Phase
type and add sync
to it?
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.
Good point! I'll update this in a follow up
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.
Related: #5422 , #5368
Description
Adds
pkg/skaffold/server/v2
package which contains a new struct that handles the endpoints for the v2 API. Users will now be able to hit both the v1 and v2 endpoints through the running gRPC server.Most of the server definition is copied from
pkg/skaffold/server
files, and the functions added topkg/skaffold/event/v2/event.go
are straight frompkg/skaffold/event/event.go
Follow-up Work (remove if N/A)
Emit protos on this server