Class ReferentialAccessionRegisterImpl
java.lang.Object
fr.gouv.vitam.functional.administration.core.accession.register.ReferentialAccessionRegisterImpl
- All Implemented Interfaces:
VitamAutoCloseable
,AutoCloseable
Referential Accession Register Implement
-
Constructor Summary
ConstructorsConstructorDescriptionReferentialAccessionRegisterImpl
(MongoDbAccessAdminImpl dbConfiguration, VitamCounterService vitamCounterService, MetaDataClientFactory metaDataClientFactory, AdminManagementConfiguration configuration) ConstructorReferentialAccessionRegisterImpl
(MongoDbAccessAdminImpl dbConfiguration, FunctionalBackupService functionalBackupService, MetaDataClientFactory metaDataClientFactory, int accessionRegisterSymbolicThreadPoolSize) Constructor -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
void
createAccessionRegisterSymbolic
(List<Integer> tenants) void
createOrUpdateAccessionRegister
(AccessionRegisterDetailModel registerDetail) findAccessionRegisterSymbolic
(com.fasterxml.jackson.databind.JsonNode queryDsl) Find the accession register symbolic filtered by the query dsl, if an empty query dsl is provided, the last 20 accession register symbolics will be returned.findDetail
(com.fasterxml.jackson.databind.JsonNode select) search for an accession register's operation detailfindDocuments
(com.fasterxml.jackson.databind.JsonNode select) search for an accession register's summaryvoid
migrateAccessionRegister
(AccessionRegisterDetailModel accessionRegister, List<String> fieldsToUpdate)
-
Constructor Details
-
ReferentialAccessionRegisterImpl
public ReferentialAccessionRegisterImpl(MongoDbAccessAdminImpl dbConfiguration, VitamCounterService vitamCounterService, MetaDataClientFactory metaDataClientFactory, AdminManagementConfiguration configuration) Constructor- Parameters:
dbConfiguration
- the mongo access configurationmetaDataClientFactory
-configuration
-
-
ReferentialAccessionRegisterImpl
public ReferentialAccessionRegisterImpl(MongoDbAccessAdminImpl dbConfiguration, FunctionalBackupService functionalBackupService, MetaDataClientFactory metaDataClientFactory, int accessionRegisterSymbolicThreadPoolSize) Constructor- Parameters:
dbConfiguration
- the mongo access configurationmetaDataClientFactory
-accessionRegisterSymbolicThreadPoolSize
-
-
-
Method Details
-
createAccessionRegisterSymbolic
- Throws:
ReferentialException
-
findAccessionRegisterSymbolic
public RequestResponseOK<AccessionRegisterSymbolicModel> findAccessionRegisterSymbolic(com.fasterxml.jackson.databind.JsonNode queryDsl) throws ReferentialException, InvalidParseOperationException Find the accession register symbolic filtered by the query dsl, if an empty query dsl is provided, the last 20 accession register symbolics will be returned.- Parameters:
queryDsl
- that filter the accession register to find- Returns:
- the list of accession register symbolic or an empty list
- Throws:
ReferentialException
InvalidParseOperationException
-
createOrUpdateAccessionRegister
public void createOrUpdateAccessionRegister(AccessionRegisterDetailModel registerDetail) throws BadRequestException, ReferentialException - Parameters:
registerDetail
- to create in Mongodb- Throws:
ReferentialException
- throws when insert mongodb errorBadRequestException
-
close
public void close()- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceVitamAutoCloseable
-
findDocuments
public RequestResponseOK<AccessionRegisterSummary> findDocuments(com.fasterxml.jackson.databind.JsonNode select) throws ReferentialException search for an accession register's summary- Parameters:
select
- the search criteria for the select operation- Returns:
- A list of AccressionRegisterSummaries matching the 'select' criteria.
- Throws:
ReferentialException
- If the search's result is null or empty, or if the mongo search throw error
-
findDetail
public RequestResponseOK<AccessionRegisterDetail> findDetail(com.fasterxml.jackson.databind.JsonNode select) throws ReferentialException search for an accession register's operation detail- Parameters:
select
- the search criteria for the select operation- Returns:
- A list of AccressionRegisterDetails matching the 'select' criteria.
- Throws:
ReferentialException
- If the search's result is null or empty, or if the mongo search throw error
-
migrateAccessionRegister
public void migrateAccessionRegister(AccessionRegisterDetailModel accessionRegister, List<String> fieldsToUpdate) throws ReferentialException, BadRequestException
-