@@ -3,18 +3,18 @@ name: Validate Go SDK Release Candidate
33on :
44 workflow_dispatch :
55 inputs :
6- rc_tag :
7- description : ' Beam RC Tag (e.g., v2.59.0-RC1 )'
6+ RELEASE_VER :
7+ description : ' Beam Release Version (e.g., 2.69.0 )'
88 required : true
9- type : string
10- container_tag :
11- description : ' Beam Go SDK Container Tag (e.g., 2.59.0rc1 )'
9+ default : ' 2.69.0 '
10+ RC_NUM :
11+ description : ' Release Candidate number (e.g., 1 )'
1212 required : true
13- type : string
13+ default : ' 1 '
1414
1515# This allows a subsequently queued workflow run to interrupt previous runs
1616concurrency :
17- group : ' ${{ github.workflow }} @ ${{ github.event.inputs.rc_tag }} ' # Group by RC tag
17+ group : ' ${{ github.workflow }}'
1818 cancel-in-progress : true
1919
2020# Setting explicit permissions (copied from Java Mobile Gaming workflow)
4040 GCS_TEMP_LOCATION : gs://rc-validation-migration-tests/temp/
4141 GCS_STAGING_LOCATION : gs://rc-validation-migration-tests/staging/
4242 GCS_INPUT_PATH : gs://apache-beam-samples/shakespeare/kinglear.txt
43+ CONTAINER_TAG : " ${{github.event.inputs.RELEASE_VER}}rc${{github.event.inputs.RC_NUM}}"
44+ RC_TAG : " v${{github.event.inputs.RELEASE_VER}}-RC${{github.event.inputs.RC_NUM}}"
4345
4446jobs :
4547 validate-rc-package :
6163 wget -O $TEMP_DIR/wordcount.go https://raw.githubusercontent.com/apache/beam/refs/heads/master/sdks/go/examples/wordcount/wordcount.go
6264 cd $TEMP_DIR
6365 go mod init rc-test
64- go get github.com/apache/beam/sdks/v2/go/pkg/beam@${{ github.event.inputs.rc_tag }}
66+ go get github.com/apache/beam/sdks/v2/go/pkg/beam@${{ env.RC_TAG }}
6567 go mod tidy
6668 echo "work_dir=$TEMP_DIR" >> $GITHUB_OUTPUT # Output relative path
6769
9799 working-directory : ./${{ steps.setup_go.outputs.work_dir }}
98100 env :
99101 # Define output path based on constant prefix and RC tag for uniqueness
100- GCS_OUTPUT_PATH : ${{ env.GCS_OUTPUT_PREFIX }}/${{ github.event.inputs.rc_tag }}/dataflow/output
102+ GCS_OUTPUT_PATH : ${{ env.GCS_OUTPUT_PREFIX }}/${{ env.RC_TAG }}/dataflow/output
101103 run : |
102104 echo "Using output path: $GCS_OUTPUT_PATH"
103105 go run wordcount.go \
@@ -109,13 +111,13 @@ jobs:
109111 --temp_location=${{ env.GCS_TEMP_LOCATION }} \
110112 --staging_location=${{ env.GCS_STAGING_LOCATION }} \
111113 --environment_type=DOCKER \
112- --environment_config=apache/beam_go_sdk:${{ github.event.inputs.container_tag }}
114+ --environment_config=apache/beam_go_sdk:${{ env.CONTAINER_TAG }}
113115
114116 - name : Check Dataflow Output in GCS
115117 working-directory : ./${{ steps.setup_go.outputs.work_dir }} # Added working directory for consistency, though not strictly needed for gsutil
116118 env :
117119 # Re-define the output path pattern for checking
118- GCS_OUTPUT_PATH_PATTERN : ${{ env.GCS_OUTPUT_PREFIX }}/${{ github.event.inputs.rc_tag }}/dataflow/output*
120+ GCS_OUTPUT_PATH_PATTERN : ${{ env.GCS_OUTPUT_PREFIX }}/${{ env.RC_TAG }}/dataflow/output*
119121 run : |
120122 echo "Checking for Dataflow output files in GCS at: $GCS_OUTPUT_PATH_PATTERN"
121123 # Use gsutil stat. The -q flag suppresses errors for non-existent files,
0 commit comments