Skip to content

Commit

Permalink
wip
Browse files Browse the repository at this point in the history
  • Loading branch information
IvanJosipovic committed Sep 30, 2024
1 parent 06067d7 commit 0dbd8ba
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 27 deletions.
37 changes: 21 additions & 16 deletions .github/workflows/cicd.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,27 @@ jobs:
file: coverage.cobertura.xml
fail_ci_if_error: true

- name: Publish Benchmark
working-directory: benchmarks/oidc-guard-benchmarks
run: dotnet publish -c Release -o bin/publish

- name: Run Benchmark
working-directory: benchmarks/oidc-guard-benchmarks/bin/publish
run: oidc-guard-benchmarks

- name: Store benchmark result
uses: benchmark-action/github-action-benchmark@v1
with:
name: Benchmark.Net Benchmark
tool: 'benchmarkdotnet'
output-file-path: benchmarks/oidc-guard-benchmarks/bin/publish/BenchmarkDotNet.Artifacts/results/Sample.Benchmarks-report-full-compressed.json
github-token: ${{ secrets.GITHUB_TOKEN }}
auto-push: true
# Show alert with commit comment on detecting possible performance regression
alert-threshold: '200%'
comment-on-alert: true
fail-on-alert: false
alert-comment-cc-users: '@IvanJosipovic'

- name: Run Trivy vulnerability scanner
uses: aquasecurity/trivy-action@master
Expand All @@ -66,22 +87,6 @@ jobs:
vuln-type: 'os,library'
severity: 'CRITICAL,HIGH'

benchmark:
name: Benchmark
runs-on: windows-latest
needs: build-test
steps:
- uses: actions/checkout@v4

- name: Setup .NET Core
uses: actions/setup-dotnet@v4
with:
global-json-file: global.json

- name: Benchmark
working-directory: benchmarks/oidc-guard-benchmarks
run: dotnet run -c Release

create-release:
if: ${{ github.event_name != 'pull_request' }}
name: Create Release
Expand Down
21 changes: 10 additions & 11 deletions src/oidc-guard/oidc-guard.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,22 @@

<PropertyGroup>
<TargetFramework>net9.0</TargetFramework>
<Nullable>enable</Nullable>
<EnableConfigurationBindingGenerator>true</EnableConfigurationBindingGenerator>
<EnableRequestDelegateGenerator>true</EnableRequestDelegateGenerator>
<ImplicitUsings>enable</ImplicitUsings>
<InvariantGlobalization>true</InvariantGlobalization>
<RootNamespace>oidc_guard</RootNamespace>
<UserSecretsId>a70c2d04-572e-41af-8710-66bacf303453</UserSecretsId>
<PublishReadyToRun>true</PublishReadyToRun>
<EnableRequestDelegateGenerator>true</EnableRequestDelegateGenerator>
<EnableConfigurationBindingGenerator>true</EnableConfigurationBindingGenerator>
<IsAotCompatible>true</IsAotCompatible>
<PublishAot>false</PublishAot>
<SelfContained>true</SelfContained>
<JsonSerializerIsReflectionEnabledByDefault>false</JsonSerializerIsReflectionEnabledByDefault>
<PublishIISAssets>false</PublishIISAssets>
<TrimmerSingleWarn>false</TrimmerSingleWarn>
<Nullable>enable</Nullable>
<OptimizationPreference>Speed</OptimizationPreference>
<IsAotCompatible>true</IsAotCompatible>
<PublishAot>false</PublishAot>
<PublishIISAssets>false</PublishIISAssets>
<PublishReadyToRun>true</PublishReadyToRun>
<RootNamespace>oidc_guard</RootNamespace>
<SelfContained>true</SelfContained>
<SuppressTrimAnalysisWarnings>false</SuppressTrimAnalysisWarnings>
<TrimmerSingleWarn>false</TrimmerSingleWarn>
<UserSecretsId>a70c2d04-572e-41af-8710-66bacf303453</UserSecretsId>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)'=='Release'">
Expand Down

0 comments on commit 0dbd8ba

Please sign in to comment.