Questions about configuring a pubsub node

Hey I’m working on a pubsub client and I have a few questions about configuring the nodes. I was wondering if it was possible to configure a pubsub node to retain messages if the subscribers are offline? So that when the subscribers come online they will receive any messages published to the node while they were offline. Also, when I shut down the server I want the messages to be persisted.

Another question about subscribing and unsubscribing. I think we might have found a bug. It looks like if you subscribe an account to a node, they become a subscriber for life. Even if you remove the affiliation to that node, they still receive published messages.

Thanks for any help!

There are two different features at work here. If your subscriptions are not presence based, then they may already be diverted to offline storage when they are sent. This has nothing to do with the node or pubsub for that matter. I have never actually tried this so I am not sure if any specific configuration is required to support this or not. The other question is whether it is desirable to have all those messages stored on a per user basis.

As for the node itself, it can be configured to be persistent, which will save all messages (or a specified number) to persistent storage. To retrieve these messages you send a getItems() request.

As for the subscribe for life. Do you mean that unsubscribe is not working? Affiliations and subscriptions are two different things.