- Refactor automatic subscribing to personal channel option. Option that enables feature renamed from
UserSubscribePersonal
toUserSubscribeToPersonal
, also instead ofUserPersonalChannelPrefix
users can setUserPersonalChannelNamespace
option, the general advice here is to create separate namespace for automatic personal channels if one requires custom channel options WebsocketUseWriteBufferPool
option for SockJS handler
- Simplify server-side subscription API replacing
[]centrifuge.Subscription
with just[]string
- i.e. a slice of channels we want to subscribe connection to. For now it seems much more simple to just use a slice of strings and this must be sufficient for most use cases. It is also a bit more efficient for JWT use case in terms of its payload size. More complex logic can be introduced later over separate field ofConnectReply
orconnectToken
if needed - Support server-side subscriptions via JWT using
channels
claim field
This release introduces server-side subscription support - see #89 for details. Release highlights:
- New field
Subscriptions
forConnectReply
to provide server side subscriptions - New
Client.Subscribe
method - New node configuration options:
UserSubscribePersonal
andUserPersonalChannelPrefix
- New
ServerSide
boolean namespace option - Method
Client.Unsubscribe
now accepts one main argument (channel
) andUnsubscribeOptions
- New option
UseWriteBufferPool
for WebSocket handler config - Internal refactor of JWT related code, many thanks to @Nesty92
- Introduce subscription dissolver - node now reliably unsubscribes from PUB/SUB channels, see details in #77
Secret
config option renamed toTokenHMACSecretKey
, that was reasonable due to recent addition of RSA-based tokens so we now haveTokenRSAPublicKey
option