Project

General

Profile

« Previous | Next » 

Revision 54942

[maven-release-plugin] copy for tag dnet-validator-workflows-1.1.9

View differences:

modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/deploy.info
1
{
2
	"type_source": "SVN", 
3
	"goal": "package -U source:jar", 
4
	"url": "http://svn-public.driver.research-infrastructures.eu/driver/dnet45/modules/dnet-validator-workflows/trunk", 
5
	"deploy_repository": "dnet45-snapshots", 
6
	"version": "4", 
7
	"mail": "sandro.labruzzo@isti.cnr.it,michele.artini@isti.cnr.it,claudio.atzori@isti.cnr.it,alessia.bardi@isti.cnr.it,andrea.mannocci@isti.cnr.it", 
8
	"deploy_repository_url": "http://maven.research-infrastructures.eu/nexus/content/repositories/dnet45-snapshots", 
9
	"name": "dnet-validator-workflows"
10
}
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/test/java/eu/dnetlib/PatchValidatedRecordTest.java
1
package eu.dnetlib;
2

  
3
import java.io.InputStream;
4

  
5
import org.apache.commons.io.IOUtils;
6
import org.junit.Before;
7
import org.junit.Test;
8

  
9
import eu.dnetlib.miscutils.functional.xml.ApplyXslt;
10

  
11
public class PatchValidatedRecordTest {
12

  
13
	String patchXslt = null;
14
	String validatorRecord = null;
15

  
16
	@Before
17
	public void setUp() throws Exception {
18
		patchXslt = IOUtils.toString(load("/eu/dnetlib/msro/workflows/repo/validation/patchValidationHeader.xsl"));
19
		validatorRecord = IOUtils.toString(load("validator-record.xml"));
20
	}
21

  
22
	@Test
23
	public void test() {
24
		ApplyXslt applyXslt = new ApplyXslt(patchXslt);
25
		String output = applyXslt.evaluate(validatorRecord);
26
		System.out.println(output);
27
	}
28

  
29
	private InputStream load(final String fileName) {
30
		return getClass().getResourceAsStream(fileName);
31
	}
32

  
33
}
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/test/resources/eu/dnetlib/validator-record.xml
1
<validator:result recordId="reposit2:HASH01939420936165b797fbc1ce" score="0" status="fail"
2
    xmlns:validator="http://eu.dnetlib/validator">
3
    <validator:failedRules>
4
        <validator:rule id="109" mandatory="false" name="Field Source (R)"
5
            xpath="//record/metadata//*[name()='dc:source']/text()"/>
6
        <validator:rule id="111" mandatory="false" name="Field Coverage (R)"
7
            xpath="//record/metadata//*[name()='dc:coverage']/text()"/>
8
        <validator:rule id="112" mandatory="false" name="Field Audience (R)"
9
            xpath="//record/metadata//*[name()='dc:audience']/text()"/>
10
        <validator:rule id="116" mandatory="true"
11
            name="Field Project Identifier for ecfundedresources (M)" xpath="$rule.xpath"/>
12
    </validator:failedRules>
13
    <validator:record>
14
        <oai:record xmlns="http://namespace.openaire.eu/"
15
            xmlns:dc="http://purl.org/dc/elements/1.1/"
16
            xmlns:dr="http://www.driver-repository.eu/namespace/dr"
17
            xmlns:dri="http://www.driver-repository.eu/namespace/dri"
18
            xmlns:oai="http://www.openarchives.org/OAI/2.0/"
19
            xmlns:prov="http://www.openarchives.org/OAI/2.0/provenance"
20
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
21
            <oai:header xmlns="">
22
                <dri:objIdentifier>UNLA::0024ba2d80e96b1ca5fd0ad87c80d276</dri:objIdentifier>
23
                <dri:recordIdentifier>reposit2:HASH01939420936165b797fbc1ce</dri:recordIdentifier>
24
                <dri:dateOfCollection>2015-03-25T17:19:24.657+01:00</dri:dateOfCollection>
25
                <dri:repositoryId>a4c4289b-dec2-469e-8da1-ad226714f13a_UmVwb3NpdG9yeVNlcnZpY2VSZXNvdXJjZXMvUmVwb3NpdG9yeVNlcnZpY2VSZXNvdXJjZVR5cGU=</dri:repositoryId>
26
                <dri:datasourceprefix>UNLA</dri:datasourceprefix>
27
                <identifier xmlns="http://www.openarchives.org/OAI/2.0/"
28
                    >reposit2:HASH01939420936165b797fbc1ce</identifier>
29
                <datestamp xmlns="http://www.openarchives.org/OAI/2.0/">2015-03-09</datestamp>
30
                <setSpec xmlns="http://www.openarchives.org/OAI/2.0/">reposit2</setSpec>
31
            </oai:header>
32
            <metadata xmlns="http://www.openarchives.org/OAI/2.0/">
33
                <oai_dc:dc xmlns="" xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
34
                    xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/                               http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
35
                    <dc:creator>Flores Rondón, María del Mar</dc:creator>
36
                    <dc:contributor>Gassibe, Ines</dc:contributor>
37
                    <dc:date>2014</dc:date>
38
                    <dc:description>Fil: Flores Rondón, María del Mar. Universidad Nacional de
39
                        Lanús. Departamento de Planificación y Políticas Públicas. Maestría en
40
                        Políticas Públicas y Gobierno; Argentina</dc:description>
41
                    <dc:format>application/pdf</dc:format>
42
                    <dc:language>spa</dc:language>
43
                    <dc:type>info:eu-repo/semantics/masterThesis</dc:type>
44
                    <dc:type>tesis de maestría</dc:type>
45
                    <dc:type>info:eu-repo/semantics/publishedVersion</dc:type>
46
                    <dc:publisher>Universidad Nacional de Lanús. Departamento de Planificación y
47
                        Políticas Públicas. Maestría en Políticas Públicas y Gobierno</dc:publisher>
48
                    <dc:subject>POLITICAS PUBLICAS</dc:subject>
49
                    <dc:subject>COMUNICACION</dc:subject>
50
                    <dc:subject>POLITICA</dc:subject>
51
                    <dc:subject>SEGURIDAD SOCIAL</dc:subject>
52
                    <dc:title>Política pública de inserción laboral para personas con discapacidad
53
                        auditiva : caso Municipio Libertador del Estado de
54
                        Mérida-Venezuela</dc:title>
55
                    <dc:identifier>http://www.repositoriojmr.unla.edu.ar/descarga/Tesis/MaPPyG/034717_Flores_Rondon.pdf</dc:identifier>
56
                </oai_dc:dc>
57
            </metadata>
58
            <about xmlns="">
59
                <provenance xmlns="http://www.openarchives.org/OAI/2.0/provenance"
60
                    xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/provenance http://www.openarchives.org/OAI/2.0/provenance.xsd">
61
                    <originDescription altered="true" harvestDate="2015-03-25T17:19:24.657+01:00"
62
                        xmlns="">
63
                        <baseURL>http%3A%2F%2Fwww.unla.edu.ar%2Fgreenstone%2Fcgi-bin%2Foaiserver.cgi</baseURL>
64
                        <identifier>reposit2:HASH01939420936165b797fbc1ce</identifier>
65
                        <datestamp>2015-03-09</datestamp>
66
                        <metadataNamespace>http://www.openarchives.org/OAI/2.0/oai_dc/</metadataNamespace>
67
                    </originDescription>
68
                </provenance>
69
            </about>
70
        </oai:record>
71
    </validator:record>
72
</validator:result>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/test/resources/eu/dnetlib/expected-prepared-record.xml
1
<oai:record xmlns:dc="http://purl.org/dc/elements/1.1/"
2
    xmlns:dr="http://www.driver-repository.eu/namespace/dr"
3
    xmlns:dri="http://www.driver-repository.eu/namespace/dri"
4
    xmlns:oai="http://www.openarchives.org/OAI/2.0/"
5
    xmlns:prov="http://www.openarchives.org/OAI/2.0/provenance"
6
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
7
    xmlns:validator="http://eu.dnetlib/validator">
8
    <oai:header xmlns="">
9
        <dri:objIdentifier>UNLA::0024ba2d80e96b1ca5fd0ad87c80d276</dri:objIdentifier>
10
        <dri:recordIdentifier>reposit2:HASH01939420936165b797fbc1ce</dri:recordIdentifier>
11
        <dri:dateOfCollection>2015-03-25T17:19:24.657+01:00</dri:dateOfCollection>
12
        <dri:repositoryId>a4c4289b-dec2-469e-8da1-ad226714f13a_UmVwb3NpdG9yeVNlcnZpY2VSZXNvdXJjZXMvUmVwb3NpdG9yeVNlcnZpY2VSZXNvdXJjZVR5cGU=</dri:repositoryId>
13
        <dri:datasourceprefix>UNLA</dri:datasourceprefix>
14
        <identifier xmlns="http://www.openarchives.org/OAI/2.0/"
15
            >reposit2:HASH01939420936165b797fbc1ce</identifier>
16
        <datestamp xmlns="http://www.openarchives.org/OAI/2.0/">2015-03-09</datestamp>
17
        <setSpec xmlns="http://www.openarchives.org/OAI/2.0/">reposit2</setSpec>
18
        <validator:result score="0" status="fail">
19
            <validator:failedRules>
20
                <validator:rule id="109" mandatory="false" name="Field Source (R)"
21
                    xpath="//record/metadata//*[name()='dc:source']/text()"/>
