public class DataRecord
extends java.lang.Object
| Modifier and Type | Class and Description |
|---|---|
static class |
DataRecord.Status
Status of the record:
INPROGRESS: record initialized when function starts
COMPLETED: record updated with the result of the function when it ends
EXPIRED: record expired, idempotency will not happen
|
| Constructor and Description |
|---|
DataRecord(java.lang.String idempotencyKey,
DataRecord.Status status,
long expiryTimestamp,
java.lang.String responseData,
java.lang.String payloadHash) |
DataRecord(java.lang.String idempotencyKey,
DataRecord.Status status,
long expiryTimestamp,
java.lang.String responseData,
java.lang.String payloadHash,
java.util.OptionalLong inProgressExpiryTimestamp) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object o) |
long |
getExpiryTimestamp() |
java.lang.String |
getIdempotencyKey() |
java.util.OptionalLong |
getInProgressExpiryTimestamp() |
java.lang.String |
getPayloadHash() |
java.lang.String |
getResponseData() |
DataRecord.Status |
getStatus() |
int |
hashCode() |
boolean |
isExpired(java.time.Instant now)
Check if data record is expired (based on expiration configured in the
IdempotencyConfig) |
public DataRecord(java.lang.String idempotencyKey,
DataRecord.Status status,
long expiryTimestamp,
java.lang.String responseData,
java.lang.String payloadHash)
public DataRecord(java.lang.String idempotencyKey,
DataRecord.Status status,
long expiryTimestamp,
java.lang.String responseData,
java.lang.String payloadHash,
java.util.OptionalLong inProgressExpiryTimestamp)
public java.lang.String getIdempotencyKey()
public boolean isExpired(java.time.Instant now)
IdempotencyConfig)public DataRecord.Status getStatus()
public long getExpiryTimestamp()
public java.util.OptionalLong getInProgressExpiryTimestamp()
public java.lang.String getResponseData()
public java.lang.String getPayloadHash()
public boolean equals(java.lang.Object o)
equals in class java.lang.Objectpublic int hashCode()
hashCode in class java.lang.ObjectCopyright © 2023. All rights reserved.