@ThreadSafe public class MutableLightblueNotificationRepositoryConfig extends Object implements LightblueNotificationRepositoryConfig
| Constructor and Description |
|---|
MutableLightblueNotificationRepositoryConfig()
Uses empty default values, which will configure a repository to never retrieve anything.
|
MutableLightblueNotificationRepositoryConfig(Collection<String> initialEntityNamesToProcess,
java.time.Duration processingTimeout,
java.time.Duration expireThreshold)
Uses provided as initial values.
|
| Modifier and Type | Method and Description |
|---|---|
Set<String> |
getEntityNamesToProcess()
Governs whether or not notifications are processed based on their associated entity's name.
|
java.time.Duration |
getNotificationExpireThreshold()
How long before a notification is available for retrieval do we drop the notification and
let it be reprocessed?
|
java.time.Duration |
getNotificationProcessingTimeout()
How long can a notification remain processing before we allow it to be retrieved again for
reprocessing?
|
MutableLightblueNotificationRepositoryConfig |
setEntityNamesToProcess(Collection<String> entityNames) |
MutableLightblueNotificationRepositoryConfig |
setNotificationExpireThreshold(java.time.Duration notificationExpireThreshold) |
MutableLightblueNotificationRepositoryConfig |
setNotificationProcessingTimeout(java.time.Duration notificationProcessingTimeout) |
public MutableLightblueNotificationRepositoryConfig()
public MutableLightblueNotificationRepositoryConfig(Collection<String> initialEntityNamesToProcess, java.time.Duration processingTimeout, java.time.Duration expireThreshold)
public Set<String> getEntityNamesToProcess()
LightblueNotificationRepositoryConfiggetEntityNamesToProcess in interface LightblueNotificationRepositoryConfigpublic MutableLightblueNotificationRepositoryConfig setEntityNamesToProcess(Collection<String> entityNames)
public java.time.Duration getNotificationProcessingTimeout()
LightblueNotificationRepositoryConfiggetNotificationProcessingTimeout in interface LightblueNotificationRepositoryConfigpublic MutableLightblueNotificationRepositoryConfig setNotificationProcessingTimeout(java.time.Duration notificationProcessingTimeout)
public java.time.Duration getNotificationExpireThreshold()
LightblueNotificationRepositoryConfigIn other words, this governs when we stop processing a notification in flight because
we're too near when another retrieval may see it is past its
LightblueNotificationRepositoryConfig.getNotificationProcessingTimeout() and retrieve it for reprocessing.
N.B. The existence of this configuration is a function of our current transaction scheme. This could go away, for instance, if we either atomically updated a notification's processing timestamp before adding its document events. Other alternative schemes are possible.
getNotificationExpireThreshold in interface LightblueNotificationRepositoryConfigpublic MutableLightblueNotificationRepositoryConfig setNotificationExpireThreshold(java.time.Duration notificationExpireThreshold)
Copyright © 2017. All rights reserved.