Commit Graph

20 Commits

Author SHA1 Message Date
Victor Agababov 74c5d67ea0 Fix the issues pointed out by staticcheck (#541)
* Fix the issues pointed out by staticcheck

* review fix
2019-07-23 13:13:36 -07:00
mattmoor-sockpuppet 1864f499dc golang format tools (#497)
Produced via:
  `gofmt -s -w $(find -path './vendor' -prune -o -type f -name '*.go' -print))`
  `goimports -w $(find -name '*.go' | grep -v vendor)`
/assign @mattmoor
2019-06-27 07:37:08 -07:00
chaodaiG 1104d6c755 update readme with knative.dev/pkg (#495) 2019-06-26 14:56:08 -07:00
Matt Moore 222dd25986 Migrate pkg to use the knative.dev/pkg import path (#489)
* Manual changes.

* scripted changes.
2019-06-26 13:02:06 -07:00
Adriano Cunha c0132d9dde Update OWNERS to use OWNERS_ALIASES (#422) 2019-05-29 20:04:33 -07:00
Scott Nichols fda62c696b Revert delete of cloudevents. (#356) 2019-03-29 16:01:54 -07:00
Scott Nichols 5e5f376ef5 Delete pkg/cloudevents, use cloudevents/sdk-go instead. (#330)
* Delete pkg/cloudevents, use cloudevents/sdk-go instead.

* update deps.
2019-03-19 17:55:46 -07:00
mattmoor-sockpuppet 4f143e6ce3 golang format tools (#263)
Produced via:
  `gofmt -s -w $(find -path './vendor' -prune -o -type f -name '*.go' -print))`
  `goimports -w $(find -name '*.go' | grep -v vendor)`
2019-02-07 08:17:41 -08:00
Victor Agababov 267197692a Use the k8s sets for the code that is actually set of strings (#261) 2019-02-04 14:35:41 -08:00
Evan Anderson a118428db1 Add support for v0.2 CloudEvents "context attributes". (#248)
* CloudEvents v0.2 support, step 1: interfaces and versioned types.

Signed-off-by: Evan Anderson <evan.k.anderson@gmail.com>

* Add support for v0.2 event types. (Breaking change in return types!)

Signed-off-by: Evan Anderson <evan.k.anderson@gmail.com>

* Move DataContentType() to be common across Senders and Receivers.

Signed-off-by: Evan Anderson <evan.k.anderson@gmail.com>

* Add comment on why test code is commented out.

Signed-off-by: Evan Anderson <evan.k.anderson@gmail.com>

* Address @vagababov review.

* Add another test case and better cover extensions in handler tests.
2019-02-01 22:23:38 -08:00
Victor Agababov da039ff041 Some fixes to the event_v01.go file. (#254)
* Some fixes to the event_v01.go file.

Mostly change to the encodeKey to not use pointer to the map.
Some minor readability improvements.

* Fix the comment wording.
2019-01-30 10:40:37 -08:00
Scott Nichols cc3cc546fe CloudeEvents: Fix a typo in unit test and code. (#252) 2019-01-29 10:25:37 -08:00
Scott Nichols b531944062 integrating exposed some minor issues. fixed. (#251) 2019-01-29 10:00:37 -08:00
Scott Nichols 61acd8a35b Add CloudEvents Client to sdk (#241)
* Add docs to help bootstrap cloud event sdk usage.

* add go markdown label.

* prettier markdown.

* well golang wants tabs but markdown does not i guess so... fight!

* adding me as an owner of this code.

* adding ville to the hook.

* Pushing new client and builder.

* good example of how to use the encoding settings int he builder.

* make it more clear,.

* prep for merge.

* adding tests.

* adding extenion tests.

* adding test for empty original extensions.

* Adding valid builder tests.

* adding client tests.

* Removing encoding from enum names.

* ran prettier.

* fix spacing.

* Update cloudevents/README.md

Co-Authored-By: n3wscott <32305648+n3wscott@users.noreply.github.com>

* Update based on feedback.

* adding builder to new client.

* update producer paragraph.

* trail space.

* trail space.
2019-01-28 20:09:15 -08:00
Evan Anderson e4ede720f3 CloudEvents v0.2 support, step 1: interfaces and versioned types. (#244)
Signed-off-by: Evan Anderson <evan.k.anderson@gmail.com>
2019-01-28 07:13:36 -08:00
Victor Agababov a330baa9b0 Grep fix formatting issues (#233)
* Some fixes to the spoof.go and exporter.go

While reviewing some other CL, I saw some avenues for improving
spoof.go, to log the URL that's being fetched, which would help in test
debugging and to use switch construct, rather than nested if's.

While testing the change, I noticed some shifty loggin from the
exporter, so I fixed that as well while I was there.

* Continuation of the previous cleanups.

* Fix the issues with formatting by executing a grep

* and fix compilation error

* lowercase error

* fix the newly changed unit test
2019-01-18 14:33:32 -08:00
Evan Anderson f3e33e3b92 Add support for returning a cloudevents.EventContext from a function. (#205)
Signed-off-by: Evan Anderson <evan.k.anderson@gmail.com>
2018-12-19 14:32:35 -08:00
Galo Navarro 6ac3c8ef24 encoding: expose HeaderExtensionPrefix (#172)
So that the header prefix can be used in downstream dependencies.

Signed-off-by: Galo Navarro <anglorvaroa@gmail.com>
2018-11-26 07:25:23 -08:00
Matthias Wessendorf 18ee4c298a Removing eventTime for required attrs. (#164) 2018-11-12 11:37:45 -08:00
Scott Nichols 04b40fd38a Adding cloudevent sdk for working with cloud event producers and consumers. (#154) 2018-11-02 10:43:35 -07:00