public interface MetaData
| Modifier and Type | Method and Description |
|---|---|
void |
flushObjectGroup()
Flush ObjectGroup Index
|
void |
flushUnit()
Flush Unit Index
|
void |
insertObjectGroup(com.fasterxml.jackson.databind.JsonNode objectRequest)
Insert an objectGroup
|
void |
insertUnit(com.fasterxml.jackson.databind.JsonNode insertRequest)
insert Unit
|
IndexationResult |
reindex(IndexParameters indexParam)
Reindex one or more collections
|
List<org.bson.Document> |
selectAccessionRegisterOnObjectGroupByOperationId(String operationId)
Select an Accession Register linked to an Operation
|
List<org.bson.Document> |
selectAccessionRegisterOnUnitByOperationId(String operationId)
find the number of archive unit per originating agency for a operationId
|
RequestResponse<com.fasterxml.jackson.databind.JsonNode> |
selectObjectGroupById(com.fasterxml.jackson.databind.JsonNode selectQuery,
String objectGroupId)
Search ObjectGroups by its Id and a Select Query
for this method, the roots will be filled for example request :{ |
RequestResponse<com.fasterxml.jackson.databind.JsonNode> |
selectObjectGroupsByQuery(com.fasterxml.jackson.databind.JsonNode selectQuery)
Search ObjectGroups by Select
SelectQuery |
RequestResponse<com.fasterxml.jackson.databind.JsonNode> |
selectUnitsById(com.fasterxml.jackson.databind.JsonNode selectQuery,
String unitId)
|
RequestResponse<com.fasterxml.jackson.databind.JsonNode> |
selectUnitsByQuery(com.fasterxml.jackson.databind.JsonNode selectQuery)
Search UNITs by Select
SelectQuery |
void |
switchIndex(String alias,
String newIndexName)
Switch indexes for one or more collections
|
void |
updateObjectGroupId(com.fasterxml.jackson.databind.JsonNode updateRequest,
String objectId)
Update an object group
|
RequestResponse<com.fasterxml.jackson.databind.JsonNode> |
updateUnitbyId(com.fasterxml.jackson.databind.JsonNode updateQuery,
String unitId)
Update UNITs by Id
UpdateMultiQueryQuery for this method, the roots will be filled for example request :{ |
void insertUnit(com.fasterxml.jackson.databind.JsonNode insertRequest)
throws InvalidParseOperationException,
IllegalArgumentException,
MetaDataNotFoundException,
MetaDataAlreadyExistException,
MetaDataExecutionException,
MetaDataDocumentSizeException,
VitamDBException
insertRequest - as String { $roots: roots, $query : query, $filter : multi, $data : data}InvalidParseOperationException - Throw if json format is not correctIllegalArgumentException - Throw if arguments of insert query is invalidMetaDataNotFoundException - Throw if parent of this unit is not foundMetaDataAlreadyExistException - Throw if Unit id already existsMetaDataExecutionException - Throw if error occurs when send Unit to databaseMetaDataDocumentSizeException - Throw if Unit size is too bigVitamDBException - in case a desynchro is recorded between Mongo and ESList<org.bson.Document> selectAccessionRegisterOnObjectGroupByOperationId(String operationId)
operationId - the operation identifierRequestResponse<com.fasterxml.jackson.databind.JsonNode> selectUnitsByQuery(com.fasterxml.jackson.databind.JsonNode selectQuery) throws InvalidParseOperationException, MetaDataExecutionException, MetaDataDocumentSizeException, MetaDataNotFoundException, BadRequestException, VitamDBException
SelectQueryselectQuery - the query of type JsonNodeInvalidParseOperationException - Thrown when json format is not correctMetaDataExecutionException - Throw if error occurs when send Unit to databaseMetaDataDocumentSizeException - Throw if Unit size is too bigMetaDataNotFoundException - Throw if unit by id not foundBadRequestException - if a bad request is being usedVitamDBException - in case a desynchro is recorded between Mongo and ESRequestResponse<com.fasterxml.jackson.databind.JsonNode> selectObjectGroupsByQuery(com.fasterxml.jackson.databind.JsonNode selectQuery) throws MetaDataExecutionException, InvalidParseOperationException, MetaDataDocumentSizeException, MetaDataNotFoundException, BadRequestException, VitamDBException
SelectQueryselectQuery - the query of type JsonNodeInvalidParseOperationException - Thrown when json format is not correctMetaDataExecutionException - Throw if error occurs when send Unit to databaseMetaDataDocumentSizeException - Throw if Unit size is too bigMetaDataNotFoundException - Throw if unit by id not foundBadRequestException - if a bad request is being usedVitamDBException - in case a desynchro is recorded between Mongo and ESRequestResponse<com.fasterxml.jackson.databind.JsonNode> selectUnitsById(com.fasterxml.jackson.databind.JsonNode selectQuery, String unitId) throws InvalidParseOperationException, MetaDataExecutionException, MetaDataDocumentSizeException, MetaDataNotFoundException, BadRequestException, VitamDBException
SelectQuery selectQuery - the select query of type JsonNodeunitId - the unit id for queryInvalidParseOperationException - Thrown when json format is not correctMetaDataExecutionException - Throw if error occurs when send Unit to databaseMetaDataDocumentSizeException - Throw if Unit size is too bigMetaDataNotFoundException - Throw if unit by id not foundBadRequestException - if a bad request is being usedVitamDBException - in case a desynchro is recorded between Mongo and ESRequestResponse<com.fasterxml.jackson.databind.JsonNode> selectObjectGroupById(com.fasterxml.jackson.databind.JsonNode selectQuery, String objectGroupId) throws InvalidParseOperationException, MetaDataDocumentSizeException, MetaDataExecutionException, MetaDataNotFoundException, BadRequestException, VitamDBException
selectQuery - the query to filter results and make projectionsobjectGroupId - the objectgroup idInvalidParseOperationException - Thrown when json format is not correctMetaDataExecutionException - Throw if error occurs when send Unit to databaseMetaDataDocumentSizeException - Throw if Unit size is too bigMetaDataNotFoundException - Thrown if no objectGroup is foundBadRequestException - if a bad request is being usedVitamDBException - in case a desynchro is recorded between Mongo and ESRequestResponse<com.fasterxml.jackson.databind.JsonNode> updateUnitbyId(com.fasterxml.jackson.databind.JsonNode updateQuery, String unitId) throws MetaDataNotFoundException, InvalidParseOperationException, MetaDataExecutionException, MetaDataDocumentSizeException, VitamDBException
UpdateMultiQueryQuery updateQuery - the update query as JsonNodeunitId - the id of Unit for queryInvalidParseOperationException - Thrown when json format is not correctMetaDataExecutionException - Throw if error occurs when send Unit to databaseMetaDataDocumentSizeException - Throw if Unit size is too bigMetaDataNotFoundException - Throw if unit does not existVitamDBException - in case a desynchro is recorded between Mongo and ESvoid insertObjectGroup(com.fasterxml.jackson.databind.JsonNode objectRequest)
throws InvalidParseOperationException,
MetaDataNotFoundException,
MetaDataAlreadyExistException,
MetaDataExecutionException,
MetaDataDocumentSizeException
objectRequest - as JsonNode { $roots: roots, $query : query, $filter : multi, $data : data}InvalidParseOperationException - Throw if json format is not correctMetaDataNotFoundException - Throw if parent of this unit is not foundMetaDataAlreadyExistException - Throw if Unit id already existsMetaDataExecutionException - Throw if error occurs when send Unit to databaseMetaDataDocumentSizeException - Throw if Unit size is too bigList<org.bson.Document> selectAccessionRegisterOnUnitByOperationId(String operationId)
operationId - operation idvoid updateObjectGroupId(com.fasterxml.jackson.databind.JsonNode updateRequest,
String objectId)
throws InvalidParseOperationException,
MetaDataExecutionException,
VitamDBException
updateRequest - the request as a jsonobjectId - the id of the object to be updatedInvalidParseOperationException - Thrown when json format is not correctMetaDataExecutionException - Thrown if error occurs when send Unit to databaseVitamDBException - in case a desynchro is recorded between Mongo and ESvoid flushUnit()
throws IllegalArgumentException,
VitamThreadAccessException
IllegalArgumentException - if tenant is wrongVitamThreadAccessException - if tenant is wrongvoid flushObjectGroup()
throws IllegalArgumentException,
VitamThreadAccessException
IllegalArgumentException - if tenant is wrongVitamThreadAccessException - if tenant is wrongIndexationResult reindex(IndexParameters indexParam)
indexParam - the parameters specifying what to reindexvoid switchIndex(String alias, String newIndexName) throws DatabaseException
alias - the alias namenewIndexName - the new index to be pointed onDatabaseException - in case error with database occursCopyright © 2018 Vitam. All rights reserved.