Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion .github/workflows/learningcourse-integration-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -76,12 +76,18 @@ jobs:
echo "🔨 Building LocalTesting solution (includes all LearningCourse projects)..."
dotnet restore LocalTesting/LocalTesting.sln
dotnet build LocalTesting/LocalTesting.sln --configuration Release --no-restore

- name: Build LearningCourse IntegrationTests solution
run: |
echo "🔨 Building LearningCourse IntegrationTests solution..."
dotnet restore LearningCourse/IntegrationTests.sln
dotnet build LearningCourse/IntegrationTests.sln --configuration Release --no-restore

- name: Run LearningCourse Integration Tests
timeout-minutes: 25 # Increased timeout for CI environment with LEARNINGCOURSE mode
run: |
echo "=== Starting LearningCourse Integration Tests ==="
dotnet test LearningCourse/IntegrationTests.sln --configuration Release --verbosity normal --logger "trx;LogFileName=LearningCourseTestResults.trx" --results-directory TestResults
dotnet test LearningCourse/IntegrationTests.sln --configuration Release --no-build --verbosity normal --logger "trx;LogFileName=LearningCourseTestResults.trx" --results-directory TestResults
env:
DOTNET_ENVIRONMENT: Testing
ASPIRE_ALLOW_UNSECURED_TRANSPORT: "true"
Expand Down
60 changes: 58 additions & 2 deletions .github/workflows/release-major.yml
Original file line number Diff line number Diff line change
Expand Up @@ -265,11 +265,39 @@ jobs:
docker tag ${{ env.DOCKER_IMAGE_NAME }}:$VERSION ${{ env.DOCKER_IMAGE_NAME }}:latest
echo "Loaded Docker image for version $VERSION and tagged as latest"

- name: Configure system for optimal performance
run: |
echo "=== Configuring system for optimal performance ==="
sudo sysctl -w vm.max_map_count=262144
sudo bash -c 'echo "* soft nofile 65536" >> /etc/security/limits.conf'
sudo bash -c 'echo "* hard nofile 65536" >> /etc/security/limits.conf'
echo "Current vm.max_map_count: $(sysctl vm.max_map_count)"
echo "Available memory: $(free -h)"
echo "CPU info: $(nproc) cores"

- name: Verify Docker environment
run: |
echo "=== Verifying Docker environment ==="
docker --version
docker info
docker ps -a

- name: Build ReleasePackagesTesting solution
run: |
echo "🔨 Building ReleasePackagesTesting solution..."
dotnet restore ReleasePackagesTesting/ReleasePackagesTesting.sln
dotnet build ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-restore

- name: Run Pre-Release Validation Tests
timeout-minutes: 12
env:
DOTNET_ENVIRONMENT: Testing
ASPIRE_ALLOW_UNSECURED_TRANSPORT: "true"
DOCKER_HOST: "unix:///var/run/docker.sock"
RELEASE_VALIDATION_MODE: "PreRelease"
run: |
echo "=== Running Pre-Release Validation Tests ==="
dotnet test ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults
dotnet test ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-build --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults

- name: Upload test results
uses: actions/upload-artifact@v4
Expand Down Expand Up @@ -471,11 +499,39 @@ jobs:
docker tag ${{ env.DOCKER_IMAGE_NAME }}:$VERSION ${{ env.DOCKER_IMAGE_NAME }}:latest
echo "✅ Docker image pulled from Docker Hub"

- name: Configure system for optimal performance
run: |
echo "=== Configuring system for optimal performance ==="
sudo sysctl -w vm.max_map_count=262144
sudo bash -c 'echo "* soft nofile 65536" >> /etc/security/limits.conf'
sudo bash -c 'echo "* hard nofile 65536" >> /etc/security/limits.conf'
echo "Current vm.max_map_count: $(sysctl vm.max_map_count)"
echo "Available memory: $(free -h)"
echo "CPU info: $(nproc) cores"

- name: Verify Docker environment
run: |
echo "=== Verifying Docker environment ==="
docker --version
docker info
docker ps -a

