public interface SessionHeartbeatController extends PropertyResolver
Modifier and Type | Interface and Description |
---|---|
static class |
SessionHeartbeatController.HeartbeatType |
Modifier and Type | Field and Description |
---|---|
static long |
DEFAULT_CONNECTION_HEARTBEAT_INTERVAL
Default value for "session-connection-heartbeat-interval" if none set
|
static java.lang.String |
SESSION_HEARTBEAT_INTERVAL
Property used to register the interval for the heartbeat - if not set or non-positive then disabled
|
static java.lang.String |
SESSION_HEARTBEAT_TYPE
Property used to register the
SessionHeartbeatController.HeartbeatType - if non-existent or NONE then disabled. |
EMPTY
Modifier and Type | Method and Description |
---|---|
default void |
disableSessionHeartbeat()
Disables the session heartbeat feature - Note: if heartbeat already in progress then it may be ignored.
|
default long |
getSessionHeartbeatInterval() |
default SessionHeartbeatController.HeartbeatType |
getSessionHeartbeatType() |
default void |
setSessionHeartbeat(SessionHeartbeatController.HeartbeatType type,
java.time.Duration interval)
Set the session heartbeat
|
default void |
setSessionHeartbeat(SessionHeartbeatController.HeartbeatType type,
java.util.concurrent.TimeUnit unit,
long count) |
getBoolean, getBooleanProperty, getCharset, getInteger, getIntProperty, getLong, getLongProperty, getObject, getParentPropertyResolver, getProperties, getString, getStringProperty
static final java.lang.String SESSION_HEARTBEAT_TYPE
SessionHeartbeatController.HeartbeatType
- if non-existent or NONE
then disabled. Same if some
unknown string value is set as the property value.static final java.lang.String SESSION_HEARTBEAT_INTERVAL
static final long DEFAULT_CONNECTION_HEARTBEAT_INTERVAL
default SessionHeartbeatController.HeartbeatType getSessionHeartbeatType()
default long getSessionHeartbeatInterval()
default void disableSessionHeartbeat()
default void setSessionHeartbeat(SessionHeartbeatController.HeartbeatType type, java.util.concurrent.TimeUnit unit, long count)
default void setSessionHeartbeat(SessionHeartbeatController.HeartbeatType type, java.time.Duration interval)
type
- The type of heartbeat
to useinterval
- The (never null
) heartbeat interval - its milliseconds value is used