UM Java API  6.16.1
com.latencybusters.lbm.LBMHotFailoverSource Class Reference
Inheritance diagram for com.latencybusters.lbm.LBMHotFailoverSource:
com.latencybusters.lbm.LBMSource

Public Member Functions

 LBMHotFailoverSource (LBMContext lbmctx, LBMTopic lbmtopic) throws LBMException
 
 LBMHotFailoverSource (LBMContext lbmctx, LBMTopic lbmtopic, LBMSourceEventCallback cb, Object cbArg) throws LBMException
 
 LBMHotFailoverSource (LBMContext lbmctx, LBMTopic lbmtopic, LBMEventQueue lbmevq) throws LBMException
 
 LBMHotFailoverSource (LBMContext lbmctx, LBMTopic lbmtopic, LBMSourceEventCallback cb, Object cbArg, LBMEventQueue lbmevq) throws LBMException
 
void send (byte[] message, int messageLength, long sqn, int flags) throws LBMException
 
void send (byte[] message, int messageLength, long sqn, int flags, Object cbArg) throws LBMException
 
void send (byte[] message, int messageLength, long sqn, int flags, LBMSourceSendExInfo exinfo) throws LBMException
 
void send (ByteBuffer message, int startPosition, int messageLength, long sqn, int flags) throws LBMException
 
void send (ByteBuffer message, int startPosition, int messageLength, long sqn, int flags, Object cbArg) throws LBMException
 
void send (ByteBuffer message, int startPosition, int messageLength, long sqn, int flags, LBMSourceSendExInfo exinfo) throws LBMException
 
void sendReceiverReset (int flags, LBMSourceSendExInfo exinfo) throws LBMException
 
void unblock () throws LBMException
 
void umederegister () throws LBMException
 
void close () throws LBMException
 
boolean isClosed ()
 
LBMConfigOption[] dumpAttributeList ()
 
LBMSourceChannelInfo createChannel (long channelNumber) throws LBMException
 
void deleteChannel (LBMSourceChannelInfo channelInfo) throws LBMException
 
void addSourceCallback (LBMSourceEventCallback cb)
 
void addSourceCallback (LBMSourceEventCallback cb, Object cbArg)
 
void removeSourceCallback (LBMSourceEventCallback cb)
 
void removeSourceCallback (LBMSourceEventCallback cb, Object cbArg)
 
String getAttributeValue (String attributeName) throws LBMException
 
void setAttributeValue (String attributeName, String attributeValue) throws LBMException
 
Object setProperty (String attributeName, String attributeValue)
 
void load (InputStream inStream) throws IOException
 
LBMSourceStatistics getStatistics () throws LBMException
 
void resetStatistics () throws LBMException
 
void sendStatistics (ByteBuffer message, int messageLength, int statsType) throws LBMException
 
void send (byte[] message, int messageLength, int flags) throws LBMException
 
void send (byte[] message, int messageLength, int flags, Object cbArg) throws LBMException
 
void send (byte[] message, int messageLength, int flags, LBMSourceSendExInfo exinfo) throws LBMException
 
void send (ByteBuffer message, int startPosition, int messageLength, int flags) throws LBMException
 
void send (ByteBuffer message, int startPosition, int messageLength, int flags, Object cbArg) throws LBMException
 
void send (ByteBuffer message, int startPosition, int messageLength, int flags, LBMSourceSendExInfo exinfo) throws LBMException
 
void send (LBMRequest lbmreq, int flags) throws LBMException
 
void send (LBMRequest lbmreq, LBMEventQueue lbmevq, int flags) throws LBMException
 
void send (LBMRequest lbmreq, LBMEventQueue lbmevq, int flags, LBMSourceSendExInfo exinfo) throws LBMException
 
void send (LBMRequest lbmreq, int flags, LBMSourceSendExInfo exinfo) throws LBMException
 
void flush () throws LBMException
 
int getInflight (int type) throws LBMException
 
LBMFlightSizeInflightInfo getInflightEx (int type) throws LBMException
 
int setInflight (int type, LBMSetInflightCallback setInflightCb, Object clientd) throws LBMException
 
