com.amazonaws.services.kinesis.producer.IKinesisProducer Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of amazon-kinesis-producer Show documentation
Show all versions of amazon-kinesis-producer Show documentation
The Amazon Kinesis Producer Library for Java enables developers to easily and reliably put data into
Amazon Kinesis.
package com.amazonaws.services.kinesis.producer;
import java.nio.ByteBuffer;
import java.util.List;
import java.util.concurrent.ExecutionException;
import com.google.common.util.concurrent.ListenableFuture;
import com.amazonaws.services.schemaregistry.common.Schema;
public interface IKinesisProducer {
ListenableFuture addUserRecord(String stream, String partitionKey, ByteBuffer data);
ListenableFuture addUserRecord(UserRecord userRecord);
ListenableFuture addUserRecord(String stream, String partitionKey, String explicitHashKey, ByteBuffer data);
ListenableFuture addUserRecord(String stream, String partitionKey, String explicitHashKey, ByteBuffer data, Schema schema);
int getOutstandingRecordsCount();
default long getOldestRecordTimeInMillis() {
throw new UnsupportedOperationException("This method is not supported in this IKinesisProducer type");
}
List getMetrics(String metricName, int windowSeconds) throws InterruptedException, ExecutionException;
List getMetrics(String metricName) throws InterruptedException, ExecutionException;
List getMetrics() throws InterruptedException, ExecutionException;
List getMetrics(int windowSeconds) throws InterruptedException, ExecutionException;
void destroy();
void flush(String stream);
void flush();
void flushSync();
}