Package org.nuxeo.ecm.liveconnect.update
Interface BatchUpdateBlobProvider
- All Known Implementing Classes:
AbstractLiveConnectBlobProvider
,BoxBlobProvider
,GoogleDriveBlobProvider
public interface BatchUpdateBlobProvider
Interface to batch update documents provided by implementing provider. The method
processDocumentsUpdate()
is called by BlobProviderDocumentsUpdateListener
.
The implementation of processDocumentsUpdate()
must schedule a BlobProviderDocumentsUpdateWork
with
the document ids to be checked and updated if needed.
The @{link BlobProviderDocumentsUpdateWork} will then call the implementation of
checkChangesAndUpdateBlob(List)
.
Note that it is recommended to schedule many workers dealing with a smaller amount of documents (using
MAX_RESULT
) rather than a single one processing all document brought by the provider.
- Since:
- 7.3
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptioncheckChangesAndUpdateBlob
(List<DocumentModel> documents) Check the given list of document for change and update if needed.void
Trigger the documents update for the implementing providers.
-
Field Details
-
MAX_RESULT
static final long MAX_RESULT- See Also:
-
-
Method Details
-
checkChangesAndUpdateBlob
Check the given list of document for change and update if needed. Note that session.save still needs to be called on changed documents.- Parameters:
documents
- to be checked for update- Returns:
- the list of DocumentModel that have changed
-
processDocumentsUpdate
void processDocumentsUpdate()Trigger the documents update for the implementing providers.
-