egeria
egeria copied to clipboard
[BUG] Issue deleting elements loaded by an archive
Existing/related issue?
No response
Current Behavior
Get an exception when trying to delete an archive.
"class": "VoidResponse",
"relatedHTTPCode": 500,
"exceptionClassName": "org.odpi.openmetadata.frameworks.connectors.ffdc.PropertyServerException",
"actionDescription": "removeGlossary",
"exceptionErrorMessage": "OMAG-REPOSITORY-HANDLER-500-001 An unexpected error org.odpi.openmetadata.repositoryservices.ffdc.exception.InvalidParameterException was returned to removeRelationship by the metadata server during removeGlossary request for open metadata access service Asset Manager OMAS on server DMP_metadataServer; message was OMRS-LOCAL-REPOSITORY-503-010 The local OMRS repository connector DMP_metadataServer has been asked to update relationship 09668c3d-8a92-4488-8fb0-43d96bca284f but it is not the owner.It is not able to complete the deleteRelationship request",
"exceptionErrorMessageId": "OMAG-REPOSITORY-HANDLER-500-001",
"exceptionErrorMessageParameters": [
"OMRS-LOCAL-REPOSITORY-503-010 The local OMRS repository connector DMP_metadataServer has been asked to update relationship 09668c3d-8a92-4488-8fb0-43d96bca284f but it is not the owner.It is not able to complete the deleteRelationship request",
"removeGlossary",
"Asset Manager OMAS",
"DMP_metadataServer",
"org.odpi.openmetadata.repositoryservices.ffdc.exception.InvalidParameterException",
"removeRelationship"
],
"exceptionSystemAction": "The system is unable to process the request because of an internal error.",
"exceptionUserAction": "Verify the sanity of the server. This is probably a logic error. If you can not work out what happened, ask the Egeria community for help."
Expected Behavior
Bye-bye archive
Steps To Reproduce
Try it with Postman
Environment
- Egeria: 4.1 SNAPSHOT
- OS:
- Java:
- Browser (for UI issues):
- Additional connectors and integration:
Any Further Information?
No response
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 20 days if no further activity occurs. Thank you for your contributions.
Hello @mandy-chessell If its OK with you. would like to take a stab at this.
You may, of course :) It requires changes to a number of components to get it to work properly since the problem is in the repository services and testing this area can be chanll. I had not looked into it in detail but this was my initial thoughts.
Design 1:
Basically the request needs to be routed to the repository that is identified by the replicatedBy
property in the instance header. This function needs to be added to the enterprise repository connector in OMRS once it has retrieved the element and decided it is from an archive.
Once the request is correctly routed to the the local connector, the local repository connector needs to pass it on to the real repository connectors to perform the delete. There are three native repository connectors (inmemory, JanusGraph and XTDB) that probably need updating and testing. Once the delete is performed, the local repository connector would send delete events to the other members of the cohort.
Design 2: It may be possible to avoid updating each of the native real repository connectors (inmemory, JanusGraph and XTDB) by calling deleteXXXReferenceCopy. This method does not result in delete events flowing through the cohort. Therefore this request is would need to be orchestrated from the enterprise repository connector once it realizes that the instance to delete is from an archive. The enterprise repository connect would call this method on ever member in the cohort. The local repository connector in each member server would pass the deleteXXXReferenceCopy to the real repository connectors and the archive instance would be deleted as if it was a reference copy.
If this looks too challenging, I quite understand. I had been focussing on other fixes that improved the up-and-running experience since I did not think anyone was waiting for this one. If you need this fix, and would like me to do it, I can move it up my priority list. If you would like something different to work on, I can help you there too.
Ah,, never realized it will be that challenging. If possible I would like to work on something simpler. Its just my 3rd or 4th issue on Egeria. So something that would be appropriate for my level would be good.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 20 days if no further activity occurs. Thank you for your contributions.