Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue Retrieving Lineage with Azure Purview API #291

Open
jguajardobravo opened this issue Aug 6, 2024 · 0 comments
Open

Issue Retrieving Lineage with Azure Purview API #291

jguajardobravo opened this issue Aug 6, 2024 · 0 comments
Labels
purview question A question more about Purview and less about PyApacheAtlas

Comments

@jguajardobravo
Copy link

I am experiencing an issue when trying to retrieve lineage data using the Azure Purview API. I have tried several approaches, but none are working. Below is a snippet of the code I am using:

`# Retrieve complete lineage using the REST API
lineage_guid = "b9205209-..." # Replace with the GUID of the root entity for which you want to retrieve the lineage
url = f'https://{PURVIEW_ACCOUNT_NAME}.purview.azure.com/catalog/api/atlas/v2/lineage/{lineage_guid}?depth=10&direction=BOTH'

response = requests.get(url, headers=headers)

if response.status_code == 200:
lineage_data = response.json()
print("Lineage retrieved...")
print(lineage_data)
print(json.dumps(lineage_data, indent=4))
else:
print(f"Error retrieving lineage: {response.status_code}")
print(response.text)
return`

However, the response I get is as follows:

{ "baseEntityGuid": "b9205209-...", "lineageDirection": "BOTH", "lineageDepth": 10, "lineageWidth": 10, "childrenCount": -1, "guidEntityMap": {}, "includeParent": false, "relations": [], "parentRelations": [], "widthCounts": { "OUTPUT": {}, "INPUT": {} } }

For me, this seems like there might be a permissions issue or a misconfiguration in the lineage options. When I check within Purview, I can see the lineage properly configured:

image

The service principal being used for this purpose is capable of retrieving any information from the glossary. This is the main reason why I think permissions for my service principal are properly set.

Could anyone provide insights on what might be wrong or suggest additional configurations I need to check?

Thank you!

@jguajardobravo jguajardobravo added the purview question A question more about Purview and less about PyApacheAtlas label Aug 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
purview question A question more about Purview and less about PyApacheAtlas
Projects
None yet
Development

No branches or pull requests

1 participant