Add MessagePool documentation to advanced-topics #61
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Build and Test | |
| on: | |
| push: | |
| branches: [ main, develop ] | |
| pull_request: | |
| branches: [ main ] | |
| jobs: | |
| build: | |
| runs-on: ubuntu-22.04 | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '8.0.x' | |
| - name: Restore | |
| run: dotnet restore | |
| - name: Build | |
| run: dotnet build --configuration Release --no-restore | |
| - name: Upload build artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: build-output | |
| path: | | |
| src/*/bin/Release/ | |
| tests/*/bin/Release/ | |
| native/ | |
| test-windows: | |
| runs-on: windows-2022 | |
| needs: build | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '8.0.x' | |
| - name: Download build artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: build-output | |
| - name: Verify native library exists | |
| run: | | |
| dir native\runtimes\win-x64\native\ | |
| shell: cmd | |
| - name: Copy native library to test output | |
| run: | | |
| copy native\runtimes\win-x64\native\libzmq.dll tests\Net.Zmq.Tests\bin\Release\net8.0\ | |
| copy native\runtimes\win-x64\native\libzmq.dll tests\Net.Zmq.Core.Tests\bin\Release\net8.0\ | |
| shell: cmd | |
| - name: Verify build artifacts | |
| run: | | |
| echo "=== Net.Zmq.Tests output ===" | |
| dir tests\Net.Zmq.Tests\bin\Release\net8.0\libzmq.dll | |
| echo "=== Net.Zmq.Core.Tests output ===" | |
| dir tests\Net.Zmq.Core.Tests\bin\Release\net8.0\libzmq.dll | |
| shell: cmd | |
| - name: Test Unit | |
| run: dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName!~Integration" | |
| - name: Test Integration | |
| run: dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName~Integration" | |
| - name: Test Core | |
| run: dotnet test tests/Net.Zmq.Core.Tests/Net.Zmq.Core.Tests.csproj --configuration Release --no-build --verbosity normal | |
| test-windows-arm64: | |
| runs-on: windows-11-arm | |
| needs: build | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '8.0.x' | |
| - name: Download build artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: build-output | |
| - name: Verify native library exists | |
| run: | | |
| dir native\runtimes\win-arm64\native\ | |
| shell: cmd | |
| - name: Copy native library to test output | |
| run: | | |
| copy native\runtimes\win-arm64\native\libzmq.dll tests\Net.Zmq.Tests\bin\Release\net8.0\ | |
| copy native\runtimes\win-arm64\native\libzmq.dll tests\Net.Zmq.Core.Tests\bin\Release\net8.0\ | |
| shell: cmd | |
| - name: Verify build artifacts | |
| run: | | |
| echo "=== Net.Zmq.Tests output ===" | |
| dir tests\Net.Zmq.Tests\bin\Release\net8.0\libzmq.dll | |
| echo "=== Net.Zmq.Core.Tests output ===" | |
| dir tests\Net.Zmq.Core.Tests\bin\Release\net8.0\libzmq.dll | |
| shell: cmd | |
| - name: Test Unit | |
| run: dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName!~Integration" | |
| - name: Test Integration | |
| run: dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName~Integration" | |
| - name: Test Core | |
| run: dotnet test tests/Net.Zmq.Core.Tests/Net.Zmq.Core.Tests.csproj --configuration Release --no-build --verbosity normal | |
| test-linux: | |
| runs-on: ubuntu-22.04 | |
| needs: build | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '8.0.x' | |
| - name: Download build artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: build-output | |
| - name: Set native library permissions | |
| run: | | |
| chmod +x native/runtimes/linux-x64/native/libzmq.so | |
| ls -la native/runtimes/linux-x64/native/ | |
| echo "=== Library dependencies ===" | |
| ldd native/runtimes/linux-x64/native/libzmq.so || true | |
| - name: Copy native library to test output | |
| run: | | |
| cp native/runtimes/linux-x64/native/libzmq.so tests/Net.Zmq.Tests/bin/Release/net8.0/ | |
| cp native/runtimes/linux-x64/native/libzmq.so tests/Net.Zmq.Core.Tests/bin/Release/net8.0/ | |
| - name: Verify build artifacts | |
| run: | | |
| echo "=== Net.Zmq.Tests output ===" | |
| ls -la tests/Net.Zmq.Tests/bin/Release/net8.0/libzmq.so | |
| echo "=== Net.Zmq.Core.Tests output ===" | |
| ls -la tests/Net.Zmq.Core.Tests/bin/Release/net8.0/libzmq.so | |
| - name: Test Unit | |
| run: dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName!~Integration" | |
| - name: Test Integration | |
| run: dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName~Integration" | |
| - name: Test Core | |
| run: dotnet test tests/Net.Zmq.Core.Tests/Net.Zmq.Core.Tests.csproj --configuration Release --no-build --verbosity normal | |
| test-linux-arm64: | |
| runs-on: ubuntu-22.04-arm | |
| needs: build | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '8.0.x' | |
| - name: Download build artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: build-output | |
| - name: Set native library permissions | |
| run: | | |
| chmod +x native/runtimes/linux-arm64/native/libzmq.so | |
| ls -la native/runtimes/linux-arm64/native/ | |
| echo "=== Library dependencies ===" | |
| ldd native/runtimes/linux-arm64/native/libzmq.so || true | |
| - name: Copy native library to test output | |
| run: | | |
| cp native/runtimes/linux-arm64/native/libzmq.so tests/Net.Zmq.Tests/bin/Release/net8.0/ | |
| cp native/runtimes/linux-arm64/native/libzmq.so tests/Net.Zmq.Core.Tests/bin/Release/net8.0/ | |
| - name: Verify build artifacts | |
| run: | | |
| echo "=== Net.Zmq.Tests output ===" | |
| ls -la tests/Net.Zmq.Tests/bin/Release/net8.0/libzmq.so | |
| echo "=== Net.Zmq.Core.Tests output ===" | |
| ls -la tests/Net.Zmq.Core.Tests/bin/Release/net8.0/libzmq.so | |
| - name: Test Unit | |
| run: dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName!~Integration" | |
| - name: Test Integration | |
| run: dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName~Integration" | |
| - name: Test Core | |
| run: dotnet test tests/Net.Zmq.Core.Tests/Net.Zmq.Core.Tests.csproj --configuration Release --no-build --verbosity normal | |
| test-macos-arm64: | |
| runs-on: macos-15 | |
| needs: build | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '8.0.x' | |
| - name: Download build artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: build-output | |
| - name: Prepare native library | |
| run: | | |
| chmod +x native/runtimes/osx-arm64/native/libzmq.dylib | |
| xattr -d com.apple.quarantine native/runtimes/osx-arm64/native/libzmq.dylib 2>/dev/null || true | |
| ls -la native/runtimes/osx-arm64/native/ | |
| echo "=== Library dependencies ===" | |
| otool -L native/runtimes/osx-arm64/native/libzmq.dylib || true | |
| - name: Copy native library to test output | |
| run: | | |
| cp native/runtimes/osx-arm64/native/libzmq.dylib tests/Net.Zmq.Tests/bin/Release/net8.0/ | |
| cp native/runtimes/osx-arm64/native/libzmq.dylib tests/Net.Zmq.Core.Tests/bin/Release/net8.0/ | |
| - name: Verify build artifacts | |
| run: | | |
| echo "=== Net.Zmq.Tests output ===" | |
| ls -la tests/Net.Zmq.Tests/bin/Release/net8.0/libzmq.dylib | |
| echo "=== Net.Zmq.Core.Tests output ===" | |
| ls -la tests/Net.Zmq.Core.Tests/bin/Release/net8.0/libzmq.dylib | |
| - name: Test Unit | |
| run: dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName!~Integration" | |
| - name: Test Integration | |
| run: dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName~Integration" | |
| - name: Test Core | |
| run: dotnet test tests/Net.Zmq.Core.Tests/Net.Zmq.Core.Tests.csproj --configuration Release --no-build --verbosity normal | |
| test-macos-x64: | |
| runs-on: macos-15 | |
| needs: build | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup .NET x64 (Rosetta) | |
| run: | | |
| curl -sSL https://dot.net/v1/dotnet-install.sh | bash /dev/stdin --channel 8.0 --architecture x64 --install-dir ~/.dotnet-x64 | |
| echo "$HOME/.dotnet-x64" >> $GITHUB_PATH | |
| - name: Verify x64 .NET | |
| run: | | |
| arch -x86_64 ~/.dotnet-x64/dotnet --info | head -20 | |
| - name: Download build artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: build-output | |
| - name: Prepare native library | |
| run: | | |
| chmod +x native/runtimes/osx-x64/native/libzmq.dylib | |
| xattr -d com.apple.quarantine native/runtimes/osx-x64/native/libzmq.dylib 2>/dev/null || true | |
| ls -la native/runtimes/osx-x64/native/ | |
| echo "=== Library dependencies ===" | |
| otool -L native/runtimes/osx-x64/native/libzmq.dylib || true | |
| - name: Copy native library to test output | |
| run: | | |
| cp native/runtimes/osx-x64/native/libzmq.dylib tests/Net.Zmq.Tests/bin/Release/net8.0/ | |
| cp native/runtimes/osx-x64/native/libzmq.dylib tests/Net.Zmq.Core.Tests/bin/Release/net8.0/ | |
| - name: Verify build artifacts | |
| run: | | |
| echo "=== Net.Zmq.Tests output ===" | |
| ls -la tests/Net.Zmq.Tests/bin/Release/net8.0/libzmq.dylib | |
| echo "=== Net.Zmq.Core.Tests output ===" | |
| ls -la tests/Net.Zmq.Core.Tests/bin/Release/net8.0/libzmq.dylib | |
| - name: Test Unit | |
| run: arch -x86_64 ~/.dotnet-x64/dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName!~Integration" | |
| - name: Test Integration | |
| run: arch -x86_64 ~/.dotnet-x64/dotnet test tests/Net.Zmq.Tests/Net.Zmq.Tests.csproj --configuration Release --no-build --verbosity normal --filter "FullyQualifiedName~Integration" | |
| - name: Test Core | |
| run: arch -x86_64 ~/.dotnet-x64/dotnet test tests/Net.Zmq.Core.Tests/Net.Zmq.Core.Tests.csproj --configuration Release --no-build --verbosity normal | |
| pack: | |
| runs-on: ubuntu-22.04 | |
| needs: [test-windows, test-windows-arm64, test-linux, test-linux-arm64, test-macos-arm64, test-macos-x64] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Setup .NET | |
| uses: actions/setup-dotnet@v4 | |
| with: | |
| dotnet-version: '8.0.x' | |
| - name: Download build artifacts | |
| uses: actions/download-artifact@v4 | |
| with: | |
| name: build-output | |
| - name: Restore | |
| run: dotnet restore | |
| - name: Pack | |
| run: dotnet pack --configuration Release --no-build --output ./artifacts | |
| - name: Upload artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: nuget-packages | |
| path: ./artifacts/*.nupkg |