From f41e575d168dcf64d6005530f92501e7846de00f Mon Sep 17 00:00:00 2001 From: Norbert Truchsess Date: Mon, 29 Jul 2024 16:23:10 +0200 Subject: [PATCH 1/3] chore(dependencies): bump System.Text.Json version 8.0.4 (#184) * upgrade efcore to 8.0.7 * upgrade frameworks to 2.4.2 * cleanup redundant dependencies --- DEPENDENCIES | 5 +---- src/database/PolicyHub.DbAccess/PolicyHub.DbAccess.csproj | 4 ++-- .../PolicyHub.Migrations/PolicyHub.Migrations.csproj | 5 ++--- src/database/PolicyHub.Migrations/Program.cs | 2 +- .../BusinessLogic/PolicyHubBusinessLogic.cs | 6 ++---- src/hub/PolicyHub.Service/PolicyHub.Service.csproj | 2 +- src/hub/PolicyHub.Service/Program.cs | 6 +++--- .../PolicyHub.Entities.Tests.csproj | 6 +++--- .../PolicyHub.Service.Tests/PolicyHub.Service.Tests.csproj | 6 +++--- 9 files changed, 18 insertions(+), 24 deletions(-) diff --git a/DEPENDENCIES b/DEPENDENCIES index 3d8bb53..722ad4d 100644 --- a/DEPENDENCIES +++ b/DEPENDENCIES @@ -1,8 +1,5 @@ -nuget/nuget/-/AutoFixture.AutoFakeItEasy/4.18.0, MIT, approved, #10064 nuget/nuget/-/AutoFixture.AutoFakeItEasy/4.18.1, MIT, approved, #10064 -nuget/nuget/-/AutoFixture.Xunit/4.18.0, MIT, approved, #10082 nuget/nuget/-/AutoFixture.Xunit/4.18.1, MIT, approved, #10082 -nuget/nuget/-/AutoFixture/4.18.0, MIT, approved, #10057 nuget/nuget/-/AutoFixture/4.18.1, MIT, approved, #10057 nuget/nuget/-/BouncyCastle.Cryptography/2.2.1, MIT AND Apache-2.0 AND BSD-3-Clause AND LicenseRef-Permission-Notice, approved, #10066 nuget/nuget/-/Castle.Core/5.1.1, Apache-2.0, approved, #13966 @@ -28,7 +25,7 @@ nuget/nuget/-/Serilog.Enrichers.Thread/3.1.0, Apache-2.0, approved, clearlydefin nuget/nuget/-/Serilog.Extensions.Hosting/8.0.0, Apache-2.0, approved, #13962 nuget/nuget/-/Serilog.Extensions.Logging/8.0.0, Apache-2.0, approved, #13985 nuget/nuget/-/Serilog.Formatting.Compact/2.0.0, Apache-2.0, approved, #13981 -nuget/nuget/-/Serilog.Settings.Configuration/8.0.0, Apache-2.0, approved, #13988 +nuget/nuget/-/Serilog.Settings.Configuration/8.0.2, Apache-2.0, approved, #13988 nuget/nuget/-/Serilog.Sinks.Console/5.0.1, Apache-2.0, approved, #13980 nuget/nuget/-/Serilog.Sinks.Debug/2.0.0, Apache-2.0, approved, clearlydefined nuget/nuget/-/Serilog.Sinks.File/5.0.0, Apache-2.0, approved, #11116 diff --git a/src/database/PolicyHub.DbAccess/PolicyHub.DbAccess.csproj b/src/database/PolicyHub.DbAccess/PolicyHub.DbAccess.csproj index f46e14b..f7876d6 100644 --- a/src/database/PolicyHub.DbAccess/PolicyHub.DbAccess.csproj +++ b/src/database/PolicyHub.DbAccess/PolicyHub.DbAccess.csproj @@ -33,8 +33,8 @@ - - + + diff --git a/src/database/PolicyHub.Migrations/PolicyHub.Migrations.csproj b/src/database/PolicyHub.Migrations/PolicyHub.Migrations.csproj index 6edaecb..fa2ecd2 100644 --- a/src/database/PolicyHub.Migrations/PolicyHub.Migrations.csproj +++ b/src/database/PolicyHub.Migrations/PolicyHub.Migrations.csproj @@ -45,9 +45,8 @@ - - - + + diff --git a/src/database/PolicyHub.Migrations/Program.cs b/src/database/PolicyHub.Migrations/Program.cs index 5f94233..4217826 100644 --- a/src/database/PolicyHub.Migrations/Program.cs +++ b/src/database/PolicyHub.Migrations/Program.cs @@ -54,5 +54,5 @@ finally { Log.Information("Process Shutting down..."); - Log.CloseAndFlush(); + await Log.CloseAndFlushAsync().ConfigureAwait(false); } diff --git a/src/hub/PolicyHub.Service/BusinessLogic/PolicyHubBusinessLogic.cs b/src/hub/PolicyHub.Service/BusinessLogic/PolicyHubBusinessLogic.cs index 9c4093c..18f641e 100644 --- a/src/hub/PolicyHub.Service/BusinessLogic/PolicyHubBusinessLogic.cs +++ b/src/hub/PolicyHub.Service/BusinessLogic/PolicyHubBusinessLogic.cs @@ -20,12 +20,10 @@ using Org.Eclipse.TractusX.PolicyHub.DbAccess; using Org.Eclipse.TractusX.PolicyHub.DbAccess.Models; using Org.Eclipse.TractusX.PolicyHub.DbAccess.Repositories; -using Org.Eclipse.TractusX.PolicyHub.Entities.Entities; using Org.Eclipse.TractusX.PolicyHub.Entities.Enums; using Org.Eclipse.TractusX.PolicyHub.Service.Extensions; using Org.Eclipse.TractusX.PolicyHub.Service.Models; using Org.Eclipse.TractusX.Portal.Backend.Framework.ErrorHandling; -using Org.Eclipse.TractusX.Portal.Backend.Framework.Linq; using System.Text.RegularExpressions; namespace Org.Eclipse.TractusX.PolicyHub.Service.BusinessLogic; @@ -68,10 +66,10 @@ private static (object rightOperand, AdditionalAttributes? additionalAttribute) _ => operatorId == OperatorId.Equals ? rightOperands.Count() > 1 ? ($"@{leftOperand}{(useCase != null ? - useCase.ToString().Insert(0, ".") : + useCase.Value.ToString().Insert(0, ".") : string.Empty)}-{attributes.Key}", new AdditionalAttributes($"@{leftOperand}{(useCase != null ? - useCase.ToString().Insert(0, ".") : + useCase.Value.ToString().Insert(0, ".") : string.Empty)}-{attributes.Key}", rightOperands)) : (rightOperands.Single(), null) : (rightOperands, null) diff --git a/src/hub/PolicyHub.Service/PolicyHub.Service.csproj b/src/hub/PolicyHub.Service/PolicyHub.Service.csproj index e96ff48..83fd06b 100644 --- a/src/hub/PolicyHub.Service/PolicyHub.Service.csproj +++ b/src/hub/PolicyHub.Service/PolicyHub.Service.csproj @@ -36,7 +36,7 @@ - + diff --git a/src/hub/PolicyHub.Service/Program.cs b/src/hub/PolicyHub.Service/Program.cs index 1b7664b..e71d0bf 100644 --- a/src/hub/PolicyHub.Service/Program.cs +++ b/src/hub/PolicyHub.Service/Program.cs @@ -26,8 +26,8 @@ const string Version = "v2"; -WebApplicationBuildRunner - .BuildAndRunWebApplication(args, "policy-hub", Version, ".Hub", +await WebApplicationBuildRunner + .BuildAndRunWebApplicationAsync(args, "policy-hub", Version, ".Hub", builder => { builder.Services.AddTransient(); @@ -47,4 +47,4 @@ app.MapGroup("/api") .WithOpenApi() .MapPolicyHubApi(); - }); + }).ConfigureAwait(ConfigureAwaitOptions.None); diff --git a/tests/database/PolicyHub.Entities.Tests/PolicyHub.Entities.Tests.csproj b/tests/database/PolicyHub.Entities.Tests/PolicyHub.Entities.Tests.csproj index bb42047..0ce74eb 100644 --- a/tests/database/PolicyHub.Entities.Tests/PolicyHub.Entities.Tests.csproj +++ b/tests/database/PolicyHub.Entities.Tests/PolicyHub.Entities.Tests.csproj @@ -32,12 +32,12 @@ - - + + - + diff --git a/tests/hub/PolicyHub.Service.Tests/PolicyHub.Service.Tests.csproj b/tests/hub/PolicyHub.Service.Tests/PolicyHub.Service.Tests.csproj index ba58f5f..7edfe95 100644 --- a/tests/hub/PolicyHub.Service.Tests/PolicyHub.Service.Tests.csproj +++ b/tests/hub/PolicyHub.Service.Tests/PolicyHub.Service.Tests.csproj @@ -32,9 +32,9 @@ - - - + + + From 5bdbc96fb72a1c1b77ce2e2fdb325bcbaedf810b Mon Sep 17 00:00:00 2001 From: Phil Schneider Date: Tue, 30 Jul 2024 15:11:05 +0200 Subject: [PATCH 2/3] docs: add known knowns section to readme (#188) Reviewed-By: Evelyn Gurschler --- README.md | 4 ++++ .../known-knowns/known-issues-and-limitations.md | 11 +++++++++++ 2 files changed, 15 insertions(+) create mode 100644 docs/technical-documentation/known-knowns/known-issues-and-limitations.md diff --git a/README.md b/README.md index 044c60f..4e2ec5f 100644 --- a/README.md +++ b/README.md @@ -23,6 +23,10 @@ Run the following command from the CLI in the directory of the service you want dotnet run ``` +## Known Issues and Limitations + +See [Known Knowns](/docs/technical-documentation/known-knowns/known-issues-and-limitations.md). + ## Notice for Docker image This application provides container images for demonstration purposes. diff --git a/docs/technical-documentation/known-knowns/known-issues-and-limitations.md b/docs/technical-documentation/known-knowns/known-issues-and-limitations.md new file mode 100644 index 0000000..bad7443 --- /dev/null +++ b/docs/technical-documentation/known-knowns/known-issues-and-limitations.md @@ -0,0 +1,11 @@ +# Known Issues and Limitations + +- There is currently a discussion ongoing about the value types of PolicyKindId `ContractReference` that can be found [here](https://github.com/eclipse-tractusx/policy-hub/issues/186) + +## NOTICE + +This work is licensed under the [Apache-2.0](https://www.apache.org/licenses/LICENSE-2.0). + +- SPDX-License-Identifier: Apache-2.0 +- SPDX-FileCopyrightText: 2024 Contributors to the Eclipse Foundation +- Source URL: https://github.com/eclipse-tractusx/policy-hub \ No newline at end of file From ef092cb792e5df90cee86e1607fd4d9b56c9a712 Mon Sep 17 00:00:00 2001 From: Evelyn Gurschler Date: Tue, 30 Jul 2024 15:41:33 +0200 Subject: [PATCH 3/3] build(1.1.0): bump version and update docs --- charts/policy-hub/Chart.yaml | 4 ++-- charts/policy-hub/README.md | 2 +- environments/argocd-app-templates/appsetup-int.yaml | 2 +- environments/consortia/argocd-app-templates/appsetup-int.yaml | 2 +- src/Directory.Build.props | 2 +- 5 files changed, 6 insertions(+), 6 deletions(-) diff --git a/charts/policy-hub/Chart.yaml b/charts/policy-hub/Chart.yaml index 3a617f5..29e7a45 100644 --- a/charts/policy-hub/Chart.yaml +++ b/charts/policy-hub/Chart.yaml @@ -20,8 +20,8 @@ apiVersion: v2 name: policy-hub type: application -version: 1.1.0-rc.2 -appVersion: 1.1.0-rc.2 +version: 1.1.0 +appVersion: 1.1.0 description: Helm chart for Policy Hub home: https://github.com/eclipse-tractusx/policy-hub dependencies: diff --git a/charts/policy-hub/README.md b/charts/policy-hub/README.md index a49b197..d545edd 100644 --- a/charts/policy-hub/README.md +++ b/charts/policy-hub/README.md @@ -33,7 +33,7 @@ To use the helm chart as a dependency: dependencies: - name: policy-hub repository: https://eclipse-tractusx.github.io/charts/dev - version: 1.1.0-rc.2 + version: 1.1.0 ``` ## Requirements diff --git a/environments/argocd-app-templates/appsetup-int.yaml b/environments/argocd-app-templates/appsetup-int.yaml index bbc2cf4..a650e05 100644 --- a/environments/argocd-app-templates/appsetup-int.yaml +++ b/environments/argocd-app-templates/appsetup-int.yaml @@ -28,7 +28,7 @@ spec: source: path: charts/policy-hub repoURL: 'https://github.com/eclipse-tractusx/policy-hub.git' - targetRevision: policy-hub-1.1.0-rc.2 + targetRevision: policy-hub-1.1.0 plugin: env: - name: AVP_SECRET diff --git a/environments/consortia/argocd-app-templates/appsetup-int.yaml b/environments/consortia/argocd-app-templates/appsetup-int.yaml index ab65737..0767bbc 100644 --- a/environments/consortia/argocd-app-templates/appsetup-int.yaml +++ b/environments/consortia/argocd-app-templates/appsetup-int.yaml @@ -28,7 +28,7 @@ spec: source: path: charts/policy-hub repoURL: 'https://github.com/eclipse-tractusx/policy-hub.git' - targetRevision: policy-hub-1.1.0-rc.2 + targetRevision: policy-hub-1.1.0 plugin: env: - name: AVP_SECRET diff --git a/src/Directory.Build.props b/src/Directory.Build.props index 580eb35..b10e5d6 100644 --- a/src/Directory.Build.props +++ b/src/Directory.Build.props @@ -20,6 +20,6 @@ 1.1.0 - rc.2 +