-
Notifications
You must be signed in to change notification settings - Fork 1
/
plug.go
83 lines (66 loc) · 1.5 KB
/
plug.go
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
package mqm
import (
"context"
"github.com/semenovem/mqm/v2/queue"
"github.com/sirupsen/logrus"
)
type plug struct {
log *logrus.Entry
}
func (p plug) Put(context.Context, *queue.Msg) error {
p.log.Panic(ErrNotInitialised)
return nil
}
func (p plug) Get(context.Context, *queue.Msg) error {
p.log.Panic(ErrNotInitialised)
return nil
}
func (p plug) GetByCorrelId(context.Context, []byte) (*queue.Msg, error) {
p.log.Panic(ErrNotInitialised)
return nil, nil
}
func (p plug) GetByMsgId(context.Context, []byte) (*queue.Msg, error) {
p.log.Panic(ErrNotInitialised)
return nil, nil
}
func (p plug) Browse(context.Context) (<-chan *queue.Msg, error) {
p.log.Panic(ErrNotInitialised)
return nil, nil
}
func (p plug) Alias() string {
p.log.Panic(ErrNotInitialised)
return ""
}
func (p plug) CfgByStr(string) error {
p.log.Panic(ErrNotInitialised)
return nil
}
func (p plug) IsConfigured() bool {
p.log.Panic(ErrNotInitialised)
return false
}
func (p plug) Open() error {
p.log.Panic(ErrNotInitialised)
return nil
}
func (p plug) Close() error {
p.log.Panic(ErrNotInitialised)
return nil
}
func (p plug) UpdateBaseCfg() {
p.log.Panic(ErrNotInitialised)
}
func (p plug) IsSubscribed() bool {
p.log.Panic(ErrNotInitialised)
return false
}
func (p plug) RegisterInMsg(func(*queue.Msg)) {
p.log.Panic(ErrNotInitialised)
}
func (p plug) UnregisterInMsg() {
p.log.Panic(ErrNotInitialised)
}
func (p plug) Ready() bool {
p.log.Panic(ErrNotInitialised)
return false
}