public VoltMessage poll ( ) { if ( m_mustDrain || m_replayEntries . isEmpty ( ) ) { return null ; } if ( m_replayEntries . firstEntry ( ) . getValue ( ) . isEmpty ( ) ) { m_replayEntries . pollFirstEntry ( ) ; } // All the drain conditions depend on being blocked, which // we will only really know for sure when we try to poll(). checkDrainCondition ( ) ; if ( m_mustDrain || m_replayEntries . isEmpty ( ) ) { return null ; } VoltMessage m = m_replayEntries . firstEntry ( ) . getValue ( ) . poll ( ) ; updateLastPolledUniqueId ( m_replayEntries . firstEntry ( ) . getKey ( ) , ( TransactionInfoBaseMessage ) m ) ; return m ; }
Return the next correctly sequenced message or null if none exists .