use of net.ripe.rpki.validator3.domain.TrustAnchor in project rpki-validator-3 by RIPE-NCC.
the class TrustAnchorController method validationResults.
@GetMapping(path = "/{id}/validation-run")
public ResponseEntity<ApiResponse<ValidationRunResource>> validationResults(@PathVariable long id, HttpServletResponse response, Locale locale) throws IOException {
TrustAnchor trustAnchor = trustAnchorRepository.get(id);
ValidationRun validationRun = validationRunRepository.findLatestCompletedForTrustAnchor(trustAnchor).orElseThrow(() -> new EmptyResultDataAccessException("latest validation run for trust anchor " + id, 1));
response.sendRedirect(linkTo(methodOn(ValidationRunController.class).get(validationRun.getId(), locale)).toString());
return null;
}
use of net.ripe.rpki.validator3.domain.TrustAnchor in project rpki-validator-3 by RIPE-NCC.
the class TrustAnchorService method remove.
public void remove(long trustAnchorId) {
TrustAnchor trustAnchor = trustAnchors.get(trustAnchorId);
validationRunRepository.removeAllForTrustAnchor(trustAnchor);
rpkiRepositories.removeAllForTrustAnchor(trustAnchor);
trustAnchors.remove(trustAnchor);
validatedRpkiObjects.remove(trustAnchor);
}
Aggregations