22
                <validator:rule id="111" mandatory="false" name="Field Coverage (R)"
23
                    xpath="//record/metadata//*[name()='dc:coverage']/text()"/>
24
                <validator:rule id="112" mandatory="false" name="Field Audience (R)"
25
                    xpath="//record/metadata//*[name()='dc:audience']/text()"/>
26
                <validator:rule id="116" mandatory="true"
27
                    name="Field Project Identifier for ecfundedresources (M)" xpath="$rule.xpath"/>
28
            </validator:failedRules>
29
        </validator:result>
30
    </oai:header>
31
    <metadata xmlns="http://www.openarchives.org/OAI/2.0/">
32
        <oai_dc:dc xmlns="" xmlns:oai_dc="http://www.openarchives.org/OAI/2.0/oai_dc/"
33
            xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/oai_dc/ http://www.openarchives.org/OAI/2.0/oai_dc.xsd">
34
            <dc:creator>Flores Rondón, María del Mar</dc:creator>
35
            <dc:contributor>Gassibe, Ines</dc:contributor>
36
            <dc:date>2014</dc:date>
37
            <dc:description>Fil: Flores Rondón, María del Mar. Universidad Nacional de Lanús.
38
                Departamento de Planificación y Políticas Públicas. Maestría en Políticas Públicas y
39
                Gobierno; Argentina</dc:description>
40
            <dc:format>application/pdf</dc:format>
41
            <dc:language>spa</dc:language>
42
            <dc:type>info:eu-repo/semantics/masterThesis</dc:type>
43
            <dc:type>tesis de maestría</dc:type>
44
            <dc:type>info:eu-repo/semantics/publishedVersion</dc:type>
45
            <dc:publisher>Universidad Nacional de Lanús. Departamento de Planificación y Políticas
46
                Públicas. Maestría en Políticas Públicas y Gobierno</dc:publisher>
47
            <dc:subject>POLITICAS PUBLICAS</dc:subject>
48
            <dc:subject>COMUNICACION</dc:subject>
49
            <dc:subject>POLITICA</dc:subject>
50
            <dc:subject>SEGURIDAD SOCIAL</dc:subject>
51
            <dc:title>Política pública de inserción laboral para personas con discapacidad auditiva
52
                : caso Municipio Libertador del Estado de Mérida-Venezuela</dc:title>
53
            <dc:identifier>http://www.repositoriojmr.unla.edu.ar/descarga/Tesis/MaPPyG/034717_Flores_Rondon.pdf</dc:identifier>
54
        </oai_dc:dc>
55
    </metadata>
56
    <about xmlns="">
57
        <provenance xmlns="http://www.openarchives.org/OAI/2.0/provenance"
58
            xsi:schemaLocation="http://www.openarchives.org/OAI/2.0/provenance http://www.openarchives.org/OAI/2.0/provenance.xsd">
59
            <originDescription altered="true" harvestDate="2015-03-25T17:19:24.657+01:00" xmlns="">
60
                <baseURL>http%3A%2F%2Fwww.unla.edu.ar%2Fgreenstone%2Fcgi-bin%2Foaiserver.cgi</baseURL>
61
                <identifier>reposit2:HASH01939420936165b797fbc1ce</identifier>
62
                <datestamp>2015-03-09</datestamp>
63
                <metadataNamespace>http://www.openarchives.org/OAI/2.0/oai_dc/</metadataNamespace>
64
            </originDescription>
65
        </provenance>
66
    </about>
67
</oai:record>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/java/eu/dnetlib/msro/workflows/nodes/validation/SetInfoForValidationJobNode.java
1
package eu.dnetlib.msro.workflows.nodes.validation;
2

  
3
import javax.annotation.Resource;
4

  
5
import com.googlecode.sarasvati.Arc;
6
import com.googlecode.sarasvati.NodeToken;
7
import eu.dnetlib.enabling.is.lookup.rmi.ISLookUpService;
8
import eu.dnetlib.enabling.locators.UniqueServiceLocator;
9
import eu.dnetlib.msro.workflows.nodes.SimpleJobNode;
10
import eu.dnetlib.msro.workflows.util.WorkflowsConstants;
11
import org.apache.commons.logging.Log;
12
import org.apache.commons.logging.LogFactory;
13

  
14
public class SetInfoForValidationJobNode extends SimpleJobNode {
15

  
16
	public static final Log log = LogFactory.getLog(SetInfoForValidationJobNode.class); // NOPMD by marko on 11/24/08 5:02 PM
17

  
18
	@Resource
19
	private UniqueServiceLocator serviceLocator;
20
	private String profileId;
21
	private String providerName;
22
	private String api;
23

  
24
	@Override
25
	protected String execute(final NodeToken token) throws Exception {
26
		token.getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_ID, getProfileId());
27
		token.getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_NAME, getProviderName());
28
		token.getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_INTERFACE, getApi());
29

  
30
		token.getFullEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_ID, getProfileId());
31
		token.getFullEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_NAME, getProviderName());
32
		token.getFullEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_INTERFACE, getApi());
33

  
34
		token.getProcess().getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_ID, getProfileId());
35
		token.getProcess().getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_NAME, getProviderName());
36
		token.getProcess().getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_INTERFACE, getApi());
37

  
38
		final String query = "let $x := /*[.//RESOURCE_IDENTIFIER/@value='" + getProfileId() + "']\n"
39
				+ "return concat($x//DATASOURCE_ORIGINAL_ID/text(), '@@@', $x//EXTRA_FIELDS/FIELD[./key='NamespacePrefix']/value, '@@@', $x//INTERFACE[./@id='"
40
				+ getApi() + "']/BASE_URL/text())";
41

  
42
		final String[] arr = serviceLocator.getService(ISLookUpService.class).getResourceProfileByQuery(query).split("@@@");
43
		final String origId = arr[0].trim();
44
		final String nsPrefix = arr[1].trim();
45
		final String interfaceURL = arr[2].trim();
46

  
47
		token.getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_ORIGINALID, origId);
48
		token.getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_NAMESPACE_PREFIX, nsPrefix);
49
		token.getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_INTERFACE_BASEURL, interfaceURL);
50

  
51
		token.getFullEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_ORIGINALID, origId);
52
		token.getFullEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_NAMESPACE_PREFIX, nsPrefix);
53
		token.getFullEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_INTERFACE_BASEURL, interfaceURL);
54

  
55
		token.getProcess().getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_ORIGINALID, origId);
56
		token.getProcess().getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_NAMESPACE_PREFIX, nsPrefix);
57
		token.getProcess().getEnv().setAttribute(WorkflowsConstants.DATAPROVIDER_INTERFACE_BASEURL, interfaceURL);
58

  
59
		return Arc.DEFAULT_ARC;
60
	}
61

  
62
	public String getProviderName() {
63
		return providerName;
64
	}
65

  
66
	public void setProviderName(final String providerName) {
67
		this.providerName = providerName;
68
	}
69

  
70
	public String getApi() {
71
		return api;
72
	}
73

  
74
	public void setApi(final String api) {
75
		this.api = api;
76
	}
77

  
78
	public String getProfileId() {
79
		return profileId;
80
	}
81

  
82
	public void setProfileId(final String profileId) {
83
		this.profileId = profileId;
84
	}
85
}
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/java/eu/dnetlib/msro/workflows/nodes/validation/ValidatorServiceBlackboardJobNode.java
1
package eu.dnetlib.msro.workflows.nodes.validation;
2

  
3
import javax.annotation.Resource;
4
import javax.xml.bind.annotation.XmlType;
5

  
6
import eu.dnetlib.enabling.datasources.common.Api;
7
import eu.dnetlib.enabling.datasources.common.Datasource;
8
import eu.dnetlib.enabling.datasources.common.DsmException;
9
import eu.dnetlib.enabling.datasources.common.LocalDatasourceManager;
10
import eu.dnetlib.msro.rmi.MSROException;
11
import eu.dnetlib.msro.rmi.MSRORuntimeException;
12
import org.apache.commons.lang.StringUtils;
13
import org.apache.commons.logging.Log;
14
import org.apache.commons.logging.LogFactory;
15

  
16
import com.googlecode.sarasvati.Engine;
17
import com.googlecode.sarasvati.NodeToken;
18

  
19
import eu.dnetlib.data.mdstore.MDStoreService;
20
import eu.dnetlib.data.mdstore.MDStoreServiceException;
21
import eu.dnetlib.enabling.is.lookup.rmi.ISLookUpService;
22
import eu.dnetlib.enabling.locators.UniqueServiceLocator;
23
import eu.dnetlib.enabling.tools.blackboard.BlackboardJob;
24
import eu.dnetlib.miscutils.datetime.DateUtils;
25
import eu.dnetlib.msro.workflows.nodes.BlackboardJobNode;
26
import eu.dnetlib.msro.workflows.nodes.ProgressJobNode;
27
import eu.dnetlib.msro.workflows.nodes.blackboard.BlackboardWorkflowJobListener;
28
import eu.dnetlib.msro.workflows.util.ProgressProvider;
29
import eu.dnetlib.msro.workflows.util.WorkflowsConstants;
30
import org.springframework.beans.factory.annotation.Autowired;
31

  
32
/**
33
 * This node send the BB message to the ValidatorService to validate records from an mdstore.
34
 * <p>
35
 * See ticket https://issue.openaire.research-infrastructures.eu/issues/538 for specs.
36
 * </p>
37
 *
38
 * @author andrea.mannocci, alessia
39
 *
40
 */
