Skip to content

Commit

Permalink
GRPC Service Proxy and Encoding Interceptor (#738)
Browse files Browse the repository at this point in the history
* Add GRPC Service Proxy
* Add GRPC Client Interceptor for encoding
  • Loading branch information
robholland authored Mar 2, 2022
1 parent c3eb5b0 commit 2c5ed0f
Show file tree
Hide file tree
Showing 9 changed files with 2,104 additions and 1 deletion.
7 changes: 6 additions & 1 deletion Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ copyright $(BUILD)/copyright:
@mkdir -p $(BUILD)
@touch $(BUILD)/copyright

# Ensure generated code dependent on the API is not stale
generatorcheck:
(cd converter && go run ../internal/cmd/generateinterceptor/main.go -verifyOnly)
(cd client && go run ../internal/cmd/generateproxy/main.go -verifyOnly)

$(BUILD)/dummy:
go build -o $@ internal/cmd/dummy/dummy.go

Expand Down Expand Up @@ -92,7 +97,7 @@ fmt:
clean:
rm -rf $(BUILD)

check: vet errcheck staticcheck copyright bins
check: vet errcheck staticcheck copyright generatorcheck bins

##### Fossa #####
fossa-install:
Expand Down
1 change: 1 addition & 0 deletions client/client.go
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
// THE SOFTWARE.

//go:generate mockgen -copyright_file ../LICENSE -package client -source client.go -destination client_mock.go
//go:generate go run ../internal/cmd/generateproxy/main.go

// Package client is used by external programs to communicate with Temporal service.
// NOTE: DO NOT USE THIS API INSIDE OF ANY WORKFLOW CODE!!!
Expand Down
213 changes: 213 additions & 0 deletions client/service_proxy.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions converter/encoding_data_converter.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
// OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
// THE SOFTWARE.

//go:generate go run ../internal/cmd/generateinterceptor/main.go

package converter

import (
Expand Down
Loading

0 comments on commit 2c5ed0f

Please sign in to comment.