Skip to content

Commit

Permalink
chore(release): xxx - high scaling part resolving tracex
Browse files Browse the repository at this point in the history
  • Loading branch information
ds-mwesener committed Aug 15, 2024
1 parent d03d1ce commit 0bb3111
Showing 1 changed file with 56 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
@startuml
'https://plantuml.com/sequence-diagram
autonumber
participant TraceXFE
participant TraceX
participant "DiscoveryService" as DS
participant "Eclipse Dataspace Connector" as EDC
participant "Digital Twin Registry" as DTR

participant IRS
rnote right TraceX
Blackbox view on EDC
end rnote
TraceX -> DS: Get EDCS for BPN
DS -> TraceX: Provide EDC Urls
TraceX -> EDC: Query for catalog offer of DTR
EDC -> TraceX: Return catalog offer
TraceX -> EDC: Negotiation of contract
EDC -> TraceX: Complete negotiation
TraceX -> DTR: Query for aasIDs by bpn
DTR -> TraceX: Retrieve aasIDs by bpn
rnote right TraceX
Current state: TraceX requests for each aasID the shellDescriptor via EDC / DTR.
Because we need to know the BOMLifecycle Type (asBuilt/asPlanned) before requesting IRS with the globalAssetId.
Then for each BOMLifecycle Type we do two requests (upward/downward) to the IRS job API
end rnote
rnote right TraceX
Optimization: Since IRS can autodetect the BOMLifecycle Type. TraceX could simply use the aasID to reduce a huge amount of load to the EDC / DTR
Afterwards we switching from the IRS Job API to the IRS Order APi which lets us define batch strategies and call IRS only two times (upward/downward) for all aasIDs
end rnote
TraceX -> IRS: Register order for parts to get semantic models and traversal aspects for all aasIds (e.g. 200.000)
rnote right TraceX
TraceX provides a callback url which will be requested by IRS once a batch of the previous registered order is completed.
This results in multiple callbacks until the full list of aasIDs has been processed by the IRS.
end rnote
TraceX <-- IRS: Receive callback request by IRS including order ID.
rnote right TraceX
Current state: TraceX extracts semantic models and traversal aspects and directly map and persists them into the database
end rnote
TraceX -> TraceX: Store jobIds completed into a separate database table and set status to JOB_COMPLETED
rnote right TraceX
Introducing states to manage data records (JOB_COMPLETED, PERSISTENCE_COMPLETED)
Sequential processing of data records and transitioning them to the correct status.
end rnote
TraceX -> IRS: Jobs within the order of irs will be requested when they have the state JOB_COMPLETED
IRS -> TraceX: Provide associated semantic models and traversal aspects
TraceX -> TraceX: Semantic models and traversal aspects will be extracted, mapped to parts and persisted into database.
TraceX -> TraceX: Update status of new data record table for the completed entry to PERSISTENCE_COMPLETED

rnote right TraceXFE
Expectation: This request assumes that all data processing in TraceX has been completed and the data is available.
end rnote
TraceXFE -> TraceX: Get parts
TraceX -> TraceXFE: List<Parts>

@enduml

0 comments on commit 0bb3111

Please sign in to comment.