1 |
26600
|
sandro.lab
|
package eu.dnetlib.msro.openaireplus.workflows.nodes;
|
2 |
|
|
|
3 |
50489
|
michele.ar
|
import org.springframework.beans.factory.annotation.Autowired;
|
4 |
26600
|
sandro.lab
|
|
5 |
|
|
import com.googlecode.sarasvati.Arc;
|
6 |
|
|
import com.googlecode.sarasvati.NodeToken;
|
7 |
50489
|
michele.ar
|
|
8 |
|
|
import eu.dnetlib.enabling.datasources.common.Api;
|
9 |
|
|
import eu.dnetlib.enabling.datasources.common.Datasource;
|
10 |
|
|
import eu.dnetlib.enabling.datasources.common.LocalDatasourceManager;
|
11 |
26600
|
sandro.lab
|
import eu.dnetlib.msro.workflows.nodes.SimpleJobNode;
|
12 |
|
|
|
13 |
50489
|
michele.ar
|
public class UpdateRepositoryProfilesJobNode extends SimpleJobNode {
|
14 |
26600
|
sandro.lab
|
|
15 |
50489
|
michele.ar
|
@Autowired
|
16 |
|
|
private LocalDatasourceManager<Datasource<?, ?>, Api<?>> dsManager;
|
17 |
26600
|
sandro.lab
|
|
18 |
|
|
@Override
|
19 |
|
|
protected String execute(final NodeToken token) throws Exception {
|
20 |
50489
|
michele.ar
|
dsManager.regenerateProfiles();
|
21 |
26600
|
sandro.lab
|
|
22 |
|
|
return Arc.DEFAULT_ARC;
|
23 |
|
|
}
|
24 |
|
|
|
25 |
|
|
}
|