From 89fd27548077586def45bbe9f9e893ed6862ac84 Mon Sep 17 00:00:00 2001 From: "miriam.baglioni" Date: Mon, 21 Mar 2022 09:54:45 +0100 Subject: [PATCH] [HostedByMap] added left over from PR and fixed issue on workflow --- .../hostedbymap/download_json_parameters.json | 27 +++++++++++++++++++ .../graph/hostedbymap/oozie_app/download.sh | 3 +++ .../graph/hostedbymap/oozie_app/workflow.xml | 2 +- 3 files changed, 31 insertions(+), 1 deletion(-) create mode 100644 dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/download_json_parameters.json create mode 100644 dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/oozie_app/download.sh diff --git a/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/download_json_parameters.json b/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/download_json_parameters.json new file mode 100644 index 0000000000..72498c4e01 --- /dev/null +++ b/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/download_json_parameters.json @@ -0,0 +1,27 @@ +[ + + { + "paramName":"op", + "paramLongName":"outputPath", + "paramDescription": "the output json file produced by the CSV downlaod procedure", + "paramRequired": true + }, + + { + "paramName": "hnn", + "paramLongName": "hdfsNameNode", + "paramDescription": "the path used to store the HostedByMap", + "paramRequired": true + },{ + "paramName": "cf", + "paramLongName": "compressedFile", + "paramDescription": "the path used to store the HostedByMap", + "paramRequired": true +},{ + "paramName":"wp", + "paramLongName":"workingPath", + "paramDescription": "the output json file produced by the CSV downlaod procedure", + "paramRequired": true +} +] + diff --git a/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/oozie_app/download.sh b/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/oozie_app/download.sh new file mode 100644 index 0000000000..35220bd8c9 --- /dev/null +++ b/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/oozie_app/download.sh @@ -0,0 +1,3 @@ +#!/bin/bash +curl -LSs $1 | hdfs dfs -put - $2/$3 +curl -LSs http://api.crossref.org/works/10.1099/jgv.0.001453 > prova.txt \ No newline at end of file diff --git a/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/oozie_app/workflow.xml b/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/oozie_app/workflow.xml index 1a3261ffbc..c7fffed5b2 100644 --- a/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/oozie_app/workflow.xml +++ b/dhp-workflows/dhp-graph-mapper/src/main/resources/eu/dnetlib/dhp/oa/graph/hostedbymap/oozie_app/workflow.xml @@ -92,7 +92,7 @@ - eu.dnetlib.dhp.oa.graph.hostedbymap.DownloadCSV2 + eu.dnetlib.dhp.oa.graph.hostedbymap.DownloadCSV --hdfsNameNode${nameNode} --fileURL${unibiFileURL} --tmpFile/tmp/unibi_gold_replaced.csv