public class PageSubscriptionCounterImpl extends Object implements PageSubscriptionCounter
Constructor and Description |
---|
PageSubscriptionCounterImpl(StorageManager storage,
PageSubscription subscription,
Executor executor,
boolean persistent,
long subscriptionID) |
Modifier and Type | Method and Description |
---|---|
void |
addInc(long id,
int variance,
long size) |
void |
applyIncrementOnTX(Transaction tx,
long recordID1,
int add,
long size)
This method will install the TXs
|
protected void |
cleanup()
This method should always be called from a single threaded executor
|
void |
cleanupNonTXCounters(long pageID)
Cleanup temporary page counters on non transactional paged messages
|
void |
delete() |
void |
delete(Transaction tx) |
long |
getPersistentSize() |
long |
getPersistentSizeAdded() |
long |
getValue() |
long |
getValueAdded() |
void |
increment(Transaction tx,
int add,
long size) |
void |
incrementProcessed(long id,
int add,
long size) |
void |
loadInc(long id,
int add,
long size) |
void |
loadValue(long recordID1,
long value1,
long size) |
void |
pendingCounter(Page page,
int increment,
long size)
This is used only on non transactional paging
|
void |
processReload()
This will process the reload
|
void |
setPersistent(boolean persistent)
used on testing only
|
public PageSubscriptionCounterImpl(StorageManager storage, PageSubscription subscription, Executor executor, boolean persistent, long subscriptionID)
public long getValueAdded()
getValueAdded
in interface PageSubscriptionCounter
public long getValue()
getValue
in interface PageSubscriptionCounter
public long getPersistentSizeAdded()
getPersistentSizeAdded
in interface PageSubscriptionCounter
public long getPersistentSize()
getPersistentSize
in interface PageSubscriptionCounter
public void pendingCounter(Page page, int increment, long size) throws Exception
pendingCounter
in interface PageSubscriptionCounter
page
- increment
- Exception
public void cleanupNonTXCounters(long pageID) throws Exception
cleanupNonTXCounters
in interface PageSubscriptionCounter
pageID
- Exception
public void increment(Transaction tx, int add, long size) throws Exception
increment
in interface PageSubscriptionCounter
Exception
public void applyIncrementOnTX(Transaction tx, long recordID1, int add, long size)
applyIncrementOnTX
in interface PageSubscriptionCounter
tx
- recordID1
- add
- public void loadValue(long recordID1, long value1, long size)
loadValue
in interface PageSubscriptionCounter
public void incrementProcessed(long id, int add, long size)
public void delete() throws Exception
delete
in interface PageSubscriptionCounter
Exception
public void delete(Transaction tx) throws Exception
delete
in interface PageSubscriptionCounter
Exception
public void loadInc(long id, int add, long size)
loadInc
in interface PageSubscriptionCounter
public void processReload()
PageSubscriptionCounter
processReload
in interface PageSubscriptionCounter
public void addInc(long id, int variance, long size)
addInc
in interface PageSubscriptionCounter
public void setPersistent(boolean persistent)
protected void cleanup()
Copyright © 2021 JBoss by Red Hat. All rights reserved.