http: Added a Gin http receiver sample#842
Merged
lionelvillard merged 1 commit intocloudevents:mainfrom Jun 1, 2023
Merged
Conversation
Contributor
|
@dgeorgievski can you rebase your PR? |
Signed-off-by: Dimitar Georgievski <dgeorgievski@gmail.com>
65299fc to
215ea79
Compare
Contributor
Author
|
Rebased |
Contributor
|
thanks! |
embano1
reviewed
Jun 1, 2023
Comment on lines
+11
to
+12
| go get github.com/gin-gonic/gin | ||
| go get github.com/rs/zerolog/log |
Member
There was a problem hiding this comment.
Suggested change
| go get github.com/gin-gonic/gin | |
| go get github.com/rs/zerolog/log | |
| go get . |
| go run main.go | ||
| ``` | ||
|
|
||
| Test a CloudEvent |
Member
There was a problem hiding this comment.
Suggested change
| Test a CloudEvent | |
| Send a CloudEvent |
| ```shell | ||
| curl -v \ | ||
| -H "Ce-Id: e7d95c20-6eb4-4614-946d-27b0ce41c7ff" \ | ||
| -H "Ce-Source: /apis///namespaces/dimitar//clone-build-n4qhgl" \ |
Member
There was a problem hiding this comment.
Suggested change
| -H "Ce-Source: /apis///namespaces/dimitar//clone-build-n4qhgl" \ | |
| -H "Ce-Source: /apis/namespaces/dimitar/clone-build-n4qhgl" \ |
Member
There was a problem hiding this comment.
or is the above a real value from the example event?
| } | ||
|
|
||
| func cloudEventsHandler() gin.HandlerFunc { | ||
|
|
| } | ||
|
|
||
| func main() { | ||
|
|
lionelvillard
added a commit
that referenced
this pull request
Jun 1, 2023
This reverts commit 9970acc.
Contributor
|
Oops sorry @embano1, I went a bit fast on this one. @dgeorgievski Can you address @dgeorgievski comments in a different PR ? |
dgeorgievski
added a commit
to dgeorgievski/sdk-go
that referenced
this pull request
Jun 2, 2023
Fixes for prematurely closed cloudevents#842 PR. Applied all suggested code and doc changes..
dgeorgievski
added a commit
to dgeorgievski/sdk-go
that referenced
this pull request
Jun 2, 2023
Fixes for prematurely closed cloudevents#842 PR. Applied all suggested code and doc changes.. Signed-off-by: Dimitar Georgievski <dgeorgievski@gmail.com>
dgeorgievski
added a commit
to dgeorgievski/sdk-go
that referenced
this pull request
Jun 5, 2023
Fixes for prematurely closed cloudevents#842 PR. Applied all suggested code and doc changes.. Signed-off-by: Dimitar Georgievski <dgeorgievski@gmail.com>
lionelvillard
pushed a commit
that referenced
this pull request
Jun 8, 2023
Fixes for prematurely closed #842 PR. Applied all suggested code and doc changes.. Signed-off-by: Dimitar Georgievski <dgeorgievski@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
A simple example of a Gin http receiver for CloudEvents. The Gorilla/mux project is archived which makes the existing gorilla receiver example deprecated.