Skip to content

Add System Nexus transfer payload converter #2015

Add System Nexus transfer payload converter

Add System Nexus transfer payload converter #2015

Workflow file for this run

name: Continuous Integration
on:
pull_request:
push:
branches:
- main
- "releases/*"
permissions:
actions: read
contents: read
jobs:
build-lint-test:
env:
RestoreLockedMode: true
TEMPORAL_CLIENT_CLOUD_API_VERSION: v0.19.1
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, ubuntu-arm, macos-arm, windows-latest, windows-arm]
include:
- os: windows-latest
checkTarget: true
- os: ubuntu-latest
docsTarget: true
cloudTestTarget: true
- os: ubuntu-arm
runsOn: ubuntu-24.04-arm64-2-core
- os: macos-arm
runsOn: macos-14
- os: windows-arm
runsOn: windows-11-arm
runs-on: ${{ matrix.runsOn || matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
submodules: recursive
- name: Setup
uses: ./.github/actions/setup
- name: Regen confirm unchanged
if: ${{ matrix.checkTarget }}
shell: bash
run: |
mise run gen
git add .
git config --global core.safecrlf false
git diff --cached > generator.diff
git diff --cached --exit-code
- name: Upload generator diff
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
if: always()
with:
name: generator-diff
path: generator.diff
if-no-files-found: ignore
overwrite: true
- name: Check format
if: ${{ matrix.checkTarget }}
run: dotnet format --verify-no-changes
- name: Build
run: dotnet build
- name: Test
run: |
dotnet test --logger "console;verbosity=detailed" --logger "trx;LogFilePrefix=test-results" --results-directory tests/Temporalio.Tests/TestResults --blame-crash -v n --blame-hang-timeout 10m
- name: Validate package API surface
# Package API validation runs only during the Pack target and is
# platform-independent so running on one OS is sufficient.
if: ${{ matrix.os == 'ubuntu-latest' }}
run: dotnet pack -c Debug --no-restore
- name: Upload test results
if: ${{ !cancelled() }}
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
with:
name: test-results-${{ matrix.os }}
path: tests/Temporalio.Tests/TestResults/**/*.trx
if-no-files-found: warn
overwrite: true
- name: Confirm bench works
run: dotnet run --project tests/Temporalio.SimpleBench/Temporalio.SimpleBench.csproj -- --workflow-count 5 --max-cached-workflows 100 --max-concurrent 100
- name: Check Cloud test eligibility
id: cloud-test-eligibility
# Secrets are unavailable to Dependabot and pull requests from forks.
if: ${{ matrix.cloudTestTarget && github.actor != 'dependabot[bot]' && (github.event.pull_request.head.repo.full_name == '' || github.event.pull_request.head.repo.full_name == 'temporalio/sdk-dotnet') }}
shell: bash
run: echo "enabled=true" >> "$GITHUB_OUTPUT"
- name: Generate Cloud test certificates
if: ${{ steps.cloud-test-eligibility.outputs.enabled == 'true' }}
shell: bash
run: |
cert_dir="$RUNNER_TEMP/cloud-test-certs"
mkdir "$cert_dir"
openssl req -x509 -newkey rsa:2048 -nodes -days 1 \
-keyout "$cert_dir/ca.key" -out "$cert_dir/ca.pem" \
-subj '/CN=Temporal .NET SDK Cloud CI CA'
openssl req -newkey rsa:2048 -nodes \
-keyout "$cert_dir/client.key" -out "$cert_dir/client.csr" \
-subj '/CN=Temporal .NET SDK Cloud CI'
openssl x509 -req -days 1 -in "$cert_dir/client.csr" \
-CA "$cert_dir/ca.pem" -CAkey "$cert_dir/ca.key" -CAcreateserial \
-out "$cert_dir/client.pem" -extfile <(printf 'extendedKeyUsage=clientAuth')
{
echo "TEMPORAL_CLOUD_CLIENT_CA_PATH=$cert_dir/ca.pem"
echo "TEMPORAL_TLS_CLIENT_CERT_PATH=$cert_dir/client.pem"
echo "TEMPORAL_TLS_CLIENT_KEY_PATH=$cert_dir/client.key"
} >> "$GITHUB_ENV"
- name: Create Cloud namespace
id: create-cloud-namespace
if: ${{ steps.cloud-test-eligibility.outputs.enabled == 'true' }}
env:
TEMPORAL_CLIENT_CLOUD_API_KEY: ${{ secrets.TEMPORAL_CLIENT_CLOUD_API_KEY }}
run: dotnet run --project tests/Temporalio.Tests -- cloud-namespace create
- name: Test cloud (mTLS)
if: ${{ steps.cloud-test-eligibility.outputs.enabled == 'true' }}
env:
TEMPORAL_TEST_ENV_CONFIG_SERVER: true
TEMPORAL_ADDRESS: ${{ steps.create-cloud-namespace.outputs.namespace }}.tmprl.cloud:7233
TEMPORAL_NAMESPACE: ${{ steps.create-cloud-namespace.outputs.namespace }}
run: dotnet run --project tests/Temporalio.Tests -- -verbose -method "*.ExecuteWorkflowAsync_Simple_Succeeds"
- name: Delete Cloud namespace
id: delete-cloud-namespace
if: ${{ always() && steps.cloud-test-eligibility.outputs.enabled == 'true' && steps.create-cloud-namespace.outputs.namespace != '' }}
continue-on-error: true
env:
TEMPORAL_CLIENT_CLOUD_API_KEY: ${{ secrets.TEMPORAL_CLIENT_CLOUD_API_KEY }}
run: dotnet run --project tests/Temporalio.Tests -- cloud-namespace delete "${{ steps.create-cloud-namespace.outputs.namespace }}"
- name: Report Cloud namespace cleanup failure
if: ${{ always() && steps.delete-cloud-namespace.outcome == 'failure' }}
shell: bash
run: echo "::warning title=Cloud namespace cleanup failed::Failed to delete Cloud namespace ${{ steps.create-cloud-namespace.outputs.namespace }}"
- name: Test cloud (API key)
# Uses API key auth to test auto-TLS feature (TLS auto-enabled when API key provided).
if: ${{ steps.cloud-test-eligibility.outputs.enabled == 'true' }}
env:
TEMPORAL_TEST_CLIENT_TARGET_HOST: ca-central-1.aws.api.temporal.io:7233
TEMPORAL_TEST_CLIENT_NAMESPACE: ${{ vars.TEMPORAL_CLIENT_NAMESPACE }}
TEMPORAL_CLIENT_CLOUD_API_KEY: ${{ secrets.TEMPORAL_CLIENT_CLOUD_API_KEY }}
run: dotnet run --project tests/Temporalio.Tests -- -verbose -method "*.ExecuteWorkflowAsync_Simple_Succeeds"
- name: Test cloud operations client
if: ${{ steps.cloud-test-eligibility.outputs.enabled == 'true' }}
env:
TEMPORAL_CLIENT_CLOUD_NAMESPACE: sdk-ci.a2dd6
TEMPORAL_CLIENT_CLOUD_API_KEY: ${{ secrets.TEMPORAL_CLIENT_CLOUD_API_KEY }}
run: dotnet run --project tests/Temporalio.Tests -- -verbose -method "*.TemporalCloudOperationsClientTests.*"
- name: Upload native symbols
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
if: ${{ failure() }}
with:
name: symbols-native-${{ matrix.os }}
if-no-files-found: error
overwrite: true
path: |
src/Temporalio/Bridge/sdk-core/target/debug/*.dll
src/Temporalio/Bridge/sdk-core/target/debug/*.dylib
src/Temporalio/Bridge/sdk-core/target/debug/*.pdb
src/Temporalio/Bridge/sdk-core/target/debug/*.so
- name: Upload managed symbols
uses: actions/upload-artifact@043fb46d1a93c77aae656e7c1c64a875d1fc6a0a # v7
if: ${{ failure() }}
with:
name: symbols-managed-${{ matrix.os }}
if-no-files-found: error
overwrite: true
path: |
src/**/bin/Debug/**/*.dll
src/**/bin/Debug/**/*.pdb
- name: Build docs
if: ${{ matrix.docsTarget }}
run: mise run docs
- name: Deploy docs
# Only deploy on main merge, not in PRs
if: ${{ github.ref == 'refs/heads/main' && matrix.docsTarget }}
env:
VERCEL_PROJECT_ID: ${{ secrets.VERCEL_PROJECT_ID }}
VERCEL_ORG_ID: ${{ secrets.VERCEL_ORG_ID }}
run: npx vercel deploy src/Temporalio.ApiDoc/_site --token ${{ secrets.VERCEL_TOKEN }} --prod --yes
# Runs the sdk features repo tests with this repo's current SDK code
features-tests:
uses: temporalio/features/.github/workflows/dotnet.yaml@main
with:
dotnet-repo-path: ${{github.event.pull_request.head.repo.full_name}}
version: ${{github.event.pull_request.head.ref}}
version-is-repo-ref: true
features-repo-ref: standalone-activities-dotnet