Package org.opennms.nephron.cortex
Class CortexIo.Write<K,V>
- java.lang.Object
-
- org.apache.beam.sdk.transforms.PTransform<org.apache.beam.sdk.values.PCollection<org.apache.beam.sdk.values.KV<K,V>>,org.apache.beam.sdk.values.PDone>
-
- org.opennms.nephron.cortex.CortexIo.Write<K,V>
-
- All Implemented Interfaces:
Serializable,org.apache.beam.sdk.transforms.display.HasDisplayData
- Enclosing class:
- CortexIo
public abstract static class CortexIo.Write<K,V> extends org.apache.beam.sdk.transforms.PTransform<org.apache.beam.sdk.values.PCollection<org.apache.beam.sdk.values.KV<K,V>>,org.apache.beam.sdk.values.PDone>Stores the configuration of the transforms.Expands to a
ParDotransform that is specified by subclasses of theCortexIo.WriteFnclass.- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected CortexIo.BuildTimeSeries<K,V>buildprotected List<BiConsumer<okhttp3.Call,Exception>>failureHandlersprotected Map<String,String>fixedLabelsprotected longmaxBatchBytesprotected longmaxBatchSizeprotected StringorgIdprotected longreadTimeoutMsprotected List<BiConsumer<okhttp3.Call,okhttp3.Response>>responseHandlersprotected longwriteTimeoutMsprotected StringwriteUrl
-
Constructor Summary
Constructors Constructor Description Write(String writeUrl, CortexIo.BuildTimeSeries<K,V> build)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.apache.beam.sdk.values.PDoneexpand(org.apache.beam.sdk.values.PCollection<org.apache.beam.sdk.values.KV<K,V>> input)CortexIo.Write<K,V>withFailureHandler(BiConsumer<okhttp3.Call,Exception> handler)CortexIo.Write<K,V>withFixedLabel(String name, String value)CortexIo.Write<K,V>withMaxBatchBytes(long value)CortexIo.Write<K,V>withMaxBatchSize(long value)CortexIo.Write<K,V>withMetricName(String value)CortexIo.Write<K,V>withOrgId(String value)CortexIo.Write<K,V>withReadTimeoutMs(long value)CortexIo.Write<K,V>withResponseHandler(BiConsumer<okhttp3.Call,okhttp3.Response> handler)CortexIo.Write<K,V>withWriteTimeoutMs(long value)
-
-
-
Field Detail
-
writeUrl
protected final String writeUrl
-
build
protected final CortexIo.BuildTimeSeries<K,V> build
-
orgId
protected String orgId
-
maxBatchSize
protected long maxBatchSize
-
maxBatchBytes
protected long maxBatchBytes
-
readTimeoutMs
protected long readTimeoutMs
-
writeTimeoutMs
protected long writeTimeoutMs
-
responseHandlers
protected final List<BiConsumer<okhttp3.Call,okhttp3.Response>> responseHandlers
-
failureHandlers
protected final List<BiConsumer<okhttp3.Call,Exception>> failureHandlers
-
-
Constructor Detail
-
Write
public Write(String writeUrl, CortexIo.BuildTimeSeries<K,V> build)
-
-
Method Detail
-
withOrgId
public CortexIo.Write<K,V> withOrgId(String value)
-
withMaxBatchSize
public CortexIo.Write<K,V> withMaxBatchSize(long value)
-
withMaxBatchBytes
public CortexIo.Write<K,V> withMaxBatchBytes(long value)
-
withReadTimeoutMs
public CortexIo.Write<K,V> withReadTimeoutMs(long value)
-
withWriteTimeoutMs
public CortexIo.Write<K,V> withWriteTimeoutMs(long value)
-
withFixedLabel
public CortexIo.Write<K,V> withFixedLabel(String name, String value)
-
withMetricName
public CortexIo.Write<K,V> withMetricName(String value)
-
withResponseHandler
public CortexIo.Write<K,V> withResponseHandler(BiConsumer<okhttp3.Call,okhttp3.Response> handler)
-
withFailureHandler
public CortexIo.Write<K,V> withFailureHandler(BiConsumer<okhttp3.Call,Exception> handler)
-
-