Package com.wavefront.agent.queueing
Class RetryTaskConverter<T extends DataSubmissionTask<T>>
- java.lang.Object
-
- com.wavefront.agent.queueing.RetryTaskConverter<T>
-
- Type Parameters:
T
- task type
- All Implemented Interfaces:
com.squareup.tape2.ObjectQueue.Converter<T>
public class RetryTaskConverter<T extends DataSubmissionTask<T>> extends Object implements com.squareup.tape2.ObjectQueue.Converter<T>
A serializer + deserializer ofDataSubmissionTask
objects for storage.- Author:
- [email protected]
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
RetryTaskConverter.CompressionType
-
Constructor Summary
Constructors Constructor Description RetryTaskConverter(String handle, RetryTaskConverter.CompressionType compressionType)
-
-
-
Constructor Detail
-
RetryTaskConverter
public RetryTaskConverter(String handle, RetryTaskConverter.CompressionType compressionType)
- Parameters:
handle
- Handle (usually port number) of the pipeline where the data came from.compressionType
- compression type to use for storing tasks.
-
-
Method Detail
-
from
@Nullable public T from(@Nonnull byte[] bytes)
- Specified by:
from
in interfacecom.squareup.tape2.ObjectQueue.Converter<T extends DataSubmissionTask<T>>
-
toStream
public void toStream(@Nonnull T t, @Nonnull OutputStream bytes) throws IOException
- Specified by:
toStream
in interfacecom.squareup.tape2.ObjectQueue.Converter<T extends DataSubmissionTask<T>>
- Throws:
IOException
-
-