blob: 650f0b4b98359569abd9564ef30699b7b41b952b (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
|
package memory
import (
"github.com/spiral/roadrunner/v2/pkg/pubsub"
"github.com/spiral/roadrunner/v2/plugins/logger"
)
const PluginName string = "memory"
type Plugin struct {
log logger.Logger
}
func (p *Plugin) Init(log logger.Logger) error {
p.log = log
return nil
}
func (p *Plugin) PSProvide(key string) (pubsub.PubSub, error) {
return NewPubSubDriver(p.log, key)
}
func (p *Plugin) Name() string {
return PluginName
}
|