Skip to content

feat(mockup): add baseline for multi tier mockup - without protocol - #1176

Open
gobica wants to merge 12 commits into
eclipse-tractusx:feat/mock-participantfrom
achtzig20:tier-2-mockup-logic
Open

feat(mockup): add baseline for multi tier mockup - without protocol#1176
gobica wants to merge 12 commits into
eclipse-tractusx:feat/mock-participantfrom
achtzig20:tier-2-mockup-logic

Conversation

@gobica

@gobica gobica commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

Description

  • added a generic single-container mock participant for local n-tier supply chain simulation, mocking EDC control/data plane, DTR and PURIS backend for a partner

Pre-review checks

Please ensure to do as many of the following checks as possible, before asking for committer review:

  • DEPENDENCIES are up-to-date. Dash license tool. Committers can open IP issues for restricted libs.
  • Copyright and license header are present on all affected files (TRG 7.02)
  • Documentation Notice are present on all affected files (TRG 7.07)
  • If helm chart has been changed, the chart version has been bumped to either next major, minor or patch level (compared to released chart).
  • Changelog updated (changelog.md) with PR reference and brief summary.
  • Frontend version bumped, if needed (frontend/package.json, frontend/package-lock.json)
  • Backend version bumped, if needed (backend/pom.xml)
  • Open API specification updated, if controllers have been changed (use python script scripts/generate_openapi_yaml.py with running customer backend)

@gobica
gobica requested a review from ReneSchroederLJ July 9, 2026 13:30

@ReneSchroederLJ ReneSchroederLJ left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you for the contribution. In the future please make sure that the mocked outputs are aligned with the outputs of the corresponding submodel endpoints,

Additionally, I don't think the name tier-2 mock is a good choice since it might not be limited to that always. A general name like mock participant is more fitting.

);
tier2Partner = partnerService.create(tier2Partner);
log.info("Created tier2 partner: {}", tier2Partner);
}

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The partner creation should be moved to the bruno collection since the DataInjectionCommandLineRunner setup will be removed as part of #1131.

Comment thread local/mock/tier2/dsp/common.py Outdated
Comment thread local/mock/tier2/data.py Outdated
@@ -0,0 +1,313 @@
#
# Copyright (c) 2026 Contributors to the Eclipse Foundation

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Copyright (c) 2026 Contributors to the Eclipse Foundation
# Copyright (c) 2026 Volkswagen AG

Comment thread local/mock/tier2/Dockerfile Outdated
@@ -0,0 +1,35 @@
#
# Copyright (c) 2025 Contributors to the Eclipse Foundation

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Copyright (c) 2025 Contributors to the Eclipse Foundation
# Copyright (c) 2026 Volkswagen AG

Comment thread local/mock/tier2/main.py Outdated
@@ -0,0 +1,332 @@
#
# Copyright (c) 2026 Contributors to the Eclipse Foundation

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Copyright (c) 2026 Contributors to the Eclipse Foundation
# Copyright (c) 2026 Volkswagen AG

Comment thread local/generate-keys.sh Outdated
ISSUER_BPNL=BPNL000000000000
TIER2_BPNL=BPNL3333333333T3
TIER2_BPNS=BPNS3333333333T3
TIER2_BPNA=BPNA3333333333T3

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The BPNS and BPNA should not be necessary since they are derived from the BPNL in the code anyway.

Comment thread local/mock/tier2/data.py Outdated
# subsequent GET on the data plane, so the two sides must stay in sync.
ITEM_STOCK_ASSET = "itemstocksubmodel-api-asset"
PRODUCTION_ASSET = "productionsubmodel-api-asset"
DEMAND_ASSET = "demandsubmodel-api-asset"

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The current mock is set up as a supplier only. The demand Submodel is not supported and should not be offered.

Comment thread local/mock/tier2/data.py Outdated
],
"materialNumberSupplier": TIER2_MATERIAL_NUMBER,
"materialGlobalAssetId": _material_global_asset_id(bpnl),
"direction": "OUTBOUND",

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

direction does not exist on production.

Comment thread local/mock/tier2/data.py Outdated

def _delivery(bpnl: str) -> dict:
return {
"deliveries": [

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

positions is missing as an intermediary property.

Comment thread local/mock/participant/data.py
Comment thread local/mock/tier2/data.py Outdated
(DEMAND_ASSET, "urn:samm:io.catenax.short_term_material_demand:1.0.0#ShortTermMaterialDemand", "1.0"),
(DELIVERY_ASSET, "urn:samm:io.catenax.delivery_information:2.0.0#DeliveryInformation", "2.0"),
(DAYS_OF_SUPPLY_ASSET, "urn:samm:io.catenax.days_of_supply:2.0.0#DaysOfSupply", "2.0"),
(NOTIFICATION_ASSET, "urn:samm:io.catenax.demand_and_capacity_notification:3.0.0#DemandAndCapacityNotification", "3.0"),

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Notification is not a submodel.

@gobica
gobica force-pushed the tier-2-mockup-logic branch from 28afac4 to 92cad79 Compare July 14, 2026 13:13
@gobica
gobica requested a review from ReneSchroederLJ July 16, 2026 08:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants