redisqueue alternatives and similar packages
Based on the "Messaging" category.
Alternatively, view redisqueue alternatives based on common mentions on social networks and blogs.
-
Centrifugo
Scalable real-time messaging server in a language-agnostic way. Set up once and forever. -
machinery
Machinery is an asynchronous task queue/job queue based on distributed message passing. -
NATS Go Client
Golang client for NATS, the cloud native messaging system. -
Confluent Kafka Golang Client
Confluent's Apache Kafka Golang client -
Mercure
An open, easy, fast, reliable and battery-efficient solution for real-time communications -
APNs2
⚡ HTTP/2 Apple Push Notification Service (APNs) push provider for Go — Send push notifications to iOS, tvOS, Safari and OSX apps, using the APNs HTTP/2 protocol. -
Uniqush-Push
Uniqush is a free and open source software system which provides a unified push service for server side notification to apps on mobile devices. -
Chanify
Chanify is a safe and simple notification tools. This repository is command line tools for Chanify. -
amqp
An AMQP 0-9-1 Go client maintained by the RabbitMQ team. Originally by @streadway: `streadway/amqp` -
mangos
mangos is a pure Golang implementation of nanomsg's "Scalablilty Protocols" -
PingMe
PingMe is a CLI which provides the ability to send messages or alerts to multiple messaging platforms & email. -
emitter
Emits events in Go way, with wildcard, predicates, cancellation possibilities and many other good wins -
Bus
🔊Minimalist message bus implementation for internal communication with zero-allocation magic on Emit -
go-mq
Declare AMQP entities like queues, producers, and consumers in a declarative way. Can be used to work with RabbitMQ. -
nsq-event-bus
A tiny wrapper around NSQ topic and channel :rocket: -
go-events
:mega: Pure nodejs EventEmmiter for the Go Programming Language. -
drone-line
Sending line notifications using a binary, docker or Drone CI. -
RapidMQ
RapidMQ is a pure, extremely productive, lightweight and reliable library for managing of the local messages queue -
Ratus
Ratus is a RESTful asynchronous task queue server. It translated concepts of distributed task queues into a set of resources that conform to REST principles and provides a consistent HTTP API for various backends. -
go-notify
Package notify provides an implementation of the Gnome DBus Notifications Specification. -
Commander
Build event-driven and event streaming applications with ease -
structured pubsub
Publish and subscribe functionality within a single process in Go. -
go-vitotrol
golang client library to Viessmann Vitotrol web service -
go-longpoll
Parked: PubSub queuing with long-polling subscribers (not bound to http) -
jazz
Abstraction layer for simple rabbitMQ connection, messaging and administration
Access the most powerful time series database as a service
Do you think we are missing an alternative of redisqueue or a related project?
README
redisqueue
redisqueue
provides a producer and consumer of a queue that uses Redis
streams.
Features
- A
Producer
struct to make enqueuing messages easy. - A
Consumer
struct to make processing messages concurrenly. - Claiming and acknowledging messages if there's no error, so that if a consumer dies while processing, the message it was working on isn't lost. This guarantees at least once delivery.
- A "visibility timeout" so that if a message isn't processed in a designated time frame, it will be be processed by another consumer.
- A max length on the stream so that it doesn't store the messages indefinitely and run out of memory.
- Graceful handling of Unix signals (
SIGINT
andSIGTERM
) to let in-flight messages complete. - A channel that will surface any errors so you can handle them centrally.
- Graceful handling of panics to avoid crashing the whole process.
- A concurrency setting to control how many goroutines are spawned to process messages.
- A batch size setting to limit the total messages in flight.
- Support for multiple streams.
Installation
redisqueue
requires a Go version with Modules support and uses import
versioning. So please make sure to initialize a Go module before installing
redisqueue
:
go mod init github.com/my/repo
go get github.com/robinjoseph08/redisqueue/v2
Import:
import "github.com/robinjoseph08/redisqueue/v2"
Example
Here's an example of a producer that inserts 1000 messages into a queue:
package main
import (
"fmt"
"github.com/robinjoseph08/redisqueue/v2"
)
func main() {
p, err := redisqueue.NewProducerWithOptions(&redisqueue.ProducerOptions{
StreamMaxLength: 10000,
ApproximateMaxLength: true,
})
if err != nil {
panic(err)
}
for i := 0; i < 1000; i++ {
err := p.Enqueue(&redisqueue.Message{
Stream: "redisqueue:test",
Values: map[string]interface{}{
"index": i,
},
})
if err != nil {
panic(err)
}
if i%100 == 0 {
fmt.Printf("enqueued %d\n", i)
}
}
}
And here's an example of a consumer that reads the messages off of that queue:
package main
import (
"fmt"
"time"
"github.com/robinjoseph08/redisqueue/v2"
)
func main() {
c, err := redisqueue.NewConsumerWithOptions(&redisqueue.ConsumerOptions{
VisibilityTimeout: 60 * time.Second,
BlockingTimeout: 5 * time.Second,
ReclaimInterval: 1 * time.Second,
BufferSize: 100,
Concurrency: 10,
})
if err != nil {
panic(err)
}
c.Register("redisqueue:test", process)
go func() {
for err := range c.Errors {
// handle errors accordingly
fmt.Printf("err: %+v\n", err)
}
}()
fmt.Println("starting")
c.Run()
fmt.Println("stopped")
}
func process(msg *redisqueue.Message) error {
fmt.Printf("processing message: %v\n", msg.Values["index"])
return nil
}
*Note that all licence references and agreements mentioned in the redisqueue README section above
are relevant to that project's source code only.