TibrvCmTransport.removeSendState()

Method

Declaration

void removeSendState(
    java.lang.String    subject)
  throws TibrvException

Purpose

Reclaim ledger space from obsolete subjects.

Background

In some programs subject names are useful only for a limited time; after that time, they are never used again. For example, consider a server program that sends certified reply messages to client inbox names; it only sends one reply message to each inbox, and after delivery is confirmed and complete, that inbox name is obsolete. Nonetheless, a record for that inbox name remains in the server’s ledger.

As such obsolete records accumulate, the ledger size grows. To counteract this growth, programs can use this method to discard obsolete subject records from the ledger.

The DELIVERY.COMPLETE advisory is a good opportunity to clear the send state of an obsolete subject. Another strategy is to review the ledger periodically, sweeping to detect and remove all obsolete subjects.

Warning 

Do not use this method to clear subjects that are still in use.

Parameter

Description

subject

Remove send state for this obsolete subject.

Remarks

As a side-effect, this method resets the sequence numbering for the subject, so the next message sent on the subject would be number 1. In proper usage, this side-effect is never detected, since obsolete subjects are truly obsolete.

See Also

TibrvCmTransport.reviewLedger()

TibrvCmTransport.send()

DELIVERY.COMPLETE in TIBCO Rendezvous Concepts