Skip to content

Commit

Permalink
Merge remote-tracking branch 'origin/main' into fl/exception-manager
Browse files Browse the repository at this point in the history
# Conflicts:
#	Common/src/Pollster/Pollster.cs
#	Common/src/Pollster/PostProcessor.cs
#	Common/src/Pollster/RunningTaskProcessor.cs
#	Common/src/Pollster/TaskQueueBase.cs
  • Loading branch information
lemaitre-aneo committed Aug 23, 2024
2 parents ab98a30 + a8e8fba commit 0f95f7d
Show file tree
Hide file tree
Showing 93 changed files with 1,483 additions and 552 deletions.
223 changes: 188 additions & 35 deletions .github/workflows/build.yml

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion .github/workflows/code-formatting.yml
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ jobs:
run: |
git diff > patch-csharp.diff
- uses: actions/upload-artifact@0b2256b8c012f0828dc542b3febcab082c67f72b # v4
- uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a # v4
if: ${{ failure() && steps.check-diff.conclusion == 'failure' }}
with:
name: patch-csharp
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/make-release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ jobs:

- name: Set up Docker Buildx
id: buildx
uses: docker/setup-buildx-action@4fd812986e6c8c2a69e18311145f9371337f27d4 # v3
uses: docker/setup-buildx-action@988b5a0280414f521da01fcc63a27aeeb4b104db # v3

- name: Setup just
run: sudo snap install --edge --classic just
Expand All @@ -96,7 +96,7 @@ jobs:
run: echo ${{ secrets.DOCKER_HUB_TOKEN }} | docker login -u ${{ secrets.DOCKER_HUB_LOGIN }} --password-stdin

- name: Build
run: just tag=$VERSION platform=linux/arm64,linux/amd64 load=false push=true ${{ matrix.type }}
run: just tag=$VERSION platform=linux/arm64,linux/amd64,windows/amd64 load=false push=true ${{ matrix.type }}


publish-nuget:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/manual-integration-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ jobs:
find /tmp/armoniklogs -name "*.log"
- name: Store logs
uses: actions/upload-artifact@0b2256b8c012f0828dc542b3febcab082c67f72b # v4
uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a # v4
if: always()
with:
name: Logs Stream
Expand Down Expand Up @@ -124,7 +124,7 @@ jobs:
find /tmp/armoniklogs -name "*.log"
- name: Store logs
uses: actions/upload-artifact@0b2256b8c012f0828dc542b3febcab082c67f72b # v4
uses: actions/upload-artifact@834a144ee995460fba8ed112a2fc961b36a5ec5a # v4
if: always()
with:
name: Logs HtcMock
Expand Down
186 changes: 186 additions & 0 deletions .github/workflows/manual-test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,186 @@
name: Manual Test

on:
workflow_dispatch:
inputs:
filter:
description: 'Filter for tests'
default: ''
type: string

jobs:
tests:
strategy:
matrix:
projects:
- Common/tests
- Adaptors/MongoDB/tests
- Adaptors/Memory/tests
- Adaptors/S3/tests
os:
- ubuntu-latest
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
ref: ${{ github.ref }}
submodules: true

- name: Install AWSCLI (the one in the Github runner does not work)
run: |
pip install awscli
- name: Setup just
run: |
sudo snap install --edge --classic just
- name: Minio Server UP
if: ${{ matrix.projects }} == "Adaptors/S3/tests"
run: |
MONITOR_PREFIX="monitor/deploy/" tools/retry.sh -w 30 -- tools/monitor.sh \
just object=minio deployTargetObject
- name: Dotnet Restore
run: |
MONITOR_PREFIX="monitor/restore/" MONITOR_CD=${{ matrix.projects }} tools/retry.sh -w 60 -- tools/monitor.sh \
dotnet restore
- name: Dotnet Build
run: |
MONITOR_PREFIX="monitor/build/" MONITOR_CD=${{ matrix.projects }} tools/monitor.sh \
dotnet build
- name: Run tests
run: |
MONITOR_PREFIX="monitor/test/" MONITOR_CD=${{ matrix.projects }} tools/monitor.sh \
dotnet test --logger "trx;LogFileName=test-results.trx" ${filter:+--filter "$filter"} -p:RunAnalyzers=false -p:WarningLevel=0
env:
filter: ${{ inputs.filter }}

