From 25314bccd20d315f2b88def994dc491118bbedf1 Mon Sep 17 00:00:00 2001 From: Enrico Risa Date: Mon, 4 Mar 2024 16:17:55 +0100 Subject: [PATCH 1/5] chore: fixes after upstream changes --- .../eclipse/tractusx/edc/lifecycle/tx/iatp/DataspaceIssuer.java | 1 + 1 file changed, 1 insertion(+) diff --git a/edc-tests/e2e-tests/src/test/java/org/eclipse/tractusx/edc/lifecycle/tx/iatp/DataspaceIssuer.java b/edc-tests/e2e-tests/src/test/java/org/eclipse/tractusx/edc/lifecycle/tx/iatp/DataspaceIssuer.java index 8bb537034..829291808 100644 --- a/edc-tests/e2e-tests/src/test/java/org/eclipse/tractusx/edc/lifecycle/tx/iatp/DataspaceIssuer.java +++ b/edc-tests/e2e-tests/src/test/java/org/eclipse/tractusx/edc/lifecycle/tx/iatp/DataspaceIssuer.java @@ -95,6 +95,7 @@ public VerifiableCredentialResource issueCredential(IatpParticipant participant, var rawVc = createLdpVc(jsonLd, type, subjectSupplier); return VerifiableCredentialResource.Builder.newInstance() .issuerId(didUrl()) + .participantId(participant.didUrl()) .holderId(participant.getBpn()) .credential(new VerifiableCredentialContainer(rawVc, CredentialFormat.JSON_LD, credential)) .build(); From 476406c68361dd82e6260d960e8a498ed5b26b8c Mon Sep 17 00:00:00 2001 From: Enrico Risa Date: Wed, 6 Mar 2024 11:49:20 +0100 Subject: [PATCH 2/5] chore: fix tests --- .../org/eclipse/tractusx/edc/api/edr/EdrApiTest.java | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/edc-extensions/edr/edr-api/src/test/java/org/eclipse/tractusx/edc/api/edr/EdrApiTest.java b/edc-extensions/edr/edr-api/src/test/java/org/eclipse/tractusx/edc/api/edr/EdrApiTest.java index 27a0a03dd..cf29fd7d8 100644 --- a/edc-extensions/edr/edr-api/src/test/java/org/eclipse/tractusx/edc/api/edr/EdrApiTest.java +++ b/edc-extensions/edr/edr-api/src/test/java/org/eclipse/tractusx/edc/api/edr/EdrApiTest.java @@ -31,6 +31,7 @@ import org.eclipse.edc.jsonld.spi.JsonLd; import org.eclipse.edc.jsonld.util.JacksonJsonLd; import org.eclipse.edc.junit.assertions.AbstractResultAssert; +import org.eclipse.edc.spi.agent.ParticipantIdMapper; import org.eclipse.edc.transform.spi.TypeTransformerRegistry; import org.eclipse.tractusx.edc.api.edr.dto.NegotiateEdrRequestDto; import org.eclipse.tractusx.edc.api.edr.transform.JsonObjectToNegotiateEdrRequestDtoTransformer; @@ -49,6 +50,9 @@ import static org.eclipse.tractusx.edc.edr.spi.types.EndpointDataReferenceEntry.EDR_ENTRY_PROVIDER_ID; import static org.eclipse.tractusx.edc.edr.spi.types.EndpointDataReferenceEntry.EDR_ENTRY_STATE; import static org.eclipse.tractusx.edc.edr.spi.types.EndpointDataReferenceEntry.EDR_ENTRY_TRANSFER_PROCESS_ID; +import static org.mockito.ArgumentMatchers.any; +import static org.mockito.Mockito.mock; +import static org.mockito.Mockito.when; public class EdrApiTest { @@ -64,7 +68,11 @@ void setUp() { transformer.register(new JsonObjectToContractOfferDescriptionTransformer()); transformer.register(new JsonObjectToCallbackAddressTransformer()); transformer.register(new JsonObjectToNegotiateEdrRequestDtoTransformer()); - OdrlTransformersFactory.jsonObjectToOdrlTransformers().forEach(transformer::register); + var mapper = mock(ParticipantIdMapper.class); + + when(mapper.fromIri(any())).thenAnswer(a -> a.getArgument(0)); + when(mapper.toIri(any())).thenAnswer(a -> a.getArgument(0)); + OdrlTransformersFactory.jsonObjectToOdrlTransformers(mapper).forEach(transformer::register); } @Test From 1701be8a31bc3a26ebfa7cb131a3b9937a94a0c6 Mon Sep 17 00:00:00 2001 From: Enrico Risa Date: Wed, 6 Mar 2024 12:25:31 +0100 Subject: [PATCH 3/5] chore: fix upgradeability test with 0.6.0 --- .github/workflows/upgradeability-test.yaml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/upgradeability-test.yaml b/.github/workflows/upgradeability-test.yaml index 003ae0f74..39c2ebeb9 100644 --- a/.github/workflows/upgradeability-test.yaml +++ b/.github/workflows/upgradeability-test.yaml @@ -66,7 +66,7 @@ jobs: - name: "Get latest released version" id: get-version run: | - RELEASED_VERSION=$(helm search repo tractusx/tractusx-connector -o json | jq -r '.[0].version') + RELEASED_VERSION=$(helm search repo tractusx/tractusx-connector -l -o json | jq -r 'map(select(.version !="0.6.0")) | first | .version') echo "Last official release is $RELEASED_VERSION" echo "RELEASE=$RELEASED_VERSION" >> $GITHUB_ENV exit 0 From 93917ebbdb92e750074db03d28a1f1233b3adc4f Mon Sep 17 00:00:00 2001 From: Enrico Risa Date: Wed, 6 Mar 2024 13:53:49 +0100 Subject: [PATCH 4/5] pr remarks --- .github/workflows/upgradeability-test.yaml | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.github/workflows/upgradeability-test.yaml b/.github/workflows/upgradeability-test.yaml index 39c2ebeb9..df486e3fd 100644 --- a/.github/workflows/upgradeability-test.yaml +++ b/.github/workflows/upgradeability-test.yaml @@ -63,10 +63,11 @@ jobs: helm repo add tractusx https://eclipse-tractusx.github.io/charts/dev helm repo update tractusx + ## Skip 0.6.0 when doing the compatibility check ref https://github.com/eclipse-tractusx/tractusx-edc/issues/1082 - name: "Get latest released version" id: get-version run: | - RELEASED_VERSION=$(helm search repo tractusx/tractusx-connector -l -o json | jq -r 'map(select(.version !="0.6.0")) | first | .version') + RELEASED_VERSION=$(helm search repo tractusx/tractusx-connector -l -o json | jq -r 'map(select(.version !="0.6.0")) | first | .version') echo "Last official release is $RELEASED_VERSION" echo "RELEASE=$RELEASED_VERSION" >> $GITHUB_ENV exit 0 From 25aaad2f95c7f8c2c272e9a9b97afa6663111609 Mon Sep 17 00:00:00 2001 From: Enrico Risa Date: Wed, 6 Mar 2024 14:24:39 +0100 Subject: [PATCH 5/5] chore: dependencies file --- DEPENDENCIES | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/DEPENDENCIES b/DEPENDENCIES index dd69edb1b..b66f18352 100644 --- a/DEPENDENCIES +++ b/DEPENDENCIES @@ -52,8 +52,11 @@ maven/mavencentral/com.fasterxml.jackson/jackson-bom/2.15.1, Apache-2.0, approve maven/mavencentral/com.fasterxml.jackson/jackson-bom/2.16.1, Apache-2.0, approved, #11852 maven/mavencentral/com.fasterxml.woodstox/woodstox-core/6.5.1, Apache-2.0, approved, #7950 maven/mavencentral/com.github.docker-java/docker-java-api/3.3.5, Apache-2.0, approved, #10346 +maven/mavencentral/com.github.docker-java/docker-java-api/3.3.6, Apache-2.0, approved, #10346 maven/mavencentral/com.github.docker-java/docker-java-transport-zerodep/3.3.5, Apache-2.0 AND (Apache-2.0 AND BSD-3-Clause), approved, #7946 +maven/mavencentral/com.github.docker-java/docker-java-transport-zerodep/3.3.6, Apache-2.0 AND (Apache-2.0 AND BSD-3-Clause), approved, #7946 maven/mavencentral/com.github.docker-java/docker-java-transport/3.3.5, Apache-2.0, approved, #7942 +maven/mavencentral/com.github.docker-java/docker-java-transport/3.3.6, Apache-2.0, approved, #7942 maven/mavencentral/com.github.stephenc.jcip/jcip-annotations/1.0-1, Apache-2.0, approved, CQ21949 maven/mavencentral/com.google.code.findbugs/jsr305/3.0.2, Apache-2.0, approved, #20 maven/mavencentral/com.google.code.gson/gson/2.10.1, Apache-2.0, approved, #6159 @@ -478,10 +481,15 @@ maven/mavencentral/org.slf4j/slf4j-api/1.7.7, MIT, approved, CQ9827 maven/mavencentral/org.slf4j/slf4j-api/2.0.12, MIT, approved, #5915 maven/mavencentral/org.slf4j/slf4j-api/2.0.9, MIT, approved, #5915 maven/mavencentral/org.testcontainers/database-commons/1.19.6, Apache-2.0, approved, #10345 +maven/mavencentral/org.testcontainers/database-commons/1.19.7, Apache-2.0, approved, #10345 maven/mavencentral/org.testcontainers/jdbc/1.19.6, Apache-2.0, approved, #10348 +maven/mavencentral/org.testcontainers/jdbc/1.19.7, Apache-2.0, approved, #10348 maven/mavencentral/org.testcontainers/junit-jupiter/1.19.6, MIT, approved, #10344 +maven/mavencentral/org.testcontainers/junit-jupiter/1.19.7, MIT, approved, #10344 maven/mavencentral/org.testcontainers/postgresql/1.19.6, MIT, approved, #10350 +maven/mavencentral/org.testcontainers/postgresql/1.19.7, MIT, approved, #10350 maven/mavencentral/org.testcontainers/testcontainers/1.19.6, Apache-2.0 AND MIT, approved, #10347 +maven/mavencentral/org.testcontainers/testcontainers/1.19.7, Apache-2.0 AND MIT, approved, #10347 maven/mavencentral/org.testcontainers/vault/1.19.6, MIT, approved, #10852 maven/mavencentral/org.xmlresolver/xmlresolver/5.2.2, Apache-2.0, approved, clearlydefined maven/mavencentral/org.yaml/snakeyaml/2.0, Apache-2.0 AND (Apache-2.0 OR BSD-3-Clause OR EPL-1.0 OR GPL-2.0-or-later OR LGPL-2.1-or-later), approved, #7275