Commit Graph

4 Commits

Author SHA1 Message Date
Bernd Verst e87cd5e4cb
Go 1.19 support and linter fixes (#1975)
* Go 1.19 support and linter fixes

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* Update workflows for Go1.19 and new linter version

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* Remove unnecessary space in nolint directive

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* disable additional linters which aren't used because of Go generics

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* enable gosec linter again

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* Update bindings/zeebe/command/publish_message_test.go

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* Update bindings/output_binding.go

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* Use prepared statement for mysql table creation

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* Ping is not ping

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* c'mon linter

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* Fix MySQL gosec issue

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

* revert mysql to be fixed later

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>

Signed-off-by: Bernd Verst <4535280+berndverst@users.noreply.github.com>
2022-08-18 00:45:23 -07:00
Dmitry Shmulevich c7adb917f3
update license to Apache v2.0 (#1406) 2022-01-04 19:53:31 -08:00
Yaron Schneider 3ef025c604
change headers (#679) 2021-02-09 18:57:55 -08:00
Michael Collins b08e920cdd
Apns output binding (#481)
* Create Apple Push Notification Output Binding

I created the apns package and created apns.go to implement the output
binding to send push notifications to Apple devices using the Apple Push
Notification Service.

* Refactor Code

I refactored and cleaned up the source code in apns.go. I made the code
easier to read and understand. I split out the JWT generation into
authorization_builder.go. I split out the create operation code into
create_operation.go and refactored it to follow a pipeline pattern.

I created doc.go and added documentation for how to use the APNS binding
to send push notifications to Apple devices.

* Fix Lint Issuer

I corrected issues reported by golangci-lint in the pull request. I ran
gofumpt against the test cases for the APNs binding. I fixed a naming
error in create_operation.go.

* Address Review Comment

I revised extractKeyID in apns.go to address a readability concern in
the code. I simplified the if/else block to make the logic easier to
understand.

* Add License Header to APNs Binding

I added the standard Microsoft copyright and MIT license header to the
source files for the APNs binding. This was requested from the PR
review.

* Revise APNS.extractTeamID for Readability

Per a PR comment, I revised the APNS.extractTeamID function to make the
function more readable.

* Revise APNS Create Operation

I revised the APNS create operation based on discussions in the PR
(#481). I deleted create_operation.go and merged the code back into the
main APNS type to simplify the code.

* Fix Linter Errors

I fixed linter errors reported in apns.go.

* Fix Code Review Comments

I switched from using encoding/json for JSON encoding and decoding to
using jsoniter.

I updated authorization_builder.go to define the expiration period as a
constant and provided a comment describing the need for and use of the
expiration period.

Co-authored-by: Yaron Schneider <yaronsc@microsoft.com>
Co-authored-by: Mark Chmarny <mchmarny@users.noreply.github.com>
Co-authored-by: Young Bu Park <youngp@microsoft.com>
2020-10-09 10:26:44 -07:00