AtlasOfLivingAustralia / data-management

Data management issue tracking
7 stars 0 forks source link

Implement Delete a DR DAG #890

Closed sadeghim closed 6 months ago

sadeghim commented 1 year ago

here is the jenkins job script:

solrWs="http://solr.ala:8983/solr/biocache/update?commit=true"

for dr in ${datasetIds[@]}
do
    echo "Deleting from solr and pipelines for: $dr"
    #echo "Deleting from pipelines for: $dr"

    curl "$solrWs" -H "Content-Type: text/xml"  --data-binary "<delete><query>dataResourceUid:$dr</query></delete>"

    sudo -u spark /data/hadoop/bin/hdfs dfs -rm -r -f /pipelines-all-datasets/index-record/$dr
    sudo -u spark /data/hadoop/bin/hdfs dfs -rm -r -f /dwca-exports/$dr
    sudo -u spark /data/hadoop/bin/hdfs dfs -rm -r -f /pipelines-data/$dr    
done
peggynewman commented 6 months ago

In prod