Open aviv-julienjehannet opened 1 month ago
hey @aviv-julienjehannet! This is a great point, however this endpoint was only meant to actually create new domains, not upsert or update them. The id
field here allows you to create a domain with a specific ID, so when you call createDomain
with an ID that already exists, you'll get an error because the domain already exists. I see that the docs call this out but I believe those docs are outdated and need to be updated.
Right now your best bet for updating the description of an existing domain using graphql is to use the updateDescription
endpoint passing in the domain urn as the resourceUrn
.
Something we could do to support upserts like this would be to create a new upsertDomain
endpoint which would be more classically named for the expected behavior.
Thank you for taking the time to put this issue together and call out the incorrect docs!
Describe the bug We cannot change domain attributes thru the GraphQL API.
Steps to Reproduce the Issue
Expected Behavior As per the DataHub GraphQL documentation, the existing domain should be overwritten if a domain with the provided ID already exists.
Actual Behavior You receive a 404 error indicating that the domain already exists, which contradicts the expected behavior.
Screenshots
Desktop (please complete the following information):
Additional context Given my DataHub version 0.13.3 and the issue described in GitHub Issue #10084 is still relevant, it appears that the problem persists even though the issue was closed.