Class MakeBlob
java.lang.Object
org.nuxeo.lib.stream.computation.AbstractComputation
org.nuxeo.ecm.core.bulk.action.computation.AbstractTransientBlobComputation
org.nuxeo.ecm.core.bulk.action.computation.MakeBlob
- All Implemented Interfaces:
Computation
- Since:
- 10.3
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final longprotected static final Stringprotected static final longprotected static final Stringprotected final Map<String, DataBucket> static final Stringprotected static final intprotected final booleanprotected static final Stringprotected static final StringFields inherited from class org.nuxeo.ecm.core.bulk.action.computation.AbstractTransientBlobComputation
id, tempFields inherited from class org.nuxeo.lib.stream.computation.AbstractComputation
INPUT_1, INPUT_2, INPUT_3, INPUT_NULL, metadata, OUTPUT_1, OUTPUT_2, OUTPUT_3, OUTPUT_4 -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidappendHeaderFooterToFile(Path filePath, String commandId, byte[] header, byte[] footer) protected PathappendToFile(String commandId, byte[] content) protected voidfinishBlob(ComputationContext context, String commandId) protected StringgetOutputStream(String commandId) protected Longvoidinit(ComputationContext context) Called when the framework has registered the computation successfully.voidprocessRecord(ComputationContext context, String documentIdsStreamName, Record record) Process an incoming record on one of the computation's input streams.voidprocessTimer(ComputationContext context, String key, long timestamp) Process a timer callback previously set viaComputationContext.setTimer(String, long).protected StringsaveInTransientStore(String commandId, String storeName) Methods inherited from class org.nuxeo.ecm.core.bulk.action.computation.AbstractTransientBlobComputation
createTemp, getBlob, getTransientStoreKey, storeBlobMethods inherited from class org.nuxeo.lib.stream.computation.AbstractComputation
metadata, processFailure, processRetryMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.nuxeo.lib.stream.computation.Computation
destroy, signalStop
-
Field Details
-
NAME
- See Also:
-
CHECK_DELAY_MS
protected static final long CHECK_DELAY_MS- See Also:
-
FLUSH_UNFINISHED_BLOBS_DELAY_MS
protected static final long FLUSH_UNFINISHED_BLOBS_DELAY_MS- See Also:
-
FLUSH_UNFINISHED_BLOBS_TIMER
- See Also:
-
SORT_STREAM
- See Also:
-
ZIP_STREAM
- See Also:
-
EXPOSE_BLOB_STREAM
- See Also:
-
NB_OUTPUT_STREAMS
protected static final int NB_OUTPUT_STREAMS- See Also:
-
counters
-
totals
-
lastBuckets
-
produceImmediate
protected final boolean produceImmediate
-
-
Constructor Details
-
MakeBlob
public MakeBlob() -
MakeBlob
public MakeBlob(boolean produceImmediate)
-
-
Method Details
-
init
Description copied from interface:ComputationCalled when the framework has registered the computation successfully. Gives users a first opportunity to schedule timer callbacks and produce records. This method can be called multiple times.- Specified by:
initin interfaceComputation- Overrides:
initin classAbstractTransientBlobComputation- Parameters:
context- The computation context object provided by the system.
-
processTimer
Description copied from interface:ComputationProcess a timer callback previously set viaComputationContext.setTimer(String, long).- Specified by:
processTimerin interfaceComputation- Overrides:
processTimerin classAbstractComputation- Parameters:
context- The computation context object provided by the system.key- The name of the timer.timestamp- The timestamp (in ms) for which the callback was scheduled.
-
processRecord
Description copied from interface:ComputationProcess an incoming record on one of the computation's input streams.- Parameters:
context- The computation context object provided by the system.documentIdsStreamName- Name of the input stream that provides the record.record- The record.
-
getTotal
-
appendToFile
-
saveInTransientStore
-
getOutputStream
-
finishBlob
-