41
public class ValidatorServiceBlackboardJobNode extends BlackboardJobNode implements ProgressJobNode, ProgressProvider {
42

  
43
	public static final Log log = LogFactory.getLog(ValidatorServiceBlackboardJobNode.class); // NOPMD by marko on 11/24/08 5:02 PM
44

  
45
	private static final int DEAFULT_WORKERS = 1;
46

  
47
	public static final String VALIDATE_ACTION = "VALIDATE";
48
	public static final String VALIDATION_TYPE = "DNET";
49

  
50
	public static final String VALIDATOR_EPR_PARAM_NAME = "outputResultSetEpr";
51

  
52
	private String xQueryForValidatorServiceId;
53
	private String outputEprName = VALIDATOR_EPR_PARAM_NAME;
54

  
55
	// VALIDATOR JOB PARAM VALUES
56
	private String mdstoreId;
57
	private String guidelines;
58
	private String blacklistRuleName;
59
	private String recordsSampleSize;
60
	/** Json key-value map of other parameters that will be stored in the validator back-end as they are. **/
61
	private String extraParams;
62

  
63
	/** True to ask the validator to generate the output EPR. **/
64
	private boolean shouldOutputRecords = false;
65
	/** True to ask the validator to update the blacklist. **/
66
	private boolean shouldUpdateBlacklist = true;
67

  
68
	private int workers = DEAFULT_WORKERS;
69

  
70
	@Resource
71
	private UniqueServiceLocator serviceLocator;
72

  
73
	@Autowired
74
	private LocalDatasourceManager<Datasource<?, ?>, Api<?>> dsManager;
75

  
76
	/** Number of records after which the Validator must update its progress status in currentlyValidatedParam **/
77
	private int jobStatusUpdateInterval = 1000;
78
	/** Parameter where the validator tells how many records have been processed sofar **/
79
	private String currentlyValidatedParam = "recordsTested";
80
	/** Number of records validated so far. **/
81
	private int currentlyValidated = 0;
82
	private int total = 0;
83
	private boolean accurate;
84

  
85
	/**
86
	 * <p>
87
	 * Parameters to set for the VALIDATE BB job:
88
	 *
89
	 * <pre>
90
	 *     <PARAMETER name="type" value="DNET"/>
91
	 *     <PARAMETER name="guidelines" value="openaire3.0"/> //values: openaire3.0, openaire2.0, openaire2.0_data, driver
92
	 *     <PARAMETER name="records" value="#records"/> //OPTIONAL
93
	 *     <PARAMETER name="blacklistedRecords" value="true"/> //enables the feature to keep blacklisted records. Default is true.
94
	 *     <PARAMETER name="blacklistGuidelines" value="blacklist_ruleset"/> //optional. values: name of the ruleset (as created from the validator admin panel) to use to generate the blacklist. Default value is the value in "guidelines".
95
	 *     <PARAMETER name="datasourceID" value=""/>
96
	 *     <PARAMETER name="datasourceName" value=""/> //OPTIONAL
97
	 *     <PARAMETER name="datasourceNamespacePrefix" value=""/> //OPTIONAL
98
	 *     <PARAMETER name="interfaceId" value=" "/>
99
	 *     <PARAMETER name="baseUrl" value=""/> //OPTIONAL
100
	 *     <PARAMETER name="mdstoreId" value=" "/>
101
	 *     <PARAMETER name="outputEpr" value="boolean"/> //TRUE to get the EPR of validated records. Default is false.
102
	 *     <PARAMETER name="extraParams" value="json key-value map"/> //OPTIONAL
103
	 *     <PARAMETER name="submissionDate" value="YYYY-MM-DD HH24:MI:SS"/>
104
	 * </pre>
105
	 *
106
	 * </p>
107
	 * {@inheritDoc}
108
	 *
109
	 * @see eu.dnetlib.msro.workflows.nodes.BlackboardJobNode#prepareJob(eu.dnetlib.enabling.tools.blackboard.BlackboardJob,
110
	 *      com.googlecode.sarasvati.NodeToken)
111
	 */
112
	@Override
113
	protected void prepareJob(final BlackboardJob job, final NodeToken token) throws Exception {
114

  
115
		job.setAction(VALIDATE_ACTION);
116
		job.getParameters().put("type", VALIDATION_TYPE);
117
		job.getParameters().put("guidelines", guidelines);
118
		job.getParameters().put("records", getRecordsSampleSize());
119
		// params for blacklist
120
		job.getParameters().put("blacklistedRecords", isShouldUpdateBlacklist() + "");
121
		if (isShouldUpdateBlacklist()) {
122
			job.getParameters().put("blacklistGuidelines", blacklistRuleName);
123
		}
124

  
125
		// datasource params
126
		final String datasourceId = token.getFullEnv().getAttribute(WorkflowsConstants.DATAPROVIDER_ORIGINALID);
127
		final String api = token.getFullEnv().getAttribute(WorkflowsConstants.DATAPROVIDER_INTERFACE);
128
		job.getParameters().put("datasourceId", datasourceId);
129
		job.getParameters().put("datasourceName", token.getFullEnv().getAttribute(WorkflowsConstants.DATAPROVIDER_NAME));
130
		job.getParameters().put("datasourceNamespacePrefix", token.getFullEnv().getAttribute(WorkflowsConstants.DATAPROVIDER_NAMESPACE_PREFIX));
131

  
132
		job.getParameters().put("interfaceId", api);
133
		job.getParameters().put("baseUrl", token.getFullEnv().getAttribute(WorkflowsConstants.DATAPROVIDER_INTERFACE_BASEURL));
134
		job.getParameters().put("mdstoreId", mdstoreId);
135
		job.getParameters().put("workers", String.valueOf(getWorkers()));
136

  
137
		// output params
138
		job.getParameters().put("outputEpr", isShouldOutputRecords() + "");
139
		// extra params
140
		if (StringUtils.isNotBlank(extraParams)) {
141
			job.getParameters().put("extraParams", extraParams);
142
		}
143

  
144
		// Setting properties for the progress bar
145
		if (StringUtils.isBlank(getRecordsSampleSize()) || getRecordsSampleSize().equalsIgnoreCase("ALL")) {
146
			total = getTotal();
147
		} else {
148
			total = Integer.getInteger(getRecordsSampleSize());
149
		}
150
		if (jobStatusUpdateInterval > 0) {
151
			job.getParameters().put("jobStatusUpdateInterval", "" + jobStatusUpdateInterval);
152
		}
153

  
154
		log.debug("*****Launching validation with the following parameters:****");
155
		log.debug("Datasource id: " + datasourceId);
156
		log.debug("API: " + api);
157
		log.debug("Total records: " + total);
158
		log.debug("Number of records to validate: " + getRecordsSampleSize());
159
		log.debug("jobStatusUpdateInterval (set only if > 0, wf default is 1000, validator's default is 100): " + jobStatusUpdateInterval);
160

  
161
		job.getParameters().put("submissionDate", DateUtils.now_ISO8601());
162
	}
163

  
164
	private int getTotal() {
165
		int size = -1;
166
		accurate = false;
167
		try {
168
			if (StringUtils.isBlank(getRecordsSampleSize()) || getRecordsSampleSize().equalsIgnoreCase("ALL")) {
169
				size = serviceLocator.getService(MDStoreService.class).size(mdstoreId);
170
				accurate = true;
171
			} else {
172
				total = Integer.parseInt(getRecordsSampleSize());
173
				accurate = true;
174
			}
175
		} catch (final MDStoreServiceException e) {
176
			log.warn("Can't get size of mdstore " + mdstoreId + " progress will be INACCURATE");
177
			e.printStackTrace();
178
		} catch (final NumberFormatException e) {
179
			log.warn("The parameter recordSampleSize is invalid: progress will be INACCURATE");
180
			e.printStackTrace();
181

  
182
		}
183
		return size;
184
	}
185

  
186
	/**
187
	 * <p>
188
	 * Parameters in the VALIDATE BB job response:
189
	 *
190
	 * <pre>
191
	 * <PARAMETER name="error" value=""/>
192
	 * <PARAMETER name="outputResultSetEpr" value=""/> //only if isShouldOutputRecords() == true
193
	 * <PARAMETER name="jobId" value=""/>
194
	 * </pre>
195
	 *
196
	 * </p>
197
	 *
198
	 *
199
	 * {@inheritDoc}
200
	 *
201
	 * @see eu.dnetlib.msro.workflows.nodes.BlackboardJobNode#generateBlackboardListener(com.googlecode.sarasvati.Engine,
202
	 *      com.googlecode.sarasvati.NodeToken)
203
	 */
204
	@Override
205
	protected BlackboardWorkflowJobListener generateBlackboardListener(final Engine engine, final NodeToken token) {
206
		return new BlackboardWorkflowJobListener(engine, token) {
207

  
208
			boolean eprFound = false;
209

  
210
			@Override
211
			protected void onDone(final BlackboardJob job) {
212

  
213
				log.debug("If you see this log you are not asking to get the validated EPR...");
214

  
215
				final String jobId = job.getParameters().get("jobId");
216

  
217
				token.getEnv().setAttribute("validatorJobId", jobId);
218
				final String error = job.getParameters().get("error");
219
				if (StringUtils.isNotBlank(error)) {
220
					token.getEnv().setAttribute("validatorError", error);
221
				}
222

  
223
				final String dsId = token.getFullEnv().getAttribute(WorkflowsConstants.DATAPROVIDER_ORIGINALID);
224
				final String ifaceId = token.getFullEnv().getAttribute(WorkflowsConstants.DATAPROVIDER_INTERFACE);
225

  
226
				try {
227
					dsManager.setLastValidationJob(dsId, ifaceId, jobId);
228
				} catch (final Throwable e) {
229
					final String msg = String.format("Error setting last_validation_job field, BB jobId '%s'", job.getId());
230
					log.error(msg, e);
231
					job.setError(msg);
232
					super.onFailed(job);
233
					throw new MSRORuntimeException(msg, e);
234
				}
235
				
236
				super.onDone(job);
237
			}
238

  
239
			@Override
240
			protected void onOngoing(final BlackboardJob job) {
241
				currentlyValidated = Integer.parseInt(job.getParameters().get(currentlyValidatedParam));
242
				if (isShouldOutputRecords() & !eprFound) {
243
					final String epr = job.getParameters().get(VALIDATOR_EPR_PARAM_NAME);
244
					log.fatal(VALIDATOR_EPR_PARAM_NAME + "= " + epr);
245
					token.getEnv().setAttribute(outputEprName, epr);
246
					eprFound = true;
247
				}
248
				super.onOngoing(job);
249
			}
250

  
251
		};
252

  
253
	}
254

  
255
	@Override
256
	protected String obtainServiceId(final NodeToken token) {
257
		try {
258
			return getServiceLocator().getService(ISLookUpService.class).getResourceProfileByQuery(xQueryForValidatorServiceId);
259
		} catch (final Exception e) {
260
			throw new RuntimeException(e);
261
		}
262
	}
263

  
264
	@Override
265
	public ProgressProvider getProgressProvider() {
266
		return this;
267
	}
268

  
269
	@Override
270
	public int getTotalValue() {
271
		return total;
272
	}
273

  
274
	@Override
275
	public int getCurrentValue() {
276
		return currentlyValidated;
277
	}
278

  
279
	@Override
280
	public boolean isInaccurate() {
281
		return !accurate;
282
	}
283

  
284
	public String getGuidelines() {
285
		return guidelines;
286
	}
287

  
288
	public void setGuidelines(final String guidelines) {
289
		this.guidelines = guidelines;
290
	}
291

  
292
	public String getRecordsSampleSize() {
293
		return recordsSampleSize;
294
	}
295

  
296
	public void setRecordsSampleSize(final String recordsSampleSize) {
297
		this.recordsSampleSize = recordsSampleSize;
298
	}
299

  
300
	public String getMdstoreId() {
301
		return mdstoreId;
302
	}
303

  
304
	public void setMdstoreId(final String mdstoreId) {
305
		this.mdstoreId = mdstoreId;
306
	}
307

  
308
	public String getExtra_param() {
309
		return extraParams;
310
	}
311

  
312
	public void setExtra_param(final String extra_param) {
313
		this.extraParams = extra_param;
314
	}
315

  
316
	public String getxQueryForValidatorServiceId() {
317
		return xQueryForValidatorServiceId;
318
	}
319

  
320
	public void setxQueryForValidatorServiceId(final String xQueryForValidatorServiceId) {
321
		this.xQueryForValidatorServiceId = xQueryForValidatorServiceId;
322
	}
323

  
324
	public String getOutputEprName() {
325
		return outputEprName;
326
	}
327

  
328
	public void setOutputEprName(final String outputEprName) {
329
		this.outputEprName = outputEprName;
330
	}
331

  
332
	public String getExtraParams() {
333
		return extraParams;
334
	}
335

  
336
	public void setExtraParams(final String extraParams) {
337
		this.extraParams = extraParams;
338
	}
339

  
340
	public String getCurrentlyValidatedParam() {
341
		return currentlyValidatedParam;
342
	}
343

  
344
	public void setCurrentlyValidatedParam(final String currentlyValidatedParam) {
345
		this.currentlyValidatedParam = currentlyValidatedParam;
346
	}
347

  
348
	public int getJobStatusUpdateInterval() {
349
		return jobStatusUpdateInterval;
350
	}
351

  
352
	public void setJobStatusUpdateInterval(final int jobStatusUpdateInterval) {
353
		this.jobStatusUpdateInterval = jobStatusUpdateInterval;
354
	}
355

  
356
	public int getCurrentlyValidated() {
357
		return currentlyValidated;
358
	}
359

  
360
	public void setCurrentlyValidated(final int currentlyValidated) {
361
		this.currentlyValidated = currentlyValidated;
362
	}
363

  
364
	public boolean isShouldOutputRecords() {
365
		return shouldOutputRecords;
366
	}
367

  
368
	public void setShouldOutputRecords(final boolean shouldOutputRecords) {
369
		this.shouldOutputRecords = shouldOutputRecords;
370
	}
371

  
372
	public boolean isShouldUpdateBlacklist() {
373
		return shouldUpdateBlacklist;
374
	}
375

  
376
	public void setShouldUpdateBlacklist(final boolean shouldUpdateBlacklist) {
377
		this.shouldUpdateBlacklist = shouldUpdateBlacklist;
378
	}
379

  
380
	public String getBlacklistRuleName() {
381
		return blacklistRuleName;
382
	}
383

  
384
	public void setBlacklistRuleName(final String blacklistRuleName) {
385
		this.blacklistRuleName = blacklistRuleName;
386
	}
387

  
388
	public int getWorkers() {
389
		return workers;
390
	}
391

  
392
	public void setWorkers(int workers) {
393
		this.workers = workers;
394
	}
395
}
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/resources/eu/dnetlib/test/profiles/workflows/repo-hi-validation-nostore.xml
1
<?xml version="1.0" encoding="UTF-8"?>
2
<RESOURCE_PROFILE xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
3
	<HEADER>
