class VitamElasticsearchRepository implements VitamRepository {

    @Override
    public Optional<Document> findByIdentifier(String identifier)
        throws DatabaseException {
        ParametersChecker.checkParameter(ALL_PARAMS_REQUIRED);

        String index = indexName;


        try {
            return handleSearch(index, termQuery(IDENTIFIER, identifier));
        } catch (IOException e) {
            throw new DatabaseException("Search by identifier exception", e);
        }

    }

    public  VitamElasticsearchRepository(RestHighLevelClient client, String indexName, boolean indexByTenant);

}