- name: Build ReleasePackagesTesting solution
run: |
echo "🔨 Building ReleasePackagesTesting solution..."
dotnet restore ReleasePackagesTesting/ReleasePackagesTesting.sln
dotnet build ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-restore

- name: Run Post-Release Validation Tests
timeout-minutes: 12
env:
DOTNET_ENVIRONMENT: Testing
ASPIRE_ALLOW_UNSECURED_TRANSPORT: "true"
DOCKER_HOST: "unix:///var/run/docker.sock"
RELEASE_VALIDATION_MODE: "PostRelease"
run: |
echo "=== Running Post-Release Validation Tests ==="
dotnet test ReleasePackagesTesting.Published/ReleasePackagesTesting.Published.sln --configuration Release --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults
dotnet test ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-build --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults

- name: Upload test results
uses: actions/upload-artifact@v4
Expand Down
60 changes: 58 additions & 2 deletions .github/workflows/release-minor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -265,11 +265,39 @@ jobs:
docker tag ${{ env.DOCKER_IMAGE_NAME }}:$VERSION ${{ env.DOCKER_IMAGE_NAME }}:latest
echo "Loaded Docker image for version $VERSION and tagged as latest"

- name: Configure system for optimal performance
run: |
echo "=== Configuring system for optimal performance ==="
sudo sysctl -w vm.max_map_count=262144
sudo bash -c 'echo "* soft nofile 65536" >> /etc/security/limits.conf'
sudo bash -c 'echo "* hard nofile 65536" >> /etc/security/limits.conf'
echo "Current vm.max_map_count: $(sysctl vm.max_map_count)"
echo "Available memory: $(free -h)"
echo "CPU info: $(nproc) cores"

- name: Verify Docker environment
run: |
echo "=== Verifying Docker environment ==="
docker --version
docker info
docker ps -a

- name: Build ReleasePackagesTesting solution
run: |
echo "🔨 Building ReleasePackagesTesting solution..."
dotnet restore ReleasePackagesTesting/ReleasePackagesTesting.sln
dotnet build ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-restore

- name: Run Pre-Release Validation Tests
timeout-minutes: 12
env:
DOTNET_ENVIRONMENT: Testing
ASPIRE_ALLOW_UNSECURED_TRANSPORT: "true"
DOCKER_HOST: "unix:///var/run/docker.sock"
RELEASE_VALIDATION_MODE: "PreRelease"
run: |
echo "=== Running Pre-Release Validation Tests ==="
dotnet test ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults
dotnet test ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-build --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults

- name: Upload test results
uses: actions/upload-artifact@v4
Expand Down Expand Up @@ -471,11 +499,39 @@ jobs:
docker tag ${{ env.DOCKER_IMAGE_NAME }}:$VERSION ${{ env.DOCKER_IMAGE_NAME }}:latest
echo "✅ Docker image pulled from Docker Hub"

- name: Configure system for optimal performance
run: |
echo "=== Configuring system for optimal performance ==="
sudo sysctl -w vm.max_map_count=262144
sudo bash -c 'echo "* soft nofile 65536" >> /etc/security/limits.conf'
sudo bash -c 'echo "* hard nofile 65536" >> /etc/security/limits.conf'
echo "Current vm.max_map_count: $(sysctl vm.max_map_count)"
echo "Available memory: $(free -h)"
echo "CPU info: $(nproc) cores"

- name: Verify Docker environment
run: |
echo "=== Verifying Docker environment ==="
docker --version
docker info
docker ps -a

- name: Build ReleasePackagesTesting solution
run: |
echo "🔨 Building ReleasePackagesTesting solution..."
dotnet restore ReleasePackagesTesting/ReleasePackagesTesting.sln
dotnet build ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-restore