4
		<RESOURCE_IDENTIFIER value="0de2924a-f0f2-436c-8416-0df87e5bb073_V29ya2Zsb3dEU1Jlc291cmNlcy9Xb3JrZmxvd0RTUmVzb3VyY2VUeXBl" />
5
		<RESOURCE_TYPE value="WorkflowDSResourceType" />
6
		<RESOURCE_KIND value="WorkflowDSResources" />
7
		<RESOURCE_URI value="value3" />
8
		<DATE_OF_CREATION value="2015-07-16T18:13:51.0Z" />
9
	</HEADER>
10
	<BODY>
11
		<WORKFLOW_NAME>Collection, validation (no stored records), and transformation</WORKFLOW_NAME>
12
		<WORKFLOW_TYPE>REPO_HI</WORKFLOW_TYPE>
13
		<WORKFLOW_PRIORITY>20</WORKFLOW_PRIORITY>
14
		<CONFIGURATION start="manual">
15
			<NODE name="VerifyDatasource" type="VerifyDatasource" isStart="true">
16
				<DESCRIPTION>Verify if DS is pending</DESCRIPTION>
17
				<PARAMETERS>
18
					<PARAM name="expectedInterfaceTypologyPrefixes" managedBy="system" required="false" type="string"/>
19
					<PARAM name="expectedCompliancePrefixes" managedBy="system" required="false" type="string">metadata</PARAM>
20
				</PARAMETERS>
21
				<ARCS>
22
					<ARC to="createMetaWf"/>
23
					<ARC to="validateDs" name="validateDs"/>
24
				</ARCS>
25
			</NODE>
26
		
27
			<NODE name="validateDs" type="ValidateDatasource">
28
				<DESCRIPTION>Validate DS</DESCRIPTION>
29
				<PARAMETERS/>
30
				<ARCS>
31
					<ARC to="createMetaWf"/>
32
				</ARCS>
33
			</NODE>
34
			
35
			<NODE name="createMetaWf" type="RegisterMetaWf">
36
				<DESCRIPTION>Create MetaWorkflow</DESCRIPTION>
37
				<PARAMETERS>
38
					<PARAM name="wfName" managedBy="system" required="true" type="string">Collection, validation (no stored records), and transformation</PARAM>
39
				</PARAMETERS>
40
				<ARCS>
41
					<ARC to="createNative"/>
42
					<ARC to="createTransformed"/>
43
					<ARC to="prepareCreateIndex"/>
44
				</ARCS>
45
			</NODE>
46
			
47
			<NODE name="createNative" type="CreateMDStore">
48
				<DESCRIPTION>Create native store</DESCRIPTION>
49
				<PARAMETERS>
50
					<PARAM name="format" managedBy="system" required="true" type="string">DMF</PARAM>
51
					<PARAM name="interpretation" managedBy="system" required="true" type="string">native</PARAM>
52
					<PARAM name="layout" managedBy="system" required="true" type="string">store</PARAM>
53
					<PARAM name="outputPrefix" managedBy="system" required="true" type="string">coll_</PARAM>
54
				</PARAMETERS>
55
				<ARCS>
56
					<ARC to="updateMetaWf" />
57
				</ARCS>
58
			</NODE>
59
			
60
			<NODE name="createTransformed" type="CreateMDStore">
61
				<DESCRIPTION>Create transformed store</DESCRIPTION>
62
				<PARAMETERS>
63
					<PARAM name="format" managedBy="system" required="true" type="string">DMF</PARAM>
64
					<PARAM name="interpretation" managedBy="system" required="true" type="string">transformed</PARAM>
65
					<PARAM name="layout" managedBy="system" required="true" type="string">store</PARAM>
