Revision 49362
Added by Panagiotis Kanakakis over 6 years ago
ValidatorApiImpl.java | ||
---|---|---|
1 |
package eu.dnetlib.repo.manager.service.rest;
|
|
1 |
package eu.dnetlib.repo.manager.service.controllers;
|
|
2 | 2 |
|
3 | 3 |
import eu.dnetlib.api.functionality.ValidatorServiceException; |
4 | 4 |
import eu.dnetlib.domain.functionality.validator.StoredJob; |
... | ... | |
11 | 11 |
import java.util.*; |
12 | 12 |
import java.util.concurrent.ConcurrentHashMap; |
13 | 13 |
import eu.dnetlib.api.functionality.ValidatorService; |
14 |
import org.json.JSONException; |
|
14 | 15 |
import org.json.JSONObject; |
15 | 16 |
import org.springframework.beans.factory.annotation.Autowired; |
17 |
import org.springframework.beans.factory.annotation.Value; |
|
16 | 18 |
import org.springframework.stereotype.Component; |
17 | 19 |
import org.springframework.web.bind.annotation.PathVariable; |
18 | 20 |
|
19 | 21 |
import javax.annotation.PostConstruct; |
20 | 22 |
|
21 |
@Component |
|
23 |
@Component(value = "validationService")
|
|
22 | 24 |
public class ValidatorApiImpl implements ValidatorApi{ |
23 | 25 |
|
24 | 26 |
@Autowired |
25 | 27 |
private MonitorApiImpl monitorApi; |
26 | 28 |
|
29 |
@Autowired |
|
27 | 30 |
private ServiceLocator<ValidatorService> validatorServiceLocator; |
28 | 31 |
|
29 | 32 |
private ValidatorService getValidationService() { |
... | ... | |
79 | 82 |
} |
80 | 83 |
|
81 | 84 |
@Override |
82 |
public void reSubmitJobForValidation(String jobId) { |
|
85 |
public void reSubmitJobForValidation(String jobId) throws JSONException {
|
|
83 | 86 |
|
84 | 87 |
JSONObject jsonObject = new JSONObject(); |
85 | 88 |
jsonObject.put("jobId",jobId); |
Also available in: Unified diff
Configuration