- name: Test Report
uses: dorny/test-reporter@v1
if: success() || failure()
with:
name: Test - ${{ matrix.os }} ${{ matrix.projects }}
path: ${{ matrix.projects }}/TestResults/test-results.trx
reporter: dotnet-trx
- name: Upload monitor profile
if: always()
run: |
export AWS_ACCESS_KEY_ID=${{ secrets.AWS_ACCESS_KEY_ID }}
export AWS_SECRET_ACCESS_KEY=${{ secrets.AWS_SECRET_ACCESS_KEY }}
project="$(echo ${{ matrix.projects }} | sed 's:/:_:')"
tar -czf - monitor/ | aws s3 cp - s3://${{ secrets.AWS_LOG_BUCKET_NAME }}/core-pipeline/${{ github.run_number }}/${{ github.run_attempt }}/tests-$project-monitor.tar.gz
testsQueueProtos:
strategy:
matrix:
queue:
- activemq
- rabbitmq
projects:
- Adaptors/Amqp/tests
os:
- ubuntu-latest
include:
- queue: rabbitmq091
projects: Adaptors/RabbitMQ/tests
os: ubuntu-latest
fail-fast: false
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
ref: ${{ github.ref }}
submodules: true

- name: Install AWSCLI (the one in the Github runner does not work)
run: |
pip install awscli
- name: Setup just
run: |
sudo snap install --edge --classic just
- name: Set up queue
run: |
MONITOR_PREFIX="monitor/deploy/" tools/retry.sh -w 30 -- tools/monitor.sh \
just queue=${{ matrix.queue }} deployTargetQueue
- name: Dotnet Restore
run: |
MONITOR_PREFIX="monitor/restore/" MONITOR_CD=${{ matrix.projects }} tools/retry.sh -w 60 -- tools/monitor.sh \
dotnet restore
- name: Dotnet Build
run: |
MONITOR_PREFIX="monitor/build/" MONITOR_CD=${{ matrix.projects }} tools/monitor.sh \
dotnet build
- name: Run tests
run: |
MONITOR_PREFIX="monitor/test/" MONITOR_CD=${{ matrix.projects }} tools/monitor.sh \
dotnet test --logger "trx;LogFileName=test-results.trx" ${filter:+--filter "$filter"} -p:RunAnalyzers=false -p:WarningLevel=0
env:
filter: ${{ inputs.filter }}

- name: Test Report
uses: dorny/test-reporter@v1
if: success() || failure()
with:
name: Test - ${{ matrix.queue }} ${{ matrix.projects }}
path: ${{ matrix.projects }}/TestResults/test-results.trx
reporter: dotnet-trx
- name: Upload monitor profile
if: always()
run: |
export AWS_ACCESS_KEY_ID=${{ secrets.AWS_ACCESS_KEY_ID }}
export AWS_SECRET_ACCESS_KEY=${{ secrets.AWS_SECRET_ACCESS_KEY }}
project="$(echo ${{ matrix.projects }} | sed 's:/:_:')"
tar -czf - monitor/ | aws s3 cp - s3://${{ secrets.AWS_LOG_BUCKET_NAME }}/core-pipeline/${{ github.run_number }}/${{ github.run_attempt }}/test-${{ matrix.queue }}-$project-monitor.tar.gz
testsWinOnly:
strategy:
matrix:
projects:
- Adaptors/Redis/tests
- Common/tests
- Adaptors/MongoDB/tests
- Adaptors/Memory/tests
fail-fast: false
runs-on: windows-latest
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
with:
ref: ${{ github.ref }}
submodules: true

- name: Dotnet Restore
run: |
cd ${{ matrix.projects }}
dotnet restore
- name: Dotnet Build
run: |
cd ${{ matrix.projects }}
dotnet build
- name: Run tests
shell: bash
run: |
cd ${{ matrix.projects }}
dotnet test --logger "trx;LogFileName=test-results.trx" ${filter:+--filter "$filter"} -p:RunAnalyzers=false -p:WarningLevel=0
env:
filter: ${{ inputs.filter }}

