public class ProducerBatch extends Object implements Delayed
| 构造器和说明 |
|---|
ProducerBatch(GroupKey groupKey,
String packageId,
int batchSizeThresholdInBytes,
int batchCountThreshold,
int maxReservedAttempts,
long nowMs) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
appendAttempt(Attempt attempt) |
int |
compareTo(Delayed o) |
void |
fireCallbacksAndSetFutures() |
int |
getCurBatchSizeInBytes() |
long |
getDelay(TimeUnit unit) |
GroupKey |
getGroupKey() |
List<com.aliyun.openservices.log.common.LogItem> |
getLogItems() |
String |
getLogStore() |
long |
getNextRetryMs() |
String |
getPackageId() |
String |
getProject() |
int |
getRetries() |
String |
getShardHash() |
String |
getSource() |
String |
getTopic() |
boolean |
isMeetSendCondition() |
long |
remainingMs(long nowMs,
long lingerMs) |
void |
setNextRetryMs(long nextRetryMs) |
String |
toString() |
com.google.common.util.concurrent.ListenableFuture<Result> |
tryAppend(List<com.aliyun.openservices.log.common.LogItem> items,
int sizeInBytes,
Callback callback) |
com.google.common.util.concurrent.ListenableFuture<Result> |
tryAppend(com.aliyun.openservices.log.common.LogItem item,
int sizeInBytes,
Callback callback) |
public com.google.common.util.concurrent.ListenableFuture<Result> tryAppend(com.aliyun.openservices.log.common.LogItem item, int sizeInBytes, Callback callback)
public com.google.common.util.concurrent.ListenableFuture<Result> tryAppend(List<com.aliyun.openservices.log.common.LogItem> items, int sizeInBytes, Callback callback)
public void appendAttempt(Attempt attempt)
public boolean isMeetSendCondition()
public long remainingMs(long nowMs,
long lingerMs)
public void fireCallbacksAndSetFutures()
public GroupKey getGroupKey()
public String getPackageId()
public List<com.aliyun.openservices.log.common.LogItem> getLogItems()
public long getNextRetryMs()
public void setNextRetryMs(long nextRetryMs)
public String getProject()
public String getLogStore()
public String getTopic()
public String getSource()
public String getShardHash()
public int getCurBatchSizeInBytes()
public int getRetries()
public int compareTo(@Nonnull Delayed o)
compareTo 在接口中 Comparable<Delayed>Copyright © 2019. All rights reserved.