2021-07-17 12:14:19 +00:00
|
|
|
package core
|
|
|
|
|
|
|
|
// Queue as backend
|
|
|
|
type Queue string
|
|
|
|
|
|
|
|
var (
|
|
|
|
// LocalQueue for channel in Go
|
|
|
|
LocalQueue Queue = "local"
|
|
|
|
// NSQ a realtime distributed messaging platform
|
|
|
|
NSQ Queue = "nsq"
|
|
|
|
// NATS Connective Technology for Adaptive Edge & Distributed Systems
|
|
|
|
NATS Queue = "nats"
|
2022-01-01 15:04:13 +00:00
|
|
|
// Redis Pub/Sub
|
|
|
|
Redis Queue = "redis"
|
2021-07-17 12:14:19 +00:00
|
|
|
)
|
|
|
|
|
|
|
|
// IsLocalQueue check is Local Queue
|
|
|
|
func IsLocalQueue(q Queue) bool {
|
|
|
|
return q == LocalQueue
|
|
|
|
}
|