Hi, is there any datahub api service to delete a u...
# ingestion
d
Hi, is there any datahub api service to delete a urn?
i
b
@damp-ambulance-34232 let us know if you have questions using this^
d
@big-carpet-38439 I have some problems when using datahub cli When using cli
Copy code
bash /opt/datahub-0.8.16/metadata-ingestion/scripts/datahub_docker.sh delete --urn urn:li:dataPlatform:postgres,gmap.public.point
datahub delete --urn urn:li:dataPlatform:postgres,gmap.public.point --hard
It connected with service at url: http://localhost:8080 But my service url is mycompany.datahub:8080
So i cant delete a datahub dataset with cli. So i think maybe datahub api let me delete with urn. I added some tricky config to hide a dataset from datahub web
Copy code
transformers:
      - type: "mark_dataset_status"
      config:
          removed: true
b
Hey you can run datahub init
plus1 1
To provide the correct host for datahub’s GMS service
plus1 1
d
Hi @big-carpet-38439, i just re init datahub to connect right datahub service url url datahub dataset https://datahub.mycompany/dataset/urn:li:dataset:(urn:li:dataPlatform:postgres,gmap.public.acls,PROD)/Schema?is_lineage_mode=false But nothing delete
Copy code
datahub delete --urn "urn:li:dataPlatform:postgres,gmap.public.acls,PROD"
This will permanently delete data from DataHub. Do you want to continue? [y/N]: y
Nothing deleted for urn:li:dataPlatform:postgres,gmap.public.acls,PROD
b
@green-football-43791 Can you take a look and assist on this one?
g
Hey @damp-ambulance-34232 it looks like the urn you are trying to delete part of the dataset urn
your full dataset urn is
urn:li:dataset:(urn:li:dataPlatform:postgres,gmap.public.acls,PROD)
notice the prefix and trailing
)
d
@green-football-43791 Tks, i'm able to delete this dataset. But it is nice to have a delete button a dataset in dataset UI
b
Yeah this makes sense!