- name: Test Report
uses: dorny/test-reporter@v1
if: success() || failure()
with:
name: Test - windows ${{ matrix.projects }}
path: ${{ matrix.projects }}/TestResults/test-results.trx
reporter: dotnet-trx
2 changes: 1 addition & 1 deletion .github/workflows/sonar.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
runs-on: windows-latest
steps:
- name: Set up JDK
uses: actions/setup-java@99b8673ff64fbf99d8d325f52d9a5bdedb8483e9 # v4
uses: actions/setup-java@6a0805fcefea3d4657a47ac4c165951e33482018 # v4
with:
distribution: 'zulu'
java-version: 17
Expand Down
1 change: 1 addition & 0 deletions Adaptors/Amqp/src/ArmoniK.Core.Adapters.Amqp.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<Company>ANEO</Company>
<Copyright>Copyright (C) ANEO, 2021-2021</Copyright>
<PackageLicenseExpression>AGPL-3.0-or-later</PackageLicenseExpression>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<IsPackable>false</IsPackable>
<Nullable>enable</Nullable>
</PropertyGroup>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<Company>ANEO</Company>
<Copyright>Copyright (C) ANEO, 2021-2022</Copyright>
<PackageLicenseExpression>AGPL-3.0-or-later</PackageLicenseExpression>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
<IsPackable>true</IsPackable>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<IsPackable>true</IsPackable>
<RuntimeIdentifiers>win-x64;linux-x64</RuntimeIdentifiers>
<Nullable>enable</Nullable>
</PropertyGroup>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<IsPackable>false</IsPackable>
<Nullable>enable</Nullable>
</PropertyGroup>
Expand Down
2 changes: 1 addition & 1 deletion Adaptors/Memory/src/ArmoniK.Core.Adapters.Memory.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<Company>ANEO</Company>
<Copyright>Copyright (C) ANEO, 2021-2021</Copyright>
<PackageLicenseExpression>AGPL-3.0-or-later</PackageLicenseExpression>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<IsPackable>false</IsPackable>
<Nullable>enable</Nullable>
</PropertyGroup>
Expand Down
3 changes: 1 addition & 2 deletions Adaptors/MongoDB/src/ArmoniK.Core.Adapters.MongoDB.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,13 @@

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<Company>ANEO</Company>
<Copyright>Copyright (C) ANEO, 2021-2021</Copyright>
<PackageLicenseExpression>AGPL-3.0-or-later</PackageLicenseExpression>
<PackageRequireLicenseAcceptance>True</PackageRequireLicenseAcceptance>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<IsPackable>true</IsPackable>
<RuntimeIdentifiers>win-x64;linux-x64</RuntimeIdentifiers>
<Nullable>enable</Nullable>
</PropertyGroup>

Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
<Project Sdk="Microsoft.NET.Sdk">
<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<IsPackable>false</IsPackable>
<Nullable>enable</Nullable>
</PropertyGroup>
Expand Down
1 change: 1 addition & 0 deletions Adaptors/PubSub/src/ArmoniK.Core.Adapters.PubSub.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<Nullable>enable</Nullable>
<EnableDynamicLoading>true</EnableDynamicLoading>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
Expand Down
2 changes: 1 addition & 1 deletion Adaptors/PubSub/src/QueueMessageHandler.cs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,6 @@ await autoExtendAckDeadline_.Stop()
case QueueMessageStatus.Failed:
case QueueMessageStatus.Running:
case QueueMessageStatus.Postponed:
case QueueMessageStatus.Poisonous:
await subscriberServiceApiClient_.ModifyAckDeadlineAsync(subscriptionName_,
new[]
{
Expand All @@ -79,6 +78,7 @@ await subscriberServiceApiClient_.ModifyAckDeadlineAsync(subscriptionName_,
break;
case QueueMessageStatus.Cancelled:
case QueueMessageStatus.Processed:
case QueueMessageStatus.Poisonous:
await subscriberServiceApiClient_.AcknowledgeAsync(subscriptionName_,
new[]
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<Company>ANEO</Company>
<Copyright>Copyright (C) ANEO, 2021-2021</Copyright>
<PackageLicenseExpression>AGPL-3.0-or-later</PackageLicenseExpression>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

<PropertyGroup>
<TargetFramework>net8.0</TargetFramework>
<GeneratePackageOnBuild>True</GeneratePackageOnBuild>
<RuntimeIdentifiers>win-x64;linux-x64;linux-arm64</RuntimeIdentifiers>
<Company>ANEO</Company>
<Copyright>Copyright (C) ANEO, 2021-2021</Copyright>
<PackageLicenseExpression>AGPL-3.0-or-later</PackageLicenseExpression>
Expand Down
Loading

0 comments on commit 0f95f7d

Please sign in to comment.