66
					<PARAM name="outputPrefix" managedBy="system" required="true" type="string">tran_</PARAM>
67
				</PARAMETERS>
68
				<ARCS>
69
					<ARC to="updateMetaWf" />
70
				</ARCS>
71
			</NODE>
72
			
73
			<NODE name="prepareCreateIndex" type="PrepareCreateIndex">
74
				<DESCRIPTION>Prepare create index</DESCRIPTION>
75
				<PARAMETERS>
76
					<PARAM name="format" managedBy="system" required="true" type="string">DMF</PARAM>
77
					<PARAM name="interpretation" managedBy="system" required="true" type="string">transformed</PARAM>
78
					<PARAM name="layout" managedBy="system" required="true" type="string">index</PARAM>
79
				</PARAMETERS>
80
				<ARCS>
81
					<ARC to="createIndex" />
82
				</ARCS>
83
			</NODE>	
84
			
85
			<NODE name="createIndex" type="CreateIndex">
86
				<DESCRIPTION>Create index</DESCRIPTION>
87
				<PARAMETERS>
88
					<PARAM name="outputPrefix" managedBy="system" required="true" type="string">index_</PARAM>
89
				</PARAMETERS>
90
				<ARCS>
91
					<ARC to="updateMetaWf" />
92
				</ARCS>
93
			</NODE>		
94
						
95
			<NODE name="updateMetaWf" type="UpdateMetaWf" isJoin="true">
96
				<DESCRIPTION>Create MetaWorkflow</DESCRIPTION>
97
				<PARAMETERS>
98
					<PARAM name="beanName" managedBy="system" required="true" type="string">metaWfHiValidatorAsStepNoStore</PARAM>
99
				</PARAMETERS>
100
				<ARCS>
101
					<ARC to="updateMetaWfStatus" />
102
				</ARCS>
103
			</NODE>
104
			
105
			<NODE name="updateMetaWfStatus" type="UpdateMetaWfStatus">
106
				<DESCRIPTION>Update MetaWorkflow Status</DESCRIPTION>
107
				<PARAMETERS />
108
				<ARCS>
109
					<ARC to="success" />
110
				</ARCS>
111
			</NODE>
112
		
113
		</CONFIGURATION>
114

  
115
		<STATUS />
116
	</BODY>
117
</RESOURCE_PROFILE>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/resources/eu/dnetlib/test/profiles/workflows/repo-hi-validatorAsStep.xml
1
<?xml version="1.0" encoding="UTF-8"?>
2
<RESOURCE_PROFILE xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
3
	<HEADER>
4
		<RESOURCE_IDENTIFIER value="b1bb171a-6c7f-41ff-92e9-a992170cdc7d_V29ya2Zsb3dEU1Jlc291cmNlcy9Xb3JrZmxvd0RTUmVzb3VyY2VUeXBl" />
5
		<RESOURCE_TYPE value="WorkflowDSResourceType" />
6
		<RESOURCE_KIND value="WorkflowDSResources" />
7
		<RESOURCE_URI value="value3" />
8
		<DATE_OF_CREATION value="2006-05-04T18:13:51.0Z" />
9
	</HEADER>
10
	<BODY>
11
		<WORKFLOW_NAME>Collection, validation and transformation</WORKFLOW_NAME>
12
		<WORKFLOW_TYPE>REPO_HI</WORKFLOW_TYPE>
13
		<WORKFLOW_PRIORITY>20</WORKFLOW_PRIORITY>
14
		<CONFIGURATION start="manual">
15
			<NODE name="VerifyDatasource" type="VerifyDatasource" isStart="true">
16
				<DESCRIPTION>Verify if DS is pending</DESCRIPTION>
17
				<PARAMETERS>
18
					<PARAM name="expectedInterfaceTypologyPrefixes" managedBy="system" required="false" type="string"/>
19
					<PARAM name="expectedCompliancePrefixes" managedBy="system" required="false" type="string">metadata</PARAM>
20
				</PARAMETERS>
21
				<ARCS>
22
					<ARC to="createMetaWf"/>
23
					<ARC to="validateDs" name="validateDs"/>
24
				</ARCS>
25
			</NODE>
26
		
27
			<NODE name="validateDs" type="ValidateDatasource">
28
				<DESCRIPTION>Validate DS</DESCRIPTION>
29
				<PARAMETERS/>
30
				<ARCS>
31
					<ARC to="createMetaWf"/>
32
				</ARCS>
33
			</NODE>
34
			
35
			<NODE name="createMetaWf" type="RegisterMetaWf">
36
				<DESCRIPTION>Create MetaWorkflow</DESCRIPTION>
37
				<PARAMETERS>
38
					<PARAM name="wfName" managedBy="system" required="true" type="string">Collection, validation and transformation</PARAM>
39
				</PARAMETERS>
40
				<ARCS>
41
					<ARC to="createNative"/>
42
					<ARC to="createTransformed"/>
43
					<ARC to="createValidated"/>
44
					<ARC to="prepareCreateIndex"/>
45
				</ARCS>
46
			</NODE>
47
			
48
			<NODE name="createNative" type="CreateMDStore">
49
				<DESCRIPTION>Create native store</DESCRIPTION>
50
				<PARAMETERS>
51
					<PARAM name="format" managedBy="system" required="true" type="string">DMF</PARAM>
52
					<PARAM name="interpretation" managedBy="system" required="true" type="string">native</PARAM>
53
					<PARAM name="layout" managedBy="system" required="true" type="string">store</PARAM>
54
					<PARAM name="outputPrefix" managedBy="system" required="true" type="string">coll_</PARAM>
55
				</PARAMETERS>
56
				<ARCS>
57
					<ARC to="updateMetaWf" />
58
				</ARCS>
59
			</NODE>
60
			
61
			<NODE name="createTransformed" type="CreateMDStore">
62
				<DESCRIPTION>Create transformed store</DESCRIPTION>
63
				<PARAMETERS>
64
					<PARAM name="format" managedBy="system" required="true" type="string">DMF</PARAM>
65
					<PARAM name="interpretation" managedBy="system" required="true" type="string">transformed</PARAM>
66
					<PARAM name="layout" managedBy="system" required="true" type="string">store</PARAM>
67
					<PARAM name="outputPrefix" managedBy="system" required="true" type="string">tran_</PARAM>
68
				</PARAMETERS>
69
				<ARCS>
70
					<ARC to="updateMetaWf" />
71
				</ARCS>
72
			</NODE>
73
			
74
			<NODE name="createValidated" type="CreateMDStore">
75
				<DESCRIPTION>Create validated store</DESCRIPTION>
76
				<PARAMETERS>
77
					<PARAM name="format" managedBy="system" required="true" type="string">DMF</PARAM>
78
					<PARAM name="interpretation" managedBy="system" required="true" type="string">validated</PARAM>
79
					<PARAM name="layout" managedBy="system" required="true" type="string">store</PARAM>
80
					<PARAM name="outputPrefix" managedBy="system" required="true" type="string">val_</PARAM>
81
				</PARAMETERS>
82
				<ARCS>
83
					<ARC to="updateMetaWf" />
84
				</ARCS>
85
			</NODE>
86
			
87
			<NODE name="prepareCreateIndex" type="PrepareCreateIndex">
88
				<DESCRIPTION>Prepare create index</DESCRIPTION>
89
				<PARAMETERS>
90
					<PARAM name="format" managedBy="system" required="true" type="string">DMF</PARAM>
91
					<PARAM name="interpretation" managedBy="system" required="true" type="string">transformed</PARAM>
92
					<PARAM name="layout" managedBy="system" required="true" type="string">index</PARAM>
93
				</PARAMETERS>
94
				<ARCS>
95
					<ARC to="createIndex" />
96
				</ARCS>
97
			</NODE>	
98
			
99
			<NODE name="createIndex" type="CreateIndex">
100
				<DESCRIPTION>Create index</DESCRIPTION>
101
				<PARAMETERS>
102
					<PARAM name="outputPrefix" managedBy="system" required="true" type="string">index_</PARAM>
103
				</PARAMETERS>
104
				<ARCS>
105
					<ARC to="updateMetaWf" />
106
				</ARCS>
107
			</NODE>		
108
						
109
			<NODE name="updateMetaWf" type="UpdateMetaWf" isJoin="true">
110
				<DESCRIPTION>Create MetaWorkflow</DESCRIPTION>
111
				<PARAMETERS>
112
					<PARAM name="beanName" managedBy="system" required="true" type="string">metaWfHiValidatorAsStep</PARAM>
113
				</PARAMETERS>
114
				<ARCS>
115
					<ARC to="updateMetaWfStatus" />
116
				</ARCS>
117
			</NODE>
118
			
119
			<NODE name="updateMetaWfStatus" type="UpdateMetaWfStatus">
120
				<DESCRIPTION>Update MetaWorkflow Status</DESCRIPTION>
121
				<PARAMETERS />
122
				<ARCS>
123
					<ARC to="success" />
124
				</ARCS>
125
			</NODE>
126
		
127
		</CONFIGURATION>
128

  
129
		<STATUS />
130
	</BODY>
131
</RESOURCE_PROFILE>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/resources/eu/dnetlib/msro/workflows/repo/validation/transform-validated.wf.st
1
<NODE name="SET_INFO" isStart="true" type="SetProviderInfo">
2
	<DESCRIPTION>Retrieve information about current Content Provider</DESCRIPTION>
3
	<PARAMETERS>
4
		<PARAM required="true" type="string" name="providerId" managedBy="system">$params.("dataprovider:id")$</PARAM>
