go-sdk/design
Repository files (latest commit first)
Filename Latest commit message Latest commit date
Jim Clark cb17593a5d
update Subscribe/Unsubscribe handlers in ServerOpts (#231)
## Background

Since the Server has a map of ServersSessions->subscriptions, and takes
care of routing ResourceUpdate messages to ServerSessions, I think the
decision was made to leave *ServerSession out of the
SubscribeHandler/UnsubscribeHandler signatures. However, resource
subscriptions are not specific to the a particular client and this
information is kept private in the Session today.

## Proposal

Align the Subscribe/Unsubscribe handlers with the other two handlers
that are client specific (ProgressNotificationHandler, and
RootListChangeHanlder), and include *ServerSession in the signature.

It comes in practice because because a gateway server that needs to
forward subscriptions still needs this information. The routing logic in
Server is convenient and means that most servers won't need to know
which ServerSessions are subscribed. But I think there are still use
cases where the user will need to know.
2025-08-04 14:46:49 -04:00
..
design.md update Subscribe/Unsubscribe handlers in ServerOpts (#231) 2025-08-04 14:46:49 -04:00