PubSubSubscribeOptions

Configuration bounding a PubSub subscription's history volume and live delivery rate.

Passed to subscribe, these limit how much history is replayed on subscribe (setOldMessageLimit), cap how fast live messages are delivered (setNewMessageLimit), and choose what happens to live messages arriving faster than they drain (RealtimeOverflow).

They do not change how messages are delivered. History streams in server-paced batches via onOldMessagesReceived with or without options, and live batching is a server-side setting rather than a subscribe option.

Code Example:


try {
    PubSubSubscribeOptions options = new PubSubSubscribeOptions();
    options.setOldMessageLimit(100);
    options.setRealtimeOverflow(PubSubSubscribeOptions.RealtimeOverflow.QUEUE);
    options.setMaxQueue(70);
    meeting.pubSub.subscribe("CHAT", listener, options);
} catch (Exception e) {
    Log.d("VideoSDK", "subscribe failed: " + e.getMessage());
}

See also

Meeting.PubSub.subscribe()

Constructors

Link copied to clipboard
constructor()

Types

Link copied to clipboard
Policy for live messages that arrive faster than they can be delivered.

Properties

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard