public abstract class DrAbstractSenderStore extends Object implements DrSenderStore
DrSenderStore
implementations.Modifier and Type | Field and Description |
---|---|
protected DrSenderStoreOverflowMode |
overflowMode |
Constructor and Description |
---|
DrAbstractSenderStore() |
Modifier and Type | Method and Description |
---|---|
void |
clear()
Removes all data from store and resets overflow flag to false.
|
protected abstract void |
clear0()
Remove all store data and reset store's state.
|
DrSenderStoreCursor |
cursor(byte dataCenterId)
Gets cursor for the given data center ID.
|
protected abstract DrSenderStoreCursor |
cursor0(byte dataCenterId)
Create new cursor for specified data center.
|
DrSenderStoreOverflowMode |
getOverflowMode()
Gets overflow mode defining how store will behave in case of overflow.
|
boolean |
isOverflow()
Get overflow state of the store.
|
protected void |
onOverflow()
Handle overflow.
|
void |
setOverflowCallback(IgniteRunnable overflowCb)
Sets overflow callback.
|
DrAbstractSenderStore |
setOverflowMode(DrSenderStoreOverflowMode overflowMode)
Sets overflow mode defining how store will behave in case of overflow.
|
void |
store(byte[] dataCenterIds,
byte[] data,
int cnt,
@Nullable IgniteUuid fstId)
Store data.
|
protected abstract void |
store0(byte[] dataCenterIds,
byte[] data,
int cnt,
@Nullable IgniteUuid fstId)
Add data to store.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
sizeBytes, store
protected DrSenderStoreOverflowMode overflowMode
public void store(byte[] dataCenterIds, byte[] data, int cnt, @Nullable @Nullable IgniteUuid fstId) throws IgniteCheckedException
store
in interface DrSenderStore
dataCenterIds
- Target data center ids.data
- Data center replication store entry.cnt
- How many entries are inside passed byte array.fstId
- Full state transfer id.DrSenderStoreOverflowException
- If store is overflowed.IgniteCheckedException
- In case of failure.public DrSenderStoreCursor cursor(byte dataCenterId) throws IgniteCheckedException
cursor
in interface DrSenderStore
dataCenterId
- Data center ID.IgniteCheckedException
- If failed.public void clear() throws IgniteCheckedException
clear
in interface DrSenderStore
IgniteCheckedException
- If failed.public boolean isOverflow()
isOverflow
in interface DrSenderStore
True
if store is overflowed.public DrSenderStoreOverflowMode getOverflowMode()
DrSenderStoreOverflowMode.STOP
public DrAbstractSenderStore setOverflowMode(DrSenderStoreOverflowMode overflowMode)
getOverflowMode()
for more information.overflowMode
- Overflow mode.this
for chaining.public void setOverflowCallback(IgniteRunnable overflowCb)
overflowCb
- Overflow callback.protected void onOverflow() throws DrSenderStoreOverflowException
DrSenderStoreOverflowException
- If store is overflowed and mode is DrSenderStoreOverflowMode.STOP
.protected abstract void store0(byte[] dataCenterIds, byte[] data, int cnt, @Nullable @Nullable IgniteUuid fstId) throws IgniteCheckedException
dataCenterIds
- Data center id.data
- Data to store.cnt
- Entries count.fstId
- Full state transfer id.DrSenderStoreOverflowException
- If store is overflowed and mode is DrSenderStoreOverflowMode.STOP
.IgniteCheckedException
protected abstract DrSenderStoreCursor cursor0(byte dataCenterId) throws IgniteCheckedException
dataCenterId
- Data center id.IgniteCheckedException
- If fails.protected abstract void clear0() throws IgniteCheckedException
IgniteCheckedException
- If fails.
GridGain In-Memory Computing Platform : ver. 8.9.15 Release Date : December 3 2024