Interface QueueConfig
- All Superinterfaces:
- Config
Queues may be configured both server side and client side (if required).
Queue properties can not be changed once the server has started.
- Since:
- 4.4
- 
Method SummaryModifier and TypeMethodDescriptionbooleanGets whether the queue has conflation enabled by default.intGets the lower threshold.longGets the maximum size of the outbound message queue in bytes.intGets the maximum queue depth.getName()Gets the queue definition name.intGets the upper threshold.voidsetConflates(boolean conflates) Sets whether the queue has conflation enabled by default.voidsetLowerThreshold(int threshold) Sets the lower threshold.voidsetMaximumBytes(long maximumBytes) Sets the maximum size of the outbound message queue in bytes.voidsetMaximumDepth(int maximumDepth) Sets the maximum depth of the queue.voidsetUpperThreshold(int threshold) Sets the upper threshold.
- 
Method Details- 
getNameString getName()Gets the queue definition name.- Returns:
- queue definition name
 
- 
setMaximumDepthSets the maximum depth of the queue.If the queue depth exceeds this maximum, the server may attempt to free some space by compacting the message queue. If the number of messages queued remains above this maximum, the session will be closed to free memory. If not specified, it defaults to Integer.MAX_VALUE.This is considered separately from SessionConfig.getMaximumQueuedBytes()andgetMaximumBytes().- Parameters:
- maximumDepth- the maximum queue depth, must be positive
- Throws:
- ConfigException- if the property can not be set
 
- 
getMaximumDepthint getMaximumDepth()Gets the maximum queue depth.- Returns:
- the maximum queue depth, a positive integer
 
- 
setConflatesSets whether the queue has conflation enabled by default.The default setting is true. Conflation can be enabled or disabled for individual sessions at runtime. The behavior when conflation is enabled is determined by the conflation policies of topics. - Parameters:
- conflates- true if the queue can be conflated by default
- Throws:
- ConfigException- if unable to set the conflates property
 
- 
conflatesboolean conflates()Gets whether the queue has conflation enabled by default.- Returns:
- true if queue can be conflated by default
 
- 
setUpperThresholdSets the upper threshold.When the upper percentage of the queue reached, any queue listeners will be notified. This currently only has an effect server side. By default the upper threshold will not be notified. - Parameters:
- threshold- the upper threshold percentage. A value of -1 means that upper threshold will not be notified otherwise the value must be in the range 1 to 100 and greater than the lower threshold.
- Throws:
- ConfigException- if the property can not be set
 
- 
getUpperThresholdint getUpperThreshold()Gets the upper threshold.- Returns:
- the upper threshold
 
- 
setLowerThresholdSets the lower threshold.After an upper threshold event has occurred, this specifies the percentage queue size at which listeners for queue threshold notifications will be notified. This only has an effect when used in conjunction with the upper threshold. By default no lower threshold notification would occur. - Parameters:
- threshold- the lower threshold percentage. A value of -1 means that lower threshold will not be notified otherwise the value must be in the range 0 to 100 and less than the upper threshold.
- Throws:
- ConfigException- if the property can not be set
 
- 
getLowerThresholdint getLowerThreshold()Gets the lower threshold.- Returns:
- the lower threshold
 
- 
setMaximumBytesSets the maximum size of the outbound message queue in bytes.If the number of bytes queued exceeds this maximum, the server may attempt to free some memory by compacting the message queue. If the number of bytes queued remains above this maximum, the session will be closed to free memory. If not specified, it defaults to Long.MAX_VALUE.This is considered separately from SessionConfig.getMaximumQueuedBytes()andgetMaximumDepth().- Parameters:
- maximumBytes- the maximum queue bytes, must be positive
- Throws:
- ConfigException- if the property can not be set
- Since:
- 6.1
 
- 
getMaximumByteslong getMaximumBytes()Gets the maximum size of the outbound message queue in bytes.- Returns:
- the maximum size of the outbound message queue in bytes
- Since:
- 6.1
 
 
-