diff --git a/.github/workflows/clddx-agent-merge-hook.yml b/.github/workflows/clddx-agent-merge-hook.yml new file mode 100644 index 0000000..8087945 --- /dev/null +++ b/.github/workflows/clddx-agent-merge-hook.yml @@ -0,0 +1,35 @@ +name: clddx-agent merge hook + +on: + pull_request: + types: [closed] + +permissions: {} + +jobs: + notify: + if: github.event.pull_request.merged == true && + startsWith(github.event.pull_request.head.ref, 'releasecandidate/') && + contains(toJson(github.event.pull_request.labels.*.name), '"agent:') + runs-on: ubuntu-latest + steps: + - env: + GH_TOKEN: ${{ secrets.CLDDX_AGENT_PAT }} + REPO: ${{ github.repository }} + PR_NUMBER: ${{ github.event.pull_request.number }} + MERGE_SHA: ${{ github.event.pull_request.merge_commit_sha }} + LABELS: ${{ toJson(github.event.pull_request.labels) }} + run: | + # Send the body as raw JSON (`--input -`), NOT `-f client_payload[...]`. + # `-f` sends every field as a string, which would make `labels` a JSON + # *string* rather than an array — the runner's label routing reads + # `.labels[].name`, so a string makes every release task silently miss. + jq -n \ + --arg repo "$REPO" \ + --arg pr_number "$PR_NUMBER" \ + --arg merge_sha "$MERGE_SHA" \ + --argjson labels "$LABELS" \ + '{event_type:"pull-request-merged", + client_payload:{repo:$repo, pr_number:$pr_number, + merge_sha:$merge_sha, labels:$labels}}' \ + | gh api repos/temporalio/clddx-agent/dispatches --input - diff --git a/.github/workflows/dispatch-clddx-agent-rc.yml b/.github/workflows/dispatch-clddx-agent-rc.yml new file mode 100644 index 0000000..e39a0bc --- /dev/null +++ b/.github/workflows/dispatch-clddx-agent-rc.yml @@ -0,0 +1,24 @@ +name: Dispatch clddx-agent on RC branch + +on: + push: + branches: ['releasecandidate/**'] + +permissions: {} + +jobs: + dispatch: + runs-on: ubuntu-latest + steps: + - name: Dispatch clddx-agent + env: + GH_TOKEN: ${{ secrets.CLDDX_AGENT_PAT }} + RC_BRANCH: ${{ github.ref_name }} + SDK_SHA: ${{ github.sha }} + run: | + new_sdk="${RC_BRANCH#releasecandidate/}" # releasecandidate/v0.1.1 -> v0.1.1 + gh api repos/temporalio/clddx-agent/dispatches \ + -f event_type=cloud-sdk-go-rc \ + -f client_payload[new_sdk]="$new_sdk" \ + -f client_payload[rc_branch]="$RC_BRANCH" \ + -f client_payload[sdk_sha]="$SDK_SHA" diff --git a/api/region/v1/message.pb.go b/api/region/v1/message.pb.go index acf2de7..2c7a8b1 100644 --- a/api/region/v1/message.pb.go +++ b/api/region/v1/message.pb.go @@ -28,6 +28,7 @@ const ( Region_CLOUD_PROVIDER_UNSPECIFIED Region_CloudProvider = 0 Region_CLOUD_PROVIDER_AWS Region_CloudProvider = 1 Region_CLOUD_PROVIDER_GCP Region_CloudProvider = 2 + Region_CLOUD_PROVIDER_AZURE Region_CloudProvider = 3 ) // Enum value maps for Region_CloudProvider. @@ -36,11 +37,13 @@ var ( 0: "CLOUD_PROVIDER_UNSPECIFIED", 1: "CLOUD_PROVIDER_AWS", 2: "CLOUD_PROVIDER_GCP", + 3: "CLOUD_PROVIDER_AZURE", } Region_CloudProvider_value = map[string]int32{ "CLOUD_PROVIDER_UNSPECIFIED": 0, "CLOUD_PROVIDER_AWS": 1, "CLOUD_PROVIDER_GCP": 2, + "CLOUD_PROVIDER_AZURE": 3, } ) @@ -167,7 +170,7 @@ var file_temporal_api_cloud_region_v1_message_proto_rawDesc = string([]byte{ 0x6c, 0x6f, 0x75, 0x64, 0x2f, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x2f, 0x76, 0x31, 0x2f, 0x6d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x2e, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x12, 0x1c, 0x74, 0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x6c, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, - 0x2e, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x22, 0xe4, 0x02, 0x0a, 0x06, 0x52, + 0x2e, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x22, 0xfe, 0x02, 0x0a, 0x06, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x12, 0x0e, 0x0a, 0x02, 0x69, 0x64, 0x18, 0x01, 0x20, 0x01, 0x28, 0x09, 0x52, 0x02, 0x69, 0x64, 0x12, 0x3e, 0x0a, 0x19, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x5f, 0x70, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x5f, 0x64, 0x65, 0x70, 0x72, 0x65, 0x63, 0x61, 0x74, @@ -184,23 +187,25 @@ var file_temporal_api_cloud_region_v1_message_proto_rawDesc = string([]byte{ 0x13, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x12, 0x1a, 0x0a, 0x08, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, 0x18, 0x04, 0x20, 0x01, 0x28, 0x09, 0x52, 0x08, 0x6c, 0x6f, 0x63, 0x61, 0x74, 0x69, 0x6f, 0x6e, - 0x22, 0x5f, 0x0a, 0x0d, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, + 0x22, 0x79, 0x0a, 0x0d, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x50, 0x72, 0x6f, 0x76, 0x69, 0x64, 0x65, 0x72, 0x12, 0x1e, 0x0a, 0x1a, 0x43, 0x4c, 0x4f, 0x55, 0x44, 0x5f, 0x50, 0x52, 0x4f, 0x56, 0x49, 0x44, 0x45, 0x52, 0x5f, 0x55, 0x4e, 0x53, 0x50, 0x45, 0x43, 0x49, 0x46, 0x49, 0x45, 0x44, 0x10, 0x00, 0x12, 0x16, 0x0a, 0x12, 0x43, 0x4c, 0x4f, 0x55, 0x44, 0x5f, 0x50, 0x52, 0x4f, 0x56, 0x49, 0x44, 0x45, 0x52, 0x5f, 0x41, 0x57, 0x53, 0x10, 0x01, 0x12, 0x16, 0x0a, 0x12, 0x43, 0x4c, 0x4f, 0x55, 0x44, 0x5f, 0x50, 0x52, 0x4f, 0x56, 0x49, 0x44, 0x45, 0x52, 0x5f, 0x47, 0x43, 0x50, 0x10, - 0x02, 0x42, 0xa2, 0x01, 0x0a, 0x1f, 0x69, 0x6f, 0x2e, 0x74, 0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, - 0x6c, 0x2e, 0x61, 0x70, 0x69, 0x2e, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x2e, 0x72, 0x65, 0x67, 0x69, - 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x42, 0x0c, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x50, 0x72, - 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, 0x29, 0x67, 0x6f, 0x2e, 0x74, 0x65, 0x6d, 0x70, 0x6f, 0x72, - 0x61, 0x6c, 0x2e, 0x69, 0x6f, 0x2f, 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x2f, - 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x2f, 0x76, 0x31, 0x3b, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, - 0xaa, 0x02, 0x1e, 0x54, 0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x6c, 0x69, 0x6f, 0x2e, 0x41, 0x70, - 0x69, 0x2e, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x2e, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x2e, 0x56, - 0x31, 0xea, 0x02, 0x22, 0x54, 0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x6c, 0x69, 0x6f, 0x3a, 0x3a, - 0x41, 0x70, 0x69, 0x3a, 0x3a, 0x43, 0x6c, 0x6f, 0x75, 0x64, 0x3a, 0x3a, 0x52, 0x65, 0x67, 0x69, - 0x6f, 0x6e, 0x3a, 0x3a, 0x56, 0x31, 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, + 0x02, 0x12, 0x18, 0x0a, 0x14, 0x43, 0x4c, 0x4f, 0x55, 0x44, 0x5f, 0x50, 0x52, 0x4f, 0x56, 0x49, + 0x44, 0x45, 0x52, 0x5f, 0x41, 0x5a, 0x55, 0x52, 0x45, 0x10, 0x03, 0x42, 0xa2, 0x01, 0x0a, 0x1f, + 0x69, 0x6f, 0x2e, 0x74, 0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x6c, 0x2e, 0x61, 0x70, 0x69, 0x2e, + 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x2e, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x2e, 0x76, 0x31, 0x42, + 0x0c, 0x4d, 0x65, 0x73, 0x73, 0x61, 0x67, 0x65, 0x50, 0x72, 0x6f, 0x74, 0x6f, 0x50, 0x01, 0x5a, + 0x29, 0x67, 0x6f, 0x2e, 0x74, 0x65, 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x6c, 0x2e, 0x69, 0x6f, 0x2f, + 0x61, 0x70, 0x69, 0x2f, 0x63, 0x6c, 0x6f, 0x75, 0x64, 0x2f, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, + 0x2f, 0x76, 0x31, 0x3b, 0x72, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0xaa, 0x02, 0x1e, 0x54, 0x65, 0x6d, + 0x70, 0x6f, 0x72, 0x61, 0x6c, 0x69, 0x6f, 0x2e, 0x41, 0x70, 0x69, 0x2e, 0x43, 0x6c, 0x6f, 0x75, + 0x64, 0x2e, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x2e, 0x56, 0x31, 0xea, 0x02, 0x22, 0x54, 0x65, + 0x6d, 0x70, 0x6f, 0x72, 0x61, 0x6c, 0x69, 0x6f, 0x3a, 0x3a, 0x41, 0x70, 0x69, 0x3a, 0x3a, 0x43, + 0x6c, 0x6f, 0x75, 0x64, 0x3a, 0x3a, 0x52, 0x65, 0x67, 0x69, 0x6f, 0x6e, 0x3a, 0x3a, 0x56, 0x31, + 0x62, 0x06, 0x70, 0x72, 0x6f, 0x74, 0x6f, 0x33, }) var ( diff --git a/cloudclient/options.go b/cloudclient/options.go index 4937ca7..5249e73 100644 --- a/cloudclient/options.go +++ b/cloudclient/options.go @@ -22,8 +22,8 @@ const ( authorizationBearer = "Bearer" temporalCloudAPIVersionHeader = "temporal-cloud-api-version" - sdkVersion = "0.14.0" - defaultAPIVersion = "v0.17.0" + sdkVersion = "0.14.1" + defaultAPIVersion = "v0.17.1" ) func DefaultAPIVersion() string { diff --git a/proto/cloud-api b/proto/cloud-api index 445e909..ca7683f 160000 --- a/proto/cloud-api +++ b/proto/cloud-api @@ -1 +1 @@ -Subproject commit 445e9090b8a79f1b49713ab31eaeab2629b05dc7 +Subproject commit ca7683f23093f696eca53137644a28a67eb12e22