- name: Run Post-Release Validation Tests
timeout-minutes: 12
env:
DOTNET_ENVIRONMENT: Testing
ASPIRE_ALLOW_UNSECURED_TRANSPORT: "true"
DOCKER_HOST: "unix:///var/run/docker.sock"
RELEASE_VALIDATION_MODE: "PostRelease"
run: |
echo "=== Running Post-Release Validation Tests ==="
dotnet test ReleasePackagesTesting.Published/ReleasePackagesTesting.Published.sln --configuration Release --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults
dotnet test ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-build --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults

- name: Upload test results
uses: actions/upload-artifact@v4
Expand Down
8 changes: 8 additions & 0 deletions .github/workflows/release-package-validation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -110,16 +110,24 @@ jobs:
dotnet nuget add source $(pwd)/packages --name LocalTestFeed
echo "Added local NuGet source"

- name: Build ReleasePackagesTesting solution
run: |
echo "🔨 Building ReleasePackagesTesting solution..."
dotnet restore ReleasePackagesTesting/ReleasePackagesTesting.sln
dotnet build ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-restore

- name: Run ReleasePackagesTesting validation
timeout-minutes: 20
env:
DOTNET_ENVIRONMENT: Testing
ASPIRE_ALLOW_UNSECURED_TRANSPORT: "true"
DOCKER_HOST: "unix:///var/run/docker.sock"
RELEASE_VALIDATION_MODE: "PreRelease"
run: |
echo "🧪 Running Release Package Validation Tests..."
dotnet test ReleasePackagesTesting/ReleasePackagesTesting.sln \
--configuration Release \
--no-build \
--verbosity normal \
--logger "trx;LogFileName=TestResults.trx" \
--results-directory TestResults
Expand Down
60 changes: 58 additions & 2 deletions .github/workflows/release-patch.yml
Original file line number Diff line number Diff line change
Expand Up @@ -265,11 +265,39 @@ jobs:
docker tag ${{ env.DOCKER_IMAGE_NAME }}:$VERSION ${{ env.DOCKER_IMAGE_NAME }}:latest
echo "Loaded Docker image for version $VERSION and tagged as latest"

- name: Configure system for optimal performance
run: |
echo "=== Configuring system for optimal performance ==="
sudo sysctl -w vm.max_map_count=262144
sudo bash -c 'echo "* soft nofile 65536" >> /etc/security/limits.conf'
sudo bash -c 'echo "* hard nofile 65536" >> /etc/security/limits.conf'
echo "Current vm.max_map_count: $(sysctl vm.max_map_count)"
echo "Available memory: $(free -h)"
echo "CPU info: $(nproc) cores"

- name: Verify Docker environment
run: |
echo "=== Verifying Docker environment ==="
docker --version
docker info
docker ps -a

- name: Build ReleasePackagesTesting solution
run: |
echo "🔨 Building ReleasePackagesTesting solution..."
dotnet restore ReleasePackagesTesting/ReleasePackagesTesting.sln
dotnet build ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-restore

- name: Run Pre-Release Validation Tests
timeout-minutes: 12
env:
DOTNET_ENVIRONMENT: Testing
ASPIRE_ALLOW_UNSECURED_TRANSPORT: "true"
DOCKER_HOST: "unix:///var/run/docker.sock"
RELEASE_VALIDATION_MODE: "PreRelease"
run: |
echo "=== Running Pre-Release Validation Tests ==="
dotnet test ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults
dotnet test ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-build --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults

- name: Upload test results
uses: actions/upload-artifact@v4
Expand Down Expand Up @@ -471,11 +499,39 @@ jobs:
docker tag ${{ env.DOCKER_IMAGE_NAME }}:$VERSION ${{ env.DOCKER_IMAGE_NAME }}:latest
echo "✅ Docker image pulled from Docker Hub"

- name: Configure system for optimal performance
run: |
echo "=== Configuring system for optimal performance ==="
sudo sysctl -w vm.max_map_count=262144
sudo bash -c 'echo "* soft nofile 65536" >> /etc/security/limits.conf'
sudo bash -c 'echo "* hard nofile 65536" >> /etc/security/limits.conf'
echo "Current vm.max_map_count: $(sysctl vm.max_map_count)"
echo "Available memory: $(free -h)"
echo "CPU info: $(nproc) cores"

