diff options
author | Valery Piashchynski <[email protected]> | 2021-05-18 15:36:06 +0300 |
---|---|---|
committer | Valery Piashchynski <[email protected]> | 2021-05-18 15:36:06 +0300 |
commit | f85172106b4723b705aa75c3c310e8cebd050a8d (patch) | |
tree | aa98200d5d01776d4328c31c79b8af52986a4375 /plugins/broadcast/ws/subscriber.go | |
parent | 60a3793f83c672e24283c009f53e780a4932be50 (diff) |
- Add protected connection
- Update arch diagram
- Update interfaces
Signed-off-by: Valery Piashchynski <[email protected]>
Diffstat (limited to 'plugins/broadcast/ws/subscriber.go')
-rw-r--r-- | plugins/broadcast/ws/subscriber.go | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/plugins/broadcast/ws/subscriber.go b/plugins/broadcast/ws/subscriber.go index 98592950..2039cf95 100644 --- a/plugins/broadcast/ws/subscriber.go +++ b/plugins/broadcast/ws/subscriber.go @@ -1 +1,35 @@ package ws + +import "github.com/spiral/roadrunner/v2/plugins/broadcast" + +type Subscriber struct { + connections map[string]*Connection + storage broadcast.Storage +} + +func NewWSSubscriber() (broadcast.Subscriber, error) { + m := make(map[string]*Connection) + return &Subscriber{ + connections: m, + }, nil +} + +func (s *Subscriber) Subscribe(upstream chan *broadcast.Message, topics ...string) error { + panic("implement me") + + + + +} + +func (s *Subscriber) SubscribePattern(upstream chan *broadcast.Message, pattern string) error { + panic("implement me") +} + +func (s *Subscriber) Unsubscribe(upstream chan *broadcast.Message, topics ...string) error { + panic("implement me") +} + +func (s *Subscriber) UnsubscribePattern(upstream chan *broadcast.Message, pattern string) error { + panic("implement me") +} |