1
|
package eu.dnetlib.oai.actions;
|
2
|
|
3
|
import eu.dnetlib.enabling.tools.blackboard.BlackboardJob;
|
4
|
import eu.dnetlib.enabling.tools.blackboard.BlackboardServerHandler;
|
5
|
import eu.dnetlib.oai.utils.OAIHelper;
|
6
|
import eu.dnetlib.oai.utils.OAIParameterNames;
|
7
|
import org.springframework.beans.factory.annotation.Autowired;
|
8
|
|
9
|
public class RefreshConfigAction extends AbstractOAIStoreAction {
|
10
|
|
11
|
@Autowired
|
12
|
private OAIHelper oaiHelper;
|
13
|
|
14
|
@Override
|
15
|
public void execute(final BlackboardServerHandler handler, final BlackboardJob job) throws Exception {
|
16
|
String dbName = job.getParameters().get(OAIParameterNames.OAI_DB);
|
17
|
oaiHelper.loadConfiguration(dbName);
|
18
|
handler.done(job);
|
19
|
}
|
20
|
|
21
|
public OAIHelper getOaiSetHelper() {
|
22
|
return this.oaiHelper;
|
23
|
}
|
24
|
|
25
|
public void setOaiHelper(final OAIHelper oaiSetHelper) {
|
26
|
this.oaiHelper = oaiSetHelper;
|
27
|
}
|
28
|
|
29
|
}
|