LBMFlightSizeInflightInfo setInflightEx (int type, LBMSetInflightCallback setInflightCb, Object clientd) throws LBMException
 
void setUMEMessageStable (long sqn) throws LBMException
 
ByteBuffer getMessagesBuffer () throws LBMException
 
int acquireMessageBufferPosition (final int messageLength, final int flags) throws LBMException
 
void messageBuffersComplete () throws LBMException
 
int messageBuffersCompleteAndAcquirePosition (final int messageLength, final int flags) throws LBMException
 
void messageBuffersCancel () throws LBMException
 

Protected Member Functions

void finalize () throws LBMException
 
int onSourceEvent (LBMSourceEvent sourceEvent)
 
int onResponse (LBMRequest lbmreq, LBMMessage lbmmsg)
 

Detailed Description

LBM Hot-Failover Source class.

Warning: It is not safe to instantiate this object from a context thread callback.

Constructor & Destructor Documentation

com.latencybusters.lbm.LBMHotFailoverSource.LBMHotFailoverSource ( LBMContext  lbmctx,
LBMTopic  lbmtopic 
) throws LBMException

Instantiate an LBM Hot-Failover Source object associated with a given context and topic. Warning: It is not safe to call this constructor from a context thread callback.

Parameters
lbmctxContext with which to associate the source.
lbmtopicLBMTopic used to initialize the source.
Exceptions
LBMExceptionif any error occurs creating the hot failover source.

References com.latencybusters.lbm.LBM.EINVAL.

com.latencybusters.lbm.LBMHotFailoverSource.LBMHotFailoverSource ( LBMContext  lbmctx,
LBMTopic  lbmtopic,
LBMSourceEventCallback  cb,
Object  cbArg 
) throws LBMException

Instantiate an LBM Hot-Failover Source object associated with a given context and topic and initialize source event callback. Warning: It is not safe to call this constructor from a context thread callback.

Parameters
lbmctxContext with which to associate the source.
lbmtopicLBMTopic used to initialize the source.
cbAn object implementing the LBMSourceEventCallback interface
cbArgCallback token object
Exceptions
LBMExceptionif any error occurs creating the hot failover source.

References com.latencybusters.lbm.LBMSource.addSourceCallback(), and com.latencybusters.lbm.LBM.EINVAL.

com.latencybusters.lbm.LBMHotFailoverSource.LBMHotFailoverSource ( LBMContext  lbmctx,
LBMTopic  lbmtopic,
LBMEventQueue  lbmevq 
) throws LBMException

Instantiate an LBM Hot-Failover Source object associated with a given context, topic, and event queue. Warning: It is not safe to call this constructor from a context thread callback.

Parameters
lbmctxContext with which to associate the source.
lbmtopicLBMTopic used to initialize the source.
lbmevqEvent queue with which to associate the source (all source events will be posted to this event queue).
Exceptions
LBMExceptionif any error occurs creating the hot failover source.

References com.latencybusters.lbm.LBM.EINVAL.

com.latencybusters.lbm.LBMHotFailoverSource.LBMHotFailoverSource ( LBMContext  lbmctx,
LBMTopic  lbmtopic,
LBMSourceEventCallback  cb,
Object  cbArg,
LBMEventQueue  lbmevq 
) throws LBMException

Instantiate an LBM Hot-Failover Source object associated with a given context, topic, and event queue and initialize source event callback. Warning: It is not safe to call this constructor from a context thread callback.

Parameters
lbmctxContext with which to associate the source.
lbmtopicLBMTopic used to initialize the source.
cbAn object implementing the LBMSourceEventCallback interface
cbArgCallback token object
lbmevqEvent queue with which to associate the source (all source events will be posted to this event queue).
Exceptions
LBMExceptionif any error occurs creating the hot failover source.

References com.latencybusters.lbm.LBMSource.addSourceCallback(), and com.latencybusters.lbm.LBM.EINVAL.

Member Function Documentation

int com.latencybusters.lbm.LBMSource.acquireMessageBufferPosition ( final int  messageLength,
final int  flags 
) throws LBMException
inherited