5
		<PARAM required="true" type="string" name="providerName" managedBy="system">$params.("dataprovider:name")$</PARAM>
6
		<PARAM required="true" type="string" name="api" managedBy="system">$params.("dataprovider:interface")$</PARAM>
7
	</PARAMETERS>
8
	<ARCS>
9
		<ARC to="selectStoreToFetch"/>
10
	</ARCS>
11
</NODE>
12
<NODE name="selectStoreToFetch" type="Selection">
13
	<DESCRIPTION>Which records do you want to transform?</DESCRIPTION>
14
	<PARAMETERS>
15
		<PARAM function="validValues(['VALIDATED_RECORDS', 'NATIVE_RECORDS'])" managedBy="user" name="selection" required="true" type="string">VALIDATED_RECORDS</PARAM>
16
	</PARAMETERS>
17
	<ARCS>
18
		<ARC name="VALIDATED_RECORDS" to="fetchValidatedRecords" />
19
		<ARC name="NATIVE_RECORDS" to="fetchNativeRecords" />
20
	</ARCS>
21
</NODE>
22
<NODE name="fetchNativeRecords" type="FetchMDStoreRecords">
23
	<DESCRIPTION>Fetch records from native MDStore</DESCRIPTION>
24
	<PARAMETERS>
25
		<PARAM required="true" type="string" name="mdId" managedBy="system" category="MDSTORE_ID">$params.("coll_id")$</PARAM>
26
		<PARAM required="true" type="string" name="mdFormat" managedBy="system">$params.("coll_format")$</PARAM>
27
		<PARAM required="true" type="string" name="eprParam" managedBy="system">epr_for_transformator</PARAM>
28
	</PARAMETERS>
29
	<ARCS>
30
		<ARC to="transformRecords"/>
31
	</ARCS>
32
</NODE>
33
<NODE name="fetchValidatedRecords" type="FetchMDStoreRecords">
34
	<DESCRIPTION>Fetch records from validated MDStore</DESCRIPTION>
35
	<PARAMETERS>
36
		<PARAM required="true" type="string" name="mdId" managedBy="system" category="MDSTORE_ID">$params.("val_id")$</PARAM>
37
		<PARAM required="true" type="string" name="mdFormat" managedBy="system">$params.("coll_format")$</PARAM>
38
		<PARAM required="true" type="string" name="eprParam" managedBy="system">validated_epr</PARAM>
39
	</PARAMETERS>
40
	<ARCS>
41
		<ARC to="prepareValidatedRecords"/>
42
	</ARCS>
43
</NODE>
44
<NODE name="prepareValidatedRecords" type="ApplyXslt">
45
	<DESCRIPTION>Prepare validated records for transformation</DESCRIPTION>
46
	<PARAMETERS>
47
		<PARAM required="true" type="string" name="inputEprParam" managedBy="system">validated_epr</PARAM>
48
		<PARAM required="true" type="string" name="outputEprParam" managedBy="system">epr_for_transformator</PARAM>
49
		<PARAM required="true" type="string" name="xsltClasspath" managedBy="user">/eu/dnetlib/msro/workflows/repo/validation/patchValidationHeader.xsl</PARAM></PARAMETERS>
50
	<ARCS>
51
		<ARC to="transformRecords"/>
52
	</ARCS>
53
</NODE>
54
<NODE name="transformRecords" type="Transform">
55
	<DESCRIPTION>Transform records</DESCRIPTION>
56
	<PARAMETERS>
57
		<PARAM required="true" type="string" name="inputEprParam" managedBy="system">epr_for_transformator</PARAM>
58
		<PARAM required="true" type="string" name="outputEprParam" managedBy="system">transformed_epr</PARAM>
59
		<PARAM required="true" type="string" name="ruleId" managedBy="user" function="listProfiles('TransformationRuleDSResourceType', '//TITLE')" category="TRANSFORMATION_RULE_ID"  />
60
	</PARAMETERS>
61
	<ARCS>
62
		<ARC to="storeRecords"/>
63
	</ARCS>
64
</NODE>
65

  
66
<NODE name="storeRecords" type="StoreMDStoreRecords">
67
	<DESCRIPTION>Store records into mdstore</DESCRIPTION>
68
	<PARAMETERS>
69
		<PARAM required="true" type="string" name="mdId" managedBy="system" category="MDSTORE_ID">$params.("tran_id")$</PARAM>
70
		<PARAM required="true" type="string" name="storingType" managedBy="system">REFRESH</PARAM>
71
		<PARAM required="true" type="string" name="eprParam" managedBy="system">transformed_epr</PARAM>
72
	</PARAMETERS>
73
	<ARCS>
74
		<ARC to="UPDATE_INFO"/>
75
	</ARCS>
76
</NODE>
77

  
78
<NODE name="UPDATE_INFO" type="MDStoreToApiExtraField">
79
	<DESCRIPTION>Update datasource API extra fields</DESCRIPTION>
80
	<PARAMETERS>
81
		<PARAM required="true" type="string" name="mdId" managedBy="system">$params.("tran_id")$</PARAM>
82
		<PARAM required="true" type="string" name="datasourceId" managedBy="system">$params.("dataprovider:id")$</PARAM>
83
		<PARAM required="true" type="string" name="datasourceInterface" managedBy="system">$params.("dataprovider:interface")$</PARAM>
84
		<PARAM required="true" type="string" name="extraFieldForTotal" managedBy="system">last_aggregation_total</PARAM>
85
		<PARAM required="true" type="string" name="extraFieldForDate" managedBy="system">last_aggregation_date</PARAM>
86
		<PARAM required="true" type="string" name="extraFieldForMdId" managedBy="system">last_aggregation_mdId</PARAM>
87
	</PARAMETERS>
88
	<ARCS>
89
		<ARC to="success"/>
90
	</ARCS>
91
</NODE>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/resources/eu/dnetlib/msro/workflows/repo/validation/patchValidationHeader.xsl
1
<xsl:stylesheet xmlns:xsl="http://www.w3.org/1999/XSL/Transform"
2
    xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:validator="http://eu.dnetlib/validator"
3
    xmlns:oai="http://www.openarchives.org/OAI/2.0/" exclude-result-prefixes="xs" version="2.0">
4

  
5
	<xsl:output method="xml" indent="yes" />
6
	
7
    <xsl:template match="/">
8
        <oai:record xmlns:dc="http://purl.org/dc/elements/1.1/"
9
            xmlns:dr="http://www.driver-repository.eu/namespace/dr"
10
            xmlns:dri="http://www.driver-repository.eu/namespace/dri"
11
            xmlns:prov="http://www.openarchives.org/OAI/2.0/provenance"
12
            xmlns:oai="http://www.openarchives.org/OAI/2.0/"
13
            xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
14
            <oai:header>
15
                <xsl:apply-templates select="//*[./local-name()='header']/*"/>
16
                <xsl:apply-templates select="//validator:result"/>
17
            </oai:header>
18
            <xsl:apply-templates select="//*[./local-name()='metadata']"/>
19
            <xsl:apply-templates select="//*[./local-name()='about']"/>
20
        </oai:record>
21

  
22
    </xsl:template>
23

  
24
    <xsl:template match="validator:result">
25
        <validator:result score="{@score}" status="{@status}">
26
            <xsl:apply-templates select="./validator:failedRules"/>
27
        </validator:result>
28
    </xsl:template>
29

  
30
    <xsl:template match="@*|node()">
31
        <xsl:copy>
32
            <xsl:apply-templates select="@*|node()"/>
33
        </xsl:copy>
34
    </xsl:template>
35

  
36
</xsl:stylesheet>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/resources/eu/dnetlib/msro/workflows/repo/validation/repobye-validatorAsStep.wf.st
1
<NODE name="SET_INFO" isStart="true" type="SetProviderInfo">
2
	<DESCRIPTION>Retrieve information about current Content Provider</DESCRIPTION>
3
	<PARAMETERS>
4
		<PARAM required="true" type="string" name="providerId" managedBy="system">$params.("dataprovider:id")$</PARAM>
5
		<PARAM required="true" type="string" name="providerName" managedBy="system">$params.("dataprovider:name")$</PARAM>
6
		<PARAM required="true" type="string" name="api" managedBy="system">$params.("dataprovider:interface")$</PARAM>
7
	</PARAMETERS>
8
	<ARCS>
9
		<ARC to="DeleteMetaWorkflow"/>
10
	</ARCS>
11
</NODE>
12

  
13
<NODE name="DeleteMetaWorkflow" type="DeleteMetaWf">
14
	<DESCRIPTION>Delete the MetaWorkflow</DESCRIPTION>
15
	<PARAMETERS>
16
		<PARAM required="true" type="string" name="metaWfId" managedBy="system">$params.("META_WORKFLOW_ID")$</PARAM>
17
	</PARAMETERS>
18
	<ARCS>
19
		<ARC to="DeleteMDStoreNative"/>
20
	</ARCS>
21
</NODE>
22

  
23
<NODE name="DeleteMDStoreNative" type="DeleteMDStore">
24
	<DESCRIPTION>Delete the native mdstore</DESCRIPTION>
25
	<PARAMETERS>
26
		<PARAM required="true" type="string" name="mdstoreId" managedBy="system">$params.("coll_id")$</PARAM>
27
	</PARAMETERS>
28
	<ARCS>
29
		<ARC to="DeleteMDStoreTransformed"/>
