删除Atlas元数据进行物理删除

一、问题

想要删除Atlas元数据,Atlas组件默认是逻辑删除,但是我们想要进行物理删除

二、解决

1、修改配置文件

vim /opt/module/atlas/conf/atlas-application.properties

添加如下内容:

#开启物理删除
atlas.DeleteHandlerV1.impl=org.apache.atlas.repository.store.graph.v1.HardDeleteHandlerV1

2、重启Atlas

python2 /opt/module/atlas/bin/atlas_stop.py
python2 /opt/module/atlas/bin/atlas_start.py

3、调用AtlasAPI接口进行删除

如何清除软删除的实体

在Apache Atlas中,有没有办法在启用硬删除后删除/清除软删除的实体?

通过如下API即可达到要求:

Http请求方式:

----------------soft delete----------------

curl -iv -u admin:admin -X DELETE http://localhost:21000/api/atlas/v2/entity/guid/88f13750-f2f9-4e31-89f7-06d313fe5d39

---------------- than hard----------------

curl -i -X PUT  -H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-u admin:admin 'http://loclahost:21000/api/atlas/admin/purge/' \
-d '["88f13750-f2f9-4e31-89f7-06d313fe5d39"]'
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值