Interface LogbookOperationsClient
-
- All Superinterfaces:
java.lang.AutoCloseable
,BasicClient
,MockOrRestClient
,VitamAutoCloseable
- All Known Implementing Classes:
LogbookOperationsClientMock
public interface LogbookOperationsClient extends BasicClient
Logbook client interface
-
-
Field Summary
-
Fields inherited from interface fr.gouv.vitam.common.client.BasicClient
STATUS_URL
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description LifecycleTraceabilityStatus
checkLifecycleTraceabilityWorkflowStatus(java.lang.String processId)
Check life cycle traceability status (unit / got)LogbookCheckResult
checkLogbookCoherence()
checkLogbookCoherencevoid
create(LogbookOperationParameters... parameters)
Create logbook entry
To be used ONLY once at top level of process startup (where eventIdentifierProcess is set for the first time).void
create(java.lang.String eventIdProc, java.lang.Iterable<LogbookOperationParameters> queue)
Bulk Create
To be used ONLY once at top level of process startup (where eventIdentifierProcess is set for the first time).RequestResponse<com.fasterxml.jackson.databind.JsonNode>
getLastOperationByType(java.lang.String operationType)
void
reconstructCollection(java.util.List<ReconstructionRequestItem> reconstructionItems)
ReindexationResult
reindex(IndexParameters indexParam)
Reindex a collection with parameterscom.fasterxml.jackson.databind.JsonNode
selectOperation(com.fasterxml.jackson.databind.JsonNode select)
com.fasterxml.jackson.databind.JsonNode
selectOperation(com.fasterxml.jackson.databind.JsonNode select, boolean isSliced, boolean isCrossTenant)
com.fasterxml.jackson.databind.JsonNode
selectOperationById(java.lang.String id)
com.fasterxml.jackson.databind.JsonNode
selectOperationById(java.lang.String processId, com.fasterxml.jackson.databind.JsonNode query, boolean isSliced, boolean isCrossTenant)
SwitchIndexResult
switchIndexes(SwitchIndexParameters switchIndexParam)
Switch indexesRequestResponseOK<TenantLogbookOperationTraceabilityResult>
traceability(java.util.List<java.lang.Integer> tenants)
Call traceability logbook operation for requested tenantsvoid
traceabilityAudit(int tenant, AuditLogbookOptions options)
RequestResponseOK<java.lang.String>
traceabilityLfcObjectGroup()
Starts Object Group logbook lifecycle traceabilityRequestResponseOK<java.lang.String>
traceabilityLfcUnit()
Starts Unit logbook lifecycle traceabilityvoid
update(LogbookOperationParameters... parameters)
Update logbook entry
To be used everywhere except very first time (when eventIdentifierProcess already used once)void
update(java.lang.String eventIdProc, java.lang.Iterable<LogbookOperationParameters> queue)
Bulk Update
To be used everywhere except very first time (when eventIdentifierProcess already used once)-
Methods inherited from interface fr.gouv.vitam.common.client.MockOrRestClient
checkStatus, checkStatus, close, consumeAnyEntityAndClose, getResourcePath, getServiceUrl
-
-
-
-
Method Detail
-
create
void create(LogbookOperationParameters... parameters) throws LogbookClientBadRequestException, LogbookClientAlreadyExistsException, LogbookClientServerException
Create logbook entry
To be used ONLY once at top level of process startup (where eventIdentifierProcess is set for the first time).- Parameters:
parameters
- the entry parameters- Throws:
LogbookClientBadRequestException
- if the argument is incorrectLogbookClientAlreadyExistsException
- if the element already existsLogbookClientServerException
- if the Server got an internal errorjava.lang.IllegalArgumentException
- if some mandatories parameters are empty or nullLogbookClientException
- if client received an error from server
-
update
void update(LogbookOperationParameters... parameters) throws LogbookClientBadRequestException, LogbookClientNotFoundException, LogbookClientServerException
Update logbook entry
To be used everywhere except very first time (when eventIdentifierProcess already used once)- Parameters:
parameters
- the entry parameters- Throws:
LogbookClientBadRequestException
- if the argument is incorrectLogbookClientNotFoundException
- if the element was not created beforeLogbookClientServerException
- if the Server got an internal errorjava.lang.IllegalArgumentException
- if some mandatories parameters are empty or null
-
selectOperation
com.fasterxml.jackson.databind.JsonNode selectOperation(com.fasterxml.jackson.databind.JsonNode select) throws LogbookClientException, InvalidParseOperationException
- Parameters:
select
-- Returns:
- logbook operation as JsonNode
- Throws:
LogbookClientException
InvalidParseOperationException
-
selectOperation
com.fasterxml.jackson.databind.JsonNode selectOperation(com.fasterxml.jackson.databind.JsonNode select, boolean isSliced, boolean isCrossTenant) throws LogbookClientException, InvalidParseOperationException
-
selectOperationById
com.fasterxml.jackson.databind.JsonNode selectOperationById(java.lang.String processId, com.fasterxml.jackson.databind.JsonNode query, boolean isSliced, boolean isCrossTenant) throws LogbookClientException, InvalidParseOperationException
-
selectOperationById
com.fasterxml.jackson.databind.JsonNode selectOperationById(java.lang.String id) throws LogbookClientException, InvalidParseOperationException
- Parameters:
id
- identifier- Returns:
- logbook operation as String
- Throws:
LogbookClientException
- LogbookClientExceptionInvalidParseOperationException
- InvalidParseOperationException
-
create
void create(java.lang.String eventIdProc, java.lang.Iterable<LogbookOperationParameters> queue) throws LogbookClientBadRequestException, LogbookClientAlreadyExistsException, LogbookClientServerException
Bulk Create
To be used ONLY once at top level of process startup (where eventIdentifierProcess is set for the first time).- Parameters:
eventIdProc
- event Process Identifierqueue
- queue of LogbookOperationParameters to create- Throws:
LogbookClientBadRequestException
- if the argument is incorrectLogbookClientAlreadyExistsException
- if the element already existsLogbookClientServerException
- if the Server got an internal errorjava.lang.IllegalArgumentException
- if some mandatories parameters are empty or null
-
update
void update(java.lang.String eventIdProc, java.lang.Iterable<LogbookOperationParameters> queue) throws LogbookClientNotFoundException, LogbookClientBadRequestException, LogbookClientServerException
Bulk Update
To be used everywhere except very first time (when eventIdentifierProcess already used once)- Parameters:
eventIdProc
- event Process Identifierqueue
- queue of LogbookOperationParameters to update- Throws:
LogbookClientBadRequestException
- if the argument is incorrectLogbookClientNotFoundException
- if the element was not created beforeLogbookClientServerException
- if the Server got an internal errorjava.lang.IllegalArgumentException
- if some mandatories parameters are empty or null
-
traceability
RequestResponseOK<TenantLogbookOperationTraceabilityResult> traceability(java.util.List<java.lang.Integer> tenants) throws LogbookClientServerException, InvalidParseOperationException
Call traceability logbook operation for requested tenants- Returns:
- logbook operation result per tenant
- Throws:
LogbookClientServerException
InvalidParseOperationException
-
traceabilityLfcUnit
RequestResponseOK<java.lang.String> traceabilityLfcUnit() throws LogbookClientServerException, InvalidParseOperationException
Starts Unit logbook lifecycle traceability- Returns:
- logbook lifecycles as String
- Throws:
LogbookClientServerException
InvalidParseOperationException
-
traceabilityLfcObjectGroup
RequestResponseOK<java.lang.String> traceabilityLfcObjectGroup() throws LogbookClientServerException, InvalidParseOperationException
Starts Object Group logbook lifecycle traceability- Returns:
- logbook lifecycles as String
- Throws:
LogbookClientServerException
InvalidParseOperationException
-
checkLifecycleTraceabilityWorkflowStatus
LifecycleTraceabilityStatus checkLifecycleTraceabilityWorkflowStatus(java.lang.String processId) throws LogbookClientServerException, InvalidParseOperationException
Check life cycle traceability status (unit / got)- Parameters:
processId
- the process id- Returns:
- lifecycle traceability status
- Throws:
LogbookClientServerException
InvalidParseOperationException
-
reindex
ReindexationResult reindex(IndexParameters indexParam) throws InvalidParseOperationException, LogbookClientServerException
Reindex a collection with parameters- Parameters:
indexParam
- reindexation parameters- Returns:
- JsonObject containing information about the newly created index
- Throws:
LogbookClientServerException
InvalidParseOperationException
-
switchIndexes
SwitchIndexResult switchIndexes(SwitchIndexParameters switchIndexParam) throws InvalidParseOperationException, LogbookClientServerException
Switch indexes- Parameters:
switchIndexParam
- switch index parameters- Returns:
- JsonObject containing information about the newly created index
- Throws:
LogbookClientServerException
InvalidParseOperationException
-
traceabilityAudit
void traceabilityAudit(int tenant, AuditLogbookOptions options) throws LogbookClientServerException
- Throws:
LogbookClientServerException
-
checkLogbookCoherence
LogbookCheckResult checkLogbookCoherence() throws LogbookClientServerException
checkLogbookCoherence- Returns:
- result
- Throws:
LogbookClientServerException
-
getLastOperationByType
RequestResponse<com.fasterxml.jackson.databind.JsonNode> getLastOperationByType(java.lang.String operationType) throws LogbookClientServerException
- Throws:
LogbookClientServerException
-
reconstructCollection
void reconstructCollection(java.util.List<ReconstructionRequestItem> reconstructionItems) throws LogbookClientServerException
- Throws:
LogbookClientServerException
-
-