- name: Verify Docker environment
run: |
echo "=== Verifying Docker environment ==="
docker --version
docker info
docker ps -a

- name: Build ReleasePackagesTesting solution
run: |
echo "🔨 Building ReleasePackagesTesting solution..."
dotnet restore ReleasePackagesTesting/ReleasePackagesTesting.sln
dotnet build ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-restore

- name: Run Post-Release Validation Tests
timeout-minutes: 12
env:
DOTNET_ENVIRONMENT: Testing
ASPIRE_ALLOW_UNSECURED_TRANSPORT: "true"
DOCKER_HOST: "unix:///var/run/docker.sock"
RELEASE_VALIDATION_MODE: "PostRelease"
run: |
echo "=== Running Post-Release Validation Tests ==="
dotnet test ReleasePackagesTesting.Published/ReleasePackagesTesting.Published.sln --configuration Release --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults
dotnet test ReleasePackagesTesting/ReleasePackagesTesting.sln --configuration Release --no-build --verbosity normal --logger "trx;LogFileName=TestResults.trx" --results-directory TestResults

- name: Upload test results
uses: actions/upload-artifact@v4
Expand Down
22 changes: 10 additions & 12 deletions RELEASE_TESTING.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,7 @@ This directory contains scripts for testing the release workflow locally before
- ✅ FlinkDotNet solution builds successfully
- ✅ NuGet packages are created correctly
- ✅ Docker image builds successfully
- ✅ Pre-release validation projects can restore and build with local packages
- ✅ Post-release validation projects can restore and build with local packages
- ✅ Release validation project can restore and build with local packages

**Execution time**: ~3 minutes

Expand Down Expand Up @@ -64,17 +63,18 @@ This directory contains scripts for testing the release workflow locally before

## What the Release Workflows Test

### Pre-Release Validation (ReleasePackagesTesting/)
Tests packages BEFORE publishing to ensure quality:
### Release Package Validation (ReleasePackagesTesting/)
Tests packages with configurable modes:

**Pre-Release Mode** (default - `RELEASE_VALIDATION_MODE=PreRelease`):
- Uses local NuGet packages from `./packages/`
- Uses local Docker image from `./docker/`
- Validates packages work with Flink and Kafka
- Prevents publishing broken releases

### Post-Release Validation (ReleasePackagesTesting.Published/)
Tests published packages AFTER release:
- Downloads packages from NuGet.org (or uses local as substitute)
- Pulls Docker images from Docker Hub (or uses local as substitute)
**Post-Release Mode** (`RELEASE_VALIDATION_MODE=PostRelease`):
- Downloads packages from NuGet.org
- Pulls Docker images from Docker Hub
- Validates published artifacts are compatible
- Confirms release actually works

Expand All @@ -95,8 +95,7 @@ dotnet add package Confluent.Kafka --version 2.11.1
**Solution**: Verify AppHost class name matches project name with underscores
```csharp
// Correct pattern:
Projects.ReleasePackagesTesting_FlinkSqlAppHost // for ReleasePackagesTesting.FlinkSqlAppHost
Projects.ReleasePackagesTesting_Published_FlinkSqlAppHost // for ReleasePackagesTesting.Published.FlinkSqlAppHost
Projects.ReleasePackagesTesting_FlinkSqlAppHost // for ReleasePackagesTesting.FlinkSqlAppHost
```

### Issue: Docker Out of Memory
Expand Down Expand Up @@ -171,8 +170,7 @@ docker system prune -a # Warning: removes all unused Docker images

## Related Documentation

- [ReleasePackagesTesting README](./ReleasePackagesTesting/README.md) - Pre-release validation details
- [ReleasePackagesTesting.Published README](./ReleasePackagesTesting.Published/README.md) - Post-release validation details
- [ReleasePackagesTesting README](./ReleasePackagesTesting/README.md) - Release validation details
- [Release Workflows](./.github/workflows/) - Actual CI/CD workflows

## Support
Expand Down
Loading
Loading