30
	</ARCS>
31
</NODE>
32

  
33
<NODE name="DeleteMDStoreTransformed" type="DeleteMDStore">
34
	<DESCRIPTION>Delete the transformed mdstore</DESCRIPTION>
35
	<PARAMETERS>
36
		<PARAM required="true" type="string" name="mdstoreId" managedBy="system">$params.("tran_id")$</PARAM>
37
	</PARAMETERS>
38
	<ARCS>
39
		<ARC to="DeleteMDStoreValidated"/>
40
	</ARCS>
41
</NODE>
42

  
43
<NODE name="DeleteMDStoreValidated" type="DeleteMDStore">
44
	<DESCRIPTION>Delete the validated mdstore</DESCRIPTION>
45
	<PARAMETERS>
46
		<PARAM required="true" type="string" name="mdstoreId" managedBy="system">$params.("val_id")$</PARAM>
47
	</PARAMETERS>
48
	<ARCS>
49
		<ARC to="DeleteIndex"/>
50
	</ARCS>
51
</NODE>
52

  
53
<NODE name="DeleteIndex" type="DeleteIndex">
54
	<DESCRIPTION>Delete the index</DESCRIPTION>
55
	<PARAMETERS>
56
		<PARAM required="true" type="string" name="indexId" managedBy="system">$params.("index_id")$</PARAM>
57
	</PARAMETERS>
58
	<ARCS>
59
		<ARC to="RemoveApiExtraFields"/>
60
	</ARCS>
61
</NODE>
62

  
63
<NODE name="RemoveApiExtraFields" type="RemoveApiExtraFields">
64
	<DESCRIPTION>Reset the extrafields of the api</DESCRIPTION>
65
	<PARAMETERS>
66
		<PARAM required="true" type="string" name="datasourceId" managedBy="system">$params.("dataprovider:id")$</PARAM>
67
		<PARAM required="true" type="string" name="datasourceInterface" managedBy="system">$params.("dataprovider:interface")$</PARAM>
68
		<PARAM required="true" type="string" name="fields" managedBy="system">last_collection_total, last_collection_date, last_collection_mdId, last_aggregation_total, last_aggregation_date, last_aggregation_mdId</PARAM>
69
	</PARAMETERS>
70
	<ARCS>
71
		<ARC to="success"/>
72
	</ARCS>
73
</NODE>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/resources/eu/dnetlib/msro/workflows/repo/validation/nostore/validate-nostore.wf.st
1
<NODE name="SET_INFO_VALIDATION" isStart="true" type="SetInfoForValidation">
2
	<DESCRIPTION>Retrieve information about current Content Provider</DESCRIPTION>
3
	<PARAMETERS>
4
		<PARAM required="true" type="string" name="profileId" managedBy="system">$params.("dataprovider:id")$</PARAM>
5
		<PARAM required="true" type="string" name="providerName" managedBy="system">$params.("dataprovider:name")$</PARAM>
6
		<PARAM required="true" type="string" name="api" managedBy="system">$params.("dataprovider:interface")$</PARAM>
7
	</PARAMETERS>
8
	<ARCS>
9
		<ARC to="selectValidate"/>
10
	</ARCS>
11
</NODE>
12
<NODE name="selectValidate" type="Selection">
13
	<DESCRIPTION>Do we validate the records?</DESCRIPTION>
14
	<PARAMETERS>
15
		<PARAM function="validValues(['YES', 'NO'])" managedBy="user" name="selection" required="true" type="string">YES</PARAM>
16
	</PARAMETERS>
17
	<ARCS>
18
		<ARC name="YES" to="validate" />
19
		<ARC name="NO" to="success" />
20
	</ARCS>
21
</NODE>
22
<NODE name="validate" type="ValidationAsStep">
23
	<DESCRIPTION>Validate from mdStore</DESCRIPTION>
24
	<PARAMETERS>
25
		<PARAM required="true" type="boolean" name="shouldOutputRecords" managedBy="system">false</PARAM>
26
		<PARAM required="false" type="string" name="outputEprName" managedBy="system">validatorEpr</PARAM>
27
		<PARAM required="true" type="string" name="mdstoreId" managedBy="system" category="MDSTORE_ID">$params.("coll_id")$</PARAM>
28
		<PARAM required="true" type="string" name="xQueryForValidatorServiceId" managedBy="user">/RESOURCE_PROFILE[.//RESOURCE_TYPE/@value='ValidatorServiceResourceType' and .//RESOURCE_KIND/@value='ServiceResources']/HEADER/RESOURCE_IDENTIFIER/@value/string()</PARAM>	
29
	    <PARAM required="false" type="string" name="recordsSampleSize" managedBy="user">ALL</PARAM>
30
	    <PARAM required="true" type="string" name="guidelines" managedBy="user" function="validValues(['openaire3.0', 'openaire2.0', 'openaire2.0_data', 'driver'])"/>
31
	    <PARAM required="true" type="boolean" name="shouldUpdateBlacklist" managedBy="user">true</PARAM>
32
		 <PARAM managedBy="user" name="blacklistRuleName" required="false" type="string">blacklist_rules</PARAM>
33
		<PARAM required="false" type="int" name="jobStatusUpdateInterval" managedBy="system"/>
34
	    <PARAM required="false" type="string" name="extraParams" managedBy="user"/>  
35
	</PARAMETERS>
36
	<ARCS>
37
		<ARC to="success"/>
38
	</ARCS>
39
</NODE>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/resources/eu/dnetlib/msro/workflows/repo/validation/nostore/repobye-validatorAsStepNoStore.wf.st
1
<NODE name="SET_INFO" isStart="true" type="SetProviderInfo">
2
	<DESCRIPTION>Retrieve information about current Content Provider</DESCRIPTION>
3
	<PARAMETERS>
4
		<PARAM required="true" type="string" name="providerId" managedBy="system">$params.("dataprovider:id")$</PARAM>
5
		<PARAM required="true" type="string" name="providerName" managedBy="system">$params.("dataprovider:name")$</PARAM>
6
		<PARAM required="true" type="string" name="api" managedBy="system">$params.("dataprovider:interface")$</PARAM>
7
	</PARAMETERS>
8
	<ARCS>
9
		<ARC to="DeleteMetaWorkflow"/>
10
	</ARCS>
11
</NODE>
12

  
13
<NODE name="DeleteMetaWorkflow" type="DeleteMetaWf">
14
	<DESCRIPTION>Delete the MetaWorkflow</DESCRIPTION>
15
	<PARAMETERS>
16
		<PARAM required="true" type="string" name="metaWfId" managedBy="system">$params.("META_WORKFLOW_ID")$</PARAM>
17
	</PARAMETERS>
18
	<ARCS>
19
		<ARC to="DeleteMDStoreNative"/>
20
	</ARCS>
21
</NODE>
22

  
23
<NODE name="DeleteMDStoreNative" type="DeleteMDStore">
24
	<DESCRIPTION>Delete the native mdstore</DESCRIPTION>
25
	<PARAMETERS>
26
		<PARAM required="true" type="string" name="mdstoreId" managedBy="system">$params.("coll_id")$</PARAM>
27
	</PARAMETERS>
28
	<ARCS>
29
		<ARC to="DeleteMDStoreTransformed"/>
30
	</ARCS>
31
</NODE>
32

  
33
<NODE name="DeleteMDStoreTransformed" type="DeleteMDStore">
34
	<DESCRIPTION>Delete the transformed mdstore</DESCRIPTION>
35
	<PARAMETERS>
36
		<PARAM required="true" type="string" name="mdstoreId" managedBy="system">$params.("tran_id")$</PARAM>
37
	</PARAMETERS>
38
	<ARCS>
39
		<ARC to="DeleteIndex"/>
40
	</ARCS>
41
</NODE>
42

  
43
<NODE name="DeleteIndex" type="DeleteIndex">
44
	<DESCRIPTION>Delete the index</DESCRIPTION>
45
	<PARAMETERS>
46
		<PARAM required="true" type="string" name="indexId" managedBy="system">$params.("index_id")$</PARAM>
47
	</PARAMETERS>
48
	<ARCS>
49
		<ARC to="RemoveApiExtraFields"/>
50
	</ARCS>
51
</NODE>
52

  
53
<NODE name="RemoveApiExtraFields" type="RemoveApiExtraFields">
54
	<DESCRIPTION>Reset the extrafields of the api</DESCRIPTION>
55
	<PARAMETERS>
56
		<PARAM required="true" type="string" name="datasourceId" managedBy="system">$params.("dataprovider:id")$</PARAM>
57
		<PARAM required="true" type="string" name="datasourceInterface" managedBy="system">$params.("dataprovider:interface")$</PARAM>
58
		<PARAM required="true" type="string" name="fields" managedBy="system">last_collection_total, last_collection_date, last_collection_mdId, last_aggregation_total, last_aggregation_date, last_aggregation_mdId</PARAM>
59
	</PARAMETERS>
60
	<ARCS>
61
		<ARC to="success"/>
62
	</ARCS>
63
</NODE>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/resources/eu/dnetlib/msro/workflows/repo/validation/validate.wf.st
1
<NODE name="SET_INFO_VALIDATION" isStart="true" type="SetInfoForValidation">
2
	<DESCRIPTION>Retrieve information about current Content Provider</DESCRIPTION>
3
	<PARAMETERS>
4
		<PARAM required="true" type="string" name="profileId" managedBy="system">$params.("dataprovider:id")$</PARAM>
5
		<PARAM required="true" type="string" name="providerName" managedBy="system">$params.("dataprovider:name")$</PARAM>
6
		<PARAM required="true" type="string" name="api" managedBy="system">$params.("dataprovider:interface")$</PARAM>
7
	</PARAMETERS>
8
	<ARCS>
9
		<ARC to="selectValidate"/>
10
	</ARCS>
11
</NODE>
12
<NODE name="selectValidate" type="Selection">
13
	<DESCRIPTION>Do we validate the records?</DESCRIPTION>
14
	<PARAMETERS>
15
		<PARAM function="validValues(['YES', 'NO'])" managedBy="user" name="selection" required="true" type="string">YES</PARAM>
16
	</PARAMETERS>
17
	<ARCS>
18
		<ARC name="YES" to="validate" />
19
		<ARC name="NO" to="success" />
20
	</ARCS>
21
</NODE>
22
<NODE name="validate" type="ValidationAsStep">
23
	<DESCRIPTION>Validate from mdStore</DESCRIPTION>
24
	<PARAMETERS>
25
		<PARAM required="true" type="boolean" name="shouldOutputRecords" managedBy="system">false</PARAM>
26
            <PARAM required="false" type="string" name="outputEprName" managedBy="system">validatorEpr</PARAM>
27
            <PARAM required="true" type="string" name="mdstoreId" managedBy="system" category="MDSTORE_ID">$params.("coll_id")$</PARAM>
28
            <PARAM required="true" type="string" name="xQueryForValidatorServiceId" managedBy="user">/RESOURCE_PROFILE[.//RESOURCE_TYPE/@value='ValidatorServiceResourceType' and .//RESOURCE_KIND/@value='ServiceResources']/HEADER/RESOURCE_IDENTIFIER/@value/string()</PARAM>
29
            <PARAM required="false" type="string" name="recordsSampleSize" managedBy="user">ALL</PARAM>
30
            <PARAM required="true" type="string" name="guidelines" managedBy="user" function="validValues(['openaire3.0', 'openaire2.0', 'openaire2.0_data', 'driver'])"/>
31
            <PARAM required="true" type="boolean" name="shouldUpdateBlacklist" managedBy="user">true</PARAM>
32
            <PARAM managedBy="user" name="blacklistRuleName" required="false" type="string">blacklist_rules</PARAM>
33
            <PARAM required="false" type="int" name="jobStatusUpdateInterval" managedBy="system"/>
34
            <PARAM required="false" type="string" name="extraParams" managedBy="user"/>
35
	</PARAMETERS>
36
	<ARCS>
37
		<ARC to="storeRecords"/>
38
	</ARCS>
39
</NODE>
40
<NODE name="storeRecords" type="StoreMDStoreRecords">
41
	<DESCRIPTION>Store records into mdstore</DESCRIPTION>
42
	<PARAMETERS>
43
		<PARAM required="true" type="string" name="mdId" managedBy="system" category="MDSTORE_ID">$params.("val_id")$</PARAM>
44
		<PARAM required="true" type="string" name="storingType" managedBy="user" function="validValues(['REFRESH', 'INCREMENTAL'])"/>
45
		<PARAM required="true" type="string" name="eprParam" managedBy="system">validatorEpr</PARAM>
46
	</PARAMETERS>
47
	<ARCS>
48
		<ARC to="success"/>
49
	</ARCS>
50
</NODE>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/resources/eu/dnetlib/msro/workflows/applicationContext-repohi.xml
1
<?xml version="1.0" encoding="UTF-8"?>
2
<beans xmlns="http://www.springframework.org/schema/beans"
3
	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:p="http://www.springframework.org/schema/p"
4
	xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
5

  
6
	<bean id="metaWfHiValidatorAsStep" class="eu.dnetlib.msro.workflows.metawf.DatasourceMetaWorkflow"
7
		p:destroyWorkflowTemplate="classpath:/eu/dnetlib/msro/workflows/repo/validation/repobye-validatorAsStep.wf.st"
8
		scope="prototype">
9
		<property name="tree">
10
			<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
11
				p:name="collect"
12
				p:template="classpath:/eu/dnetlib/msro/aggregative/workflows/repo/collect.wf.st">
13
				<property name="children">
14
					<list>
15
						<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
16
							p:name="validate"
17
							p:template="classpath:/eu/dnetlib/msro/workflows/repo/validation/validate.wf.st">
18
							<property name="children">
19
								<list>
20
									<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
21
										p:name="transform"
22
										p:template="classpath:/eu/dnetlib/msro/workflows/repo/validation/transform-validated.wf.st">
23
										<property name="children">
24
											<list>
25
												<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
26
													p:name="index"
27
													p:template="classpath:/eu/dnetlib/msro/aggregative/workflows/repo/index.wf.st">
28
												</bean>
29
												<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
30
													p:name="oai"
31
													p:template="classpath:/eu/dnetlib/msro/aggregative/workflows/repo/oai.wf.st">
32
													<property name="children">
33
														<list>
34
															<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
35
																p:name="oaiPostFeed"
36
																p:template="classpath:/eu/dnetlib/msro/aggregative/workflows/repo/oaiPostFeed.wf.st">
37
															</bean>
38
														</list>
39
													</property>
40
												</bean>
41
											</list>
42
										</property>
43
									</bean>
44
								</list>
45
							</property>
46
						</bean>
47
					</list>
48
				</property>
49
			</bean>
50
		</property>
51
	</bean>
52
	
53
	
54
	<bean id="metaWfHiValidatorAsStepNoStore" class="eu.dnetlib.msro.workflows.metawf.DatasourceMetaWorkflow"
55
		p:destroyWorkflowTemplate="classpath:/eu/dnetlib/msro/workflows/repo/validation/nostore/repobye-validatorAsStepNoStore.wf.st"
56
		scope="prototype">
57
		<property name="tree">
58
			<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
59
				p:name="collect"
60
				p:template="classpath:/eu/dnetlib/msro/aggregative/workflows/repo/collect.wf.st">
61
				<property name="children">
62
					<list>
63
						<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
64
							p:name="validate"
65
							p:template="classpath:/eu/dnetlib/msro/workflows/repo/validation/nostore/validate-nostore.wf.st">
66
							<property name="children">
67
								<list>
68
									<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
69
										p:name="transform" 
70
										p:template="classpath:/eu/dnetlib/msro/aggregative/workflows/repo/transform.wf.st">
71
										<property name="children">
72
											<list>
73
												<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
74
													p:name="index"
75
													p:template="classpath:/eu/dnetlib/msro/aggregative/workflows/repo/index.wf.st">
76
												</bean>
77
												<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
78
													p:name="oai"
79
													p:template="classpath:/eu/dnetlib/msro/aggregative/workflows/repo/oai.wf.st">
80
													<property name="children">
81
														<list>
82
															<bean class="eu.dnetlib.msro.workflows.metawf.WorkflowTree"
83
																p:name="oaiPostFeed"
84
																p:template="classpath:/eu/dnetlib/msro/aggregative/workflows/repo/oaiPostFeed.wf.st">
85
															</bean>
86
														</list>
87
													</property>
88
												</bean>
89
											</list>
90
										</property>
91
									</bean>
92
								</list>
93
							</property>
94
						</bean>
95
					</list>
96
				</property>
97
			</bean>
98
		</property>
99
	</bean>
100

  
101
</beans>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/src/main/resources/eu/dnetlib/applicationContext-dnet-validator-wfnodes.xml
1
<?xml version="1.0" encoding="UTF-8"?>
2
<beans xmlns="http://www.springframework.org/schema/beans"
3
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
4
       xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
5

  
6
	<bean id="wfNodeSetInfoForValidation"
7
		class="eu.dnetlib.msro.workflows.nodes.validation.SetInfoForValidationJobNode"
8
		scope="prototype" />
9

  
10
	<bean id="wfNodeValidationAsStep"
11
		class="eu.dnetlib.msro.workflows.nodes.validation.ValidatorServiceBlackboardJobNode"
12
		scope="prototype" />
13

  
14
</beans>
modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9/pom.xml
1
<?xml version="1.0" encoding="UTF-8"?>
2
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
3
	<parent>
4
		<groupId>eu.dnetlib</groupId>
5
		<artifactId>dnet45-parent</artifactId>
6
		<version>1.0.0</version>
7
		<relativePath />
8
	</parent>
9
	<modelVersion>4.0.0</modelVersion>
10
	<groupId>eu.dnetlib</groupId>
11
	<artifactId>dnet-validator-workflows</artifactId>
12
	<packaging>jar</packaging>
13
	<version>1.1.9</version>
14
	<scm>
15
		<developerConnection>scm:svn:https://svn.driver.research-infrastructures.eu/driver/dnet45/modules/dnet-validator-workflows/tags/dnet-validator-workflows-1.1.9</developerConnection>
16
	</scm>
17
	<dependencies>
18
		<dependency>
19
			<groupId>eu.dnetlib</groupId>
20
			<artifactId>dnet-aggregative-basic-workflows</artifactId>
21
			<version>[2.0.0,3.0.0)</version>
22
		</dependency>
23
		<dependency>
24
			<groupId>junit</groupId>
25
			<artifactId>junit</artifactId>
26
			<version>${junit.version}</version>
27
			<scope>test</scope>
28
		</dependency>
29
	</dependencies>
30
</project>
... This diff was truncated because it exceeds the maximum size that can be displayed.

Also available in: Unified diff