Repository navigation
Fix Submodel registry unlink swallowing Registry failures - #1077
Merged
aaronzi merged 2 commits intoOct 22, 2026
Merged
Conversation
Submodel deletion no longer checks for the descriptor first. It calls the Registry DELETE directly, treats only 404 as already absent, and keeps the local Submodel for every other Registry failure, matching the AAS Repository behavior from eclipse-basyx#1034. Closes eclipse-basyx#1076
The GitHub ubuntu-24.04 runner image moved to a Linux kernel >= 6.19. mongo:8 (now 8.3.13) and 8.0 refuse to start on such kernels (SERVER-121912), so every MongoDB-backed CI job failed with an unhealthy mongo container. 8.2.12 starts and passes the existing healthcheck.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull Request Template
Description of Changes
With registry integration enabled,
DELETE /submodels/{id}returned 204 when the Submodel Registry could not be reached. Before deleting, the integration checked whether the descriptor existed, and that check treated everyApiExceptionas "does not exist". A connection failure or a 5xx response therefore skipped the Registry DELETE. The Submodel was then deleted locally and its descriptor stayed in the Registry.This applies the change #1034 made on the AAS side:
deleteSubmodelDescriptorByIddirectly, with no existence check first.RepositoryRegistryUnlinkExceptionand keeps the local Submodel. That includes transport errors (code 0), 5xx responses and 403.BaSyxExceptionHandlermaps the exception to 500, which is howDELETE /shells/{id}already behaves.The feature README now describes what happens on a failure.
Related Issue
Closes #1076
BaSyx Configuration for Testing
The new unit tests need no special configuration. They use the in-memory backend and a mocked
SubmodelRegistryApi.The existing service-backed integration tests run unchanged, using the default,
multiurlandauthregistryprofiles.AAS Files Used for Testing
None. The unit tests create their Submodels in code.
Additional Information
New
RegistryIntegrationSubmodelRepositoryTestcovers four cases:On the old code all four tests fail (3 failures, 1 error). With the fix they all pass.
Validation performed:
mvn -pl basyx.submodelrepository/basyx.submodelrepository-feature-registry-integration -Dtest=RegistryIntegrationSubmodelRepositoryTest testNot part of this PR: as the issue notes,
updateSubmodelstill doesn't sync the descriptor to the Registry.CI fix: MongoDB image pinned to 8.2.12
A second commit fixes CI failures that also affect
main. They have nothing to do with the change above. Theubuntu-24.04runner image moved from kernel 6.17 to a newer one. On Linux kernel 6.19 and later,mongo:8(currently 8.3.13) andmongo:8.0exit at startup with "MongoDB cannot start: Linux kernel versions 6.19 and newer has a known incompatibility" (SERVER-121912). As a result, every MongoDB-backed job failed withcontainer mongo is unhealthy.mongo:8.2.12starts and passes the existing healthcheck, so all 15 compose files that usedmongo:8now pin it, including the examples and the registry dev setups. It can go back to a floating tag once MongoDB ships the TCMalloc fix.