public class MessageGroupStoreReaper extends ObjectSE implements RunnableSE, DisposableBean, InitializingBean, SmartLifecycle
MessageGroupStore
内の MessageGroup
インスタンスの明示的な時間指定有効期限を許可する便利な構成可能コンポーネント。このコンポーネントは、リモートまたは時限実行に役立つ引数なしの run()
メソッドと、シャットダウン時にオプションで呼び出すことができる destroy()
メソッドを提供します。DEFAULT_PHASE
コンストラクターと説明 |
---|
MessageGroupStoreReaper() |
MessageGroupStoreReaper(MessageGroupStore messageGroupStore) |
修飾子と型 | メソッドと説明 |
---|---|
void | afterPropertiesSet() |
void | destroy() |
int | getPhase() |
boolean | isAutoStartup() |
boolean | isRunning() |
void | run() 提供された timeout より古いメッセージグループをすべて期限切れにします。 |
void | setAutoStartup(boolean autoStartup) |
void | setExpireOnDestroy(boolean expireOnDestroy) このコンポーネントが破棄されたときにストアを期限切れにする必要があることを示すフラグ(つまり |
void | setMessageGroupStore(MessageGroupStore messageGroupStore) 他の構成に従って期限切れになるメッセージグループストア。 |
void | setPhase(int phase) |
void | setTimeout(long timeout) ミリ秒単位のタイムアウト(デフォルトは -1)。 |
void | start() |
void | stop() |
cloneSE, equalsSE, finalizeSE, getClassSE, hashCodeSE, notifySE, notifyAllSE, toStringSE, waitSE, waitSE, waitSE
stop
public MessageGroupStoreReaper(MessageGroupStore messageGroupStore)
public MessageGroupStoreReaper()
public void setExpireOnDestroy(boolean expireOnDestroy)
ApplicationContext
が閉じられたとき)にストアを期限切れにする必要があることを示すフラグ。expireOnDestroy
- 設定するフラグ値 public void setTimeout(long timeout)
run()
の場合、その値より古いすべてのグループが期限切れになります。timeout
- 設定するタイムアウト public void setMessageGroupStore(MessageGroupStore messageGroupStore)
messageGroupStore
- 設定する MessageGroupStore
public void afterPropertiesSet()
InitializingBean
の afterPropertiesSet
public void destroy()
DisposableBean
の destroy
public void run()
timeout
より古いメッセージグループをすべて期限切れにします。通常、このメソッドはスケジュールされたタスクによって実行されます。RunnableSE
の runSE
public int getPhase()
Phased
の getPhase
SmartLifecycle
の getPhase
public void setPhase(int phase)
public boolean isAutoStartup()
SmartLifecycle
の isAutoStartup
public void setAutoStartup(boolean autoStartup)