class RepositoryDocError implements ApiOperation {

  @Override
  public List<GenericJson> execute(IndexingService service)
      throws IOException, InterruptedException {
    PushItem item =
        new PushItem()
            .setType("REPOSITORY_ERROR")
            .setRepositoryError(repositoryDocException.getRepositoryError());
    try {
      return Collections.singletonList(service.push(itemId, item).get());
    } catch (ExecutionException e) {
      throw new IOException("Error pushing repository error", e.getCause());
    }
  }

  public  RepositoryDocError(String itemId, RepositoryException exception);

}