Reserve space in this source's messages buffer. When this method returns, we have guaranteed that there is sufficient space in the message buffer to safely write up to messageLength bytes starting at the returned position. The application must ensure that this contract is not broken. When message data has been written, call messageBuffersComplete() to make them available to receivers.

If non-blocking send, and the source would have to wait for recievers to catch up, a value of -1 is returned. This is in contrast to send methods that throw a new LBMEWouldBlockException and is done for performance reasons.

Only LBT-SMX transports currently support this method.

Warning Not thread safe among sources sharing the same transport.

Parameters
messageLengthLength in bytes to reserve in the messages buffer
flagsSource send flags
Returns
Position into the source messages buffer getMessagesBuffer() or -1 if Non-blocking and send would block.
Exceptions
LBMExceptionIf an error occurs
See also
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK

Referenced by com.latencybusters.lbm.LBMSource.getMessagesBuffer(), and com.latencybusters.lbm.LBMSource.messageBuffersCompleteAndAcquirePosition().

void com.latencybusters.lbm.LBMSource.addSourceCallback ( LBMSourceEventCallback  cb)
inherited
void com.latencybusters.lbm.LBMSource.addSourceCallback ( LBMSourceEventCallback  cb,
Object  cbArg 
)
inherited

Register a source event callback (and callback token)

Parameters
cbObject implementing the LBMSourceEventCallback interface
cbArgCallback token object
See also
LBMSourceEventCallback
removeSourceCallback
void com.latencybusters.lbm.LBMSource.close ( ) throws LBMException
inherited

Close this source

Warning: It is not safe to call this method from a context thread callback.

Exceptions
LBMExceptionif any error occurred during source deletion.

Referenced by com.latencybusters.lbm.LBMSource.finalize().

LBMSourceChannelInfo com.latencybusters.lbm.LBMSource.createChannel ( long  channelNumber) throws LBMException
inherited

Create a channel object to send messages with the given channel number. The application is responsible for calling close() or LBMSource.deleteChannel() on any LBMSourceChannelInfo object allocated via the LBMSourceChannelInfo constructor or the LBMSource.createChannel method once it is no longer being used. Failure to do so will result in unmanaged resources not being reclaimed.

Parameters
channelNumberChannel number in the range 0-4294967295
Returns
A new LBMSourceChannelInfo object
See also
LBMSourceChannelInfo
deleteChannel
void com.latencybusters.lbm.LBMSource.deleteChannel ( LBMSourceChannelInfo  channelInfo) throws LBMException
inherited

Delete a channel object

Parameters
channelInfoA channelInfo object
See also
LBMSourceChannelInfo
createChannel
LBMConfigOption [] com.latencybusters.lbm.LBMSource.dumpAttributeList ( )
inherited

Returns an array of LBMConfigOptions

Returns
Array of LBMConfigOption
void com.latencybusters.lbm.LBMHotFailoverSource.finalize ( ) throws LBMException
protected

This method is for internal use only, and is not supported for customer applications.

void com.latencybusters.lbm.LBMSource.flush ( ) throws LBMException
inherited

Send messages from both the explicit and implicit batches ASAP.

Note
calling lbm_src_flush() for a given source effectively flushes the implicit batcher for all sources on the same transport session.
Warning
Do not call this function from a context thread callback. It can result in deadlock.
Exceptions
LBMExceptionif any error occurred during sending.

References com.latencybusters.lbm.LBMSource.messageBuffersComplete(), and com.latencybusters.lbm.LBMSource.onResponse().

String com.latencybusters.lbm.LBMSource.getAttributeValue ( String  attributeName) throws LBMException
inherited

Returns the value of a source-related attribute for this source.

Parameters
attributeNameName of the attribute to retrieve
Returns
Value corresponding to the specified attribute name
Exceptions
LBMExceptionif attributeName is not a valid attribute.
int com.latencybusters.lbm.LBMSource.getInflight ( int  type) throws LBMException
inherited

Get the current inflight value for this source

Parameters
typeThe type of flight size
See also
LBM::FLIGHT_SIZE_TYPE_UME
LBM::FLIGHT_SIZE_TYPE_ULB
LBM::FLIGHT_SIZE_TYPE_UMQ
Returns
the inflight value
Exceptions
LBMExceptionif an error occurs while retrieving the inflight value

References com.latencybusters.lbm.LBMSource.setInflight().

LBMFlightSizeInflightInfo com.latencybusters.lbm.LBMSource.getInflightEx ( int  type) throws LBMException
inherited

Get the current inflight values of messages and bytes for this source

Parameters
typeThe type of flight size
See also
LBM::FLIGHT_SIZE_TYPE_UME
LBM::FLIGHT_SIZE_TYPE_ULB
LBM::FLIGHT_SIZE_TYPE_UMQ
Returns
the inflight value
Exceptions
LBMExceptionif an error occurs while retrieving the inflight value

References com.latencybusters.lbm.LBMSource.setInflightEx().

ByteBuffer com.latencybusters.lbm.LBMSource.getMessagesBuffer ( ) throws LBMException
inherited

Get the buffer for writing messages for an LBT-SMX source. This buffer will not change for the duration of this source. Messages are written into this buffer by using the return value of acquireMessageBufferPosition(final int, final int).

Only LBT-SMX transports currently support this method.

Returns
A DirectByteBuffer view of the transport window

References com.latencybusters.lbm.LBMSource.acquireMessageBufferPosition(), and com.latencybusters.lbm.LBMSource.messageBuffersComplete().

LBMSourceStatistics com.latencybusters.lbm.LBMSource.getStatistics ( ) throws LBMException
inherited

Return the current set of source transport statistics for this source.

Returns
LBMSourceStatistics object containing the statistics corresponding to this source.
Exceptions
LBMExceptionif any error occurred retrieving source statistics.

References com.latencybusters.lbm.LBMSourceStatistics.refresh().

boolean com.latencybusters.lbm.LBMSource.isClosed ( )
inherited

Returns boolean describing whether this instance has a reference to a valid C source

Returns
boolean describing whether this instance has a reference to a valid C source
void com.latencybusters.lbm.LBMSource.load ( InputStream  inStream) throws IOException
inherited

Reads a property (attribute) list (key and element pairs) from the input stream.

Parameters
inStreamInput stream of bytes
Exceptions
IOExceptionif any I/O error occurs.
LBMRuntimeExceptionif any invalid attribute is detected in inStream.

References com.latencybusters.lbm.LBMSource.setProperty().

void com.latencybusters.lbm.LBMSource.messageBuffersCancel ( ) throws LBMException
inherited

For this source, declare all previously acquired, but not completed, buffers to be invalid. The messages will not be delivered to receiving applications and the reserved buffer space will be ignored.

Only LBT-SMX transports currently support this method.

Warning Not thread safe among sources sharing the same transport.

See also
acquireMessageBufferPosition(final int, final int)
messageBuffersCompleteAndAcquirePosition(final int, final int)
Exceptions
LBMException

References com.latencybusters.lbm.LBM.EOS.

void com.latencybusters.lbm.LBMSource.messageBuffersComplete ( ) throws LBMException
inherited

Commits all previously acquired message buffers for this source's transport to be read by receivers. Call this when message data placed in the transport buffer is ready to be consumed by receivers. Calling this method with no new data has no effect.

Only LBT-SMX transports currently support this method.

Warning Not thread safe among sources sharing the same transport.

Exceptions
LBMException
See also
acquireMessageBufferPosition(final int, final int)
messageBuffersCompleteAndAcquirePosition(final int, final int)

Referenced by com.latencybusters.lbm.LBMSource.flush(), and com.latencybusters.lbm.LBMSource.getMessagesBuffer().

int com.latencybusters.lbm.LBMSource.messageBuffersCompleteAndAcquirePosition ( final int  messageLength,
final int  flags 
) throws LBMException
inherited

Convenience method that calls messageBuffersComplete() followed by acquireMessageBufferPosition(final int, final int). This is intended to reduce the number of calls per message.

Only LBT-SMX transports currently support this method.

Warning Not thread safe among sources sharing the same transport.

Parameters
messageLength- length in bytes to reserve in the messages buffer
flags- Source send flags
Returns
Position into the source messages buffer getMessagesBuffer() or -1 if Non-blocking and send would block.
Exceptions
LBMException
See also
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK

References com.latencybusters.lbm.LBMSource.acquireMessageBufferPosition().

int com.latencybusters.lbm.LBMSource.onResponse ( LBMRequest  lbmreq,
LBMMessage  lbmmsg 
)
protectedinherited

Default response message callback, which calls the interface specified when the request was sent. This method may be overridden by subclassing the LBMSource class.

Parameters
lbmreqLBMRequest object returned by corresponding send call
lbmmsgLBMMessage object containing the response data
Returns
an int, which should always be 0.
See also
send(LBMRequest, int)
send(LBMRequest, LBMEventQueue, int)

Referenced by com.latencybusters.lbm.LBMSource.flush().

int com.latencybusters.lbm.LBMSource.onSourceEvent ( LBMSourceEvent  sourceEvent)
protectedinherited

Default source event callback. Although possible, it is not recommended that this function be overridden by subclassing the LBMSource class. Instead, the source may be initialized using a constructor that specifies an LBMSourceEventCallback interface or by registering (deregistering) the callback using addSourceCallback() (removeSourceCallback()).

Parameters
sourceEventLBMSourceEvent object containing information about the posted source-related event.
Returns
an int, which is always 0.
See also
LBMSourceEvent
addSourceCallback
removeSourceCallback

References com.latencybusters.lbm.LBMSourceEventCallback.onSourceEvent(), and com.latencybusters.lbm.LBMSourceEvent.promote().

void com.latencybusters.lbm.LBMSource.removeSourceCallback ( LBMSourceEventCallback  cb)
inherited

Deregister a source event callback

Parameters
cbPreviously registered object implementing the LBMSourceEventCallback interface
See also
LBMSourceEventCallback
addSourceCallback
void com.latencybusters.lbm.LBMSource.removeSourceCallback ( LBMSourceEventCallback  cb,
Object  cbArg 
)
inherited

Deregister a source event callback (and callback token)

Parameters
cbPreviously registered object implementing the LBMSourceEventCallback interface
cbArgCallback token object
See also
LBMSourceEventCallback
addSourceCallback
void com.latencybusters.lbm.LBMSource.resetStatistics ( ) throws LBMException
inherited

Reset the transport statistics for this source.

Exceptions
LBMExceptionif any error occurred resetting source statistics.
void com.latencybusters.lbm.LBMHotFailoverSource.send ( byte []  message,
int  messageLength,
long  sqn,
int  flags 
) throws LBMException

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
messageLengthNumber of bytes of data to send in this message
sqnThe application sequence number to associate with this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
Exceptions
LBMExceptionif any error occurs sending the message.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
void com.latencybusters.lbm.LBMHotFailoverSource.send ( byte []  message,
int  messageLength,
long  sqn,
int  flags,
Object  cbArg 
) throws LBMException

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
messageLengthNumber of bytes of data to send in this message
sqnThe application sequence number to associate with this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
cbArgClient object to be passed back in stability or confirmation events related to this message (UME only)
Exceptions
LBMExceptionif any error occurs sending the message.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
LBM::SRC_EVENT_UME_MESSAGE_STABLE
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION
void com.latencybusters.lbm.LBMHotFailoverSource.send ( byte []  message,
int  messageLength,
long  sqn,
int  flags,
LBMSourceSendExInfo  exinfo 
) throws LBMException

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
messageLengthNumber of bytes of data to send in this message
sqnThe application sequence number to associate with this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
exinfoLBMSourceSendExInfo object, which includes flags to change callback behavior and a client-supplied object to be passed back. (UME only)
Exceptions
LBMExceptionif any error occurs sending the message.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
LBM::SRC_EVENT_UME_MESSAGE_STABLE
LBM::SRC_EVENT_UME_MESSAGE_STABLE_EX
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION_EX
LBMSourceSendExInfo
Since
UME 2.0
void com.latencybusters.lbm.LBMHotFailoverSource.send ( ByteBuffer  message,
int  startPosition,
int  messageLength,
long  sqn,
int  flags 
) throws LBMException

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
startPositionStarting position within the buffer to send from
messageLengthNumber of bytes of data to send in this message
sqnThe application sequence number to associate with this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
Exceptions
LBMExceptionif any error occurs sending the message.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
void com.latencybusters.lbm.LBMHotFailoverSource.send ( ByteBuffer  message,
int  startPosition,
int  messageLength,
long  sqn,
int  flags,
Object  cbArg 
) throws LBMException

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
startPositionStarting position within the buffer to send from
messageLengthNumber of bytes of data to send in this message
sqnThe application sequence number to associate with this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
cbArgClient object to be passed back in stability or confirmation events related to this message (UME only)
Exceptions
LBMExceptionif any error occurs sending the message.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
LBM::SRC_EVENT_UME_MESSAGE_STABLE
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION
void com.latencybusters.lbm.LBMHotFailoverSource.send ( ByteBuffer  message,
int  startPosition,
int  messageLength,
long  sqn,
int  flags,
LBMSourceSendExInfo  exinfo 
) throws LBMException

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
startPositionStarting position within the buffer to send from
messageLengthNumber of bytes of data to send in this message
sqnThe application sequence number to associate with this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
exinfoLBMSourceSendExInfo object, which includes flags to change callback behavior and a client-supplied object to be passed back. (UME only)
Exceptions
LBMExceptionif any error occurs sending the message.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
LBM::SRC_EVENT_UME_MESSAGE_STABLE
LBM::SRC_EVENT_UME_MESSAGE_STABLE_EX
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION_EX
LBMSourceSendExInfo
Since
UME 2.0
void com.latencybusters.lbm.LBMSource.send ( byte []  message,
int  messageLength,
int  flags 
) throws LBMException
inherited

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
messageLengthNumber of bytes of data to send in this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
LBM::SRC_EVENT_UME_MESSAGE_STABLE
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION
void com.latencybusters.lbm.LBMSource.send ( byte []  message,
int  messageLength,
int  flags,
Object  cbArg 
) throws LBMException
inherited

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
messageLengthNumber of bytes of data to send in this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
cbArgClient object to be passed back in stability or confirmation events related to this message (UME only)
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
LBM::SRC_EVENT_UME_MESSAGE_STABLE
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION
Deprecated:
This method exists for backwards compatibility but should not be used. The send method that accepts an LBMSourceSendExInfo object should be used instead.
void com.latencybusters.lbm.LBMSource.send ( byte []  message,
int  messageLength,
int  flags,
LBMSourceSendExInfo  exinfo 
) throws LBMException
inherited

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
messageLengthNumber of bytes of data to send in this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
exinfoLBMSourceSendExInfo object; used to set callback behavior flags and to pass back a user-supplied object.
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
LBM::SRC_EVENT_UME_MESSAGE_STABLE
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION
LBMSourceSendExInfo
Since
UME 2.0
void com.latencybusters.lbm.LBMSource.send ( ByteBuffer  message,
int  startPosition,
int  messageLength,
int  flags 
) throws LBMException
inherited

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
startPositionStarting position within the buffer to send from
messageLengthNumber of bytes of data to send in this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
LBM::SRC_EVENT_UME_MESSAGE_STABLE
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION
void com.latencybusters.lbm.LBMSource.send ( ByteBuffer  message,
int  startPosition,
int  messageLength,
int  flags,
Object  cbArg 
) throws LBMException
inherited

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
startPositionStarting position within the buffer to send from
messageLengthNumber of bytes of data to send in this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
cbArgClient object to be passed back in stability or confirmation events related to this message (UME only)
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
LBM::SRC_EVENT_UME_MESSAGE_STABLE
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION
Deprecated:
This method exists for backwards compatibility but should not be used. The send method that accepts an LBMSourceSendExInfo object should be used instead.
void com.latencybusters.lbm.LBMSource.send ( ByteBuffer  message,
int  startPosition,
int  messageLength,
int  flags,
LBMSourceSendExInfo  exinfo 
) throws LBMException
inherited

Send a message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
messageData to send in this message
startPositionStarting position within the buffer to send from
messageLengthNumber of bytes of data to send in this message
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
exinfoLBMSourceSendExInfo object; used to set callback behavior flags and to pass back a user-supplied object. (UME only)
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
LBM::SRC_EVENT_UME_MESSAGE_STABLE
LBM::SRC_EVENT_UME_DELIVERY_CONFIRMATION
LBMSourceSendExInfo
Since
UME 2.0
void com.latencybusters.lbm.LBMSource.send ( LBMRequest  lbmreq,
int  flags 
) throws LBMException
inherited

Send a request message to the topic associated with the LBM source.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
lbmreqLBMRequest object
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
void com.latencybusters.lbm.LBMSource.send ( LBMRequest  lbmreq,
LBMEventQueue  lbmevq,
int  flags 
) throws LBMException
inherited

Send a request message to the topic associated with the LBM source using an designated event queue for responses.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
lbmreqLBMRequest object
lbmevqLBMEventQueue used to handle response messages
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
void com.latencybusters.lbm.LBMSource.send ( LBMRequest  lbmreq,
LBMEventQueue  lbmevq,
int  flags,
LBMSourceSendExInfo  exinfo 
) throws LBMException
inherited

Send a request message to the topic associated with the LBM source using an designated event queue for responses.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
lbmreqLBMRequest object
lbmevqLBMEventQueue used to handle response messages
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
exinfoLBMSourceSendExInfo object; used to set callback behavior flags and to pass back a user-supplied object. (UME only)
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
void com.latencybusters.lbm.LBMSource.send ( LBMRequest  lbmreq,
int  flags,
LBMSourceSendExInfo  exinfo 
) throws LBMException
inherited

Send a request message to the topic associated with the LBM source using an designated event queue for responses.

Note
If called from a context thread callback, use the LBM_SRC_NONBLOCK flag and handle any LBM_EWOULDBLOCK errors internally.
Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
lbmreqLBMRequest object
flagsFlags indicating various conditions. See next section for possible OR'd set of values.
exinfoLBMSourceSendExInfo object; used to set callback behavior flags and to pass back a user-supplied object. (UME only)
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBM::MSG_START_BATCH
LBM::MSG_END_BATCH
LBM::MSG_COMPLETE_BATCH
LBM::MSG_FLUSH
LBM::SRC_NONBLOCK
LBM::SRC_BLOCK
void com.latencybusters.lbm.LBMHotFailoverSource.sendReceiverReset ( int  flags,
LBMSourceSendExInfo  exinfo 
) throws LBMException

Send a message that instructs hot-failover receivers to reset their state. In, and only in, the case that hf receivers cannot be manually restarted, this function can be used to allow delivering of previously sent sequence numbers. The hot-failover receiver will deliver a message of type LBM.MSG_HF_RESET and will include the new expected sequence number. The sequence number contained with the reset will be used as the next expected sequence number to be sent.

NOTE: The best way to reset a hot-failover receiver's state is to restart the receiver itself. This function should be used only when that is impossible.

Caution: It is not recommended to call this method from a context thread callback.

Warning: This method should only be used when it is impossible to restart hot failover receivers.

Warning
Do not call this function from a context thread callback for persistence stability or persistence confirmation events. It can result in deadlock.
Parameters
flagsFlags indicating various send conditions.
exinfoLBMSourceSendExInfo object which must include the hot failover sequence number to send
void com.latencybusters.lbm.LBMSource.sendStatistics ( ByteBuffer  message,
int  messageLength,
int  statsType 
) throws LBMException
inherited

Send a serialized PB message to the topic associated with the LBM source.

Parameters
messageByteBuffer that contains serialized PB stats to send.
messageLengthNumber of bytes in the ByteBuffer.
statsTypeIndicates the type of statistics being sent. See next section for set of possible values.
Exceptions
LBMExceptionif any error occurred during sending.
See also
LBMMonitor::LBMMON_PACKET_TYPE_SOURCE
LBMMonitor::LBMMON_PACKET_TYPE_RECEIVER
LBMMonitor::LBMMON_PACKET_TYPE_EVENT_QUEUE
LBMMonitor::LBMMON_PACKET_TYPE_CONTEXT
LBMMonitor::LBMMON_PACKET_TYPE_RECEIVER_TOPIC
LBMMonitor::LBMMON_PACKET_TYPE_WILDCARD_RECEIVER
LBMMonitor::LBMMON_PACKET_TYPE_UMESTORE
LBMMonitor::LBMMON_PACKET_TYPE_GATEWAY
LBMMonitor::LBMMON_PACKET_TYPE_UMDS
LBMMonitor::LBMMON_PACKET_TYPE_SRS
void com.latencybusters.lbm.LBMSource.setAttributeValue ( String  attributeName,
String  attributeValue 
) throws LBMException
inherited

Set the value of a source-related attribute for this source. Note that this method bypasses the property list. As such no attributes configured using this method will appear in the property list.

Parameters
attributeNameName of the attribute to set
attributeValueNew attribute value
Exceptions
LBMExceptionif attributeName is not a valid attribute, or attributeValue is not a valid value for attributeName.
See also
setProperty

Referenced by com.latencybusters.lbm.LBMSource.setProperty().

int com.latencybusters.lbm.LBMSource.setInflight ( int  type,
LBMSetInflightCallback  setInflightCb,
Object  clientd 
) throws LBMException
inherited

Set the current inflight value for this source.

Parameters
typeThe type of flight size
See also
LBM::FLIGHT_SIZE_TYPE_UME
LBM::FLIGHT_SIZE_TYPE_ULB
LBM::FLIGHT_SIZE_TYPE_UMQ
Parameters
setInflightCbObject that implements the LBMSetInflightCallback interface
clientdClientd object passed into the setInflight callback
Returns
the new inflight value
Exceptions
LBMExceptionif an error occurs while setting the inflight value

Referenced by com.latencybusters.lbm.LBMSource.getInflight().

LBMFlightSizeInflightInfo com.latencybusters.lbm.LBMSource.setInflightEx ( int  type,
LBMSetInflightCallback  setInflightCb,
Object  clientd 
) throws LBMException
inherited

Set the current inflight messages and bytes value for this source. The values are set from within the provided set inflight callback with appropriate locking held.

Parameters
typeThe type of flight size
See also
LBM::FLIGHT_SIZE_TYPE_UME
LBM::FLIGHT_SIZE_TYPE_ULB
LBM::FLIGHT_SIZE_TYPE_UMQ
Parameters
setInflightCbObject that implements the LBMSetInflightCallback interface
clientdClientd object passed into the setInflight callback
Returns
the new inflight values
Exceptions
LBMExceptionif an error occurs while setting the inflight value

Referenced by com.latencybusters.lbm.LBMSource.getInflightEx().

Object com.latencybusters.lbm.LBMSource.setProperty ( String  attributeName,
String  attributeValue 
)
inherited

Set the value of a source-related attribute for this source.

Parameters
attributeNameName of the attribute to set
attributeValueNew attribute value
Exceptions
LBMRuntimeExceptionif attributeName is not a valid attribute, or attributeValue is not a valid value for attributeName.

References com.latencybusters.lbm.LBMSource.setAttributeValue().

Referenced by com.latencybusters.lbm.LBMSource.load().

void com.latencybusters.lbm.LBMSource.setUMEMessageStable ( long  sqn) throws LBMException
inherited

Mark a specific sqn as stable, triggering an event if configured to do so, and adjusting the inflight if necessary.

Parameters
sqnSqn of the fragment to mark stable
Exceptions
LBMExceptionif an error occurs while marking the fragment stable
void com.latencybusters.lbm.LBMSource.umederegister ( ) throws LBMException
inherited

Deregister this source

Warning: It is not safe to call this method from a context thread callback.

Exceptions
LBMExceptionif any error occurred during source deletion.
void com.latencybusters.lbm.LBMSource.unblock ( ) throws LBMException
inherited

This method is for internal use only, and is not supported for customer applications.


The documentation for this class was generated from the following file: