Comments (4)
Hello @pnpdb, it depends on subscriber implementation :)
- For Kafka, it depends on the consumer group
- For Google Cloud Pub/Sub it depends on subscription name (you can pass how to generate it to Pub/Sub constructor config)
- For RabbitMQ it depends if you are using queue or pub/sub
- ... etc ;)
After you will provide a context which implementation are you using, I can probably help more :)
from watermill.
thank you very much, i have another question, for rabbitmq, how to use pull mod ? for example, i want to pull 100 messages once.
from watermill.
Hey @pnpdb, you're probably looking for QosConfig.PrefetchCount
: https://github.com/ThreeDotsLabs/watermill-amqp/blob/master/pkg/amqp/config.go#L449
from watermill.
@pnpdb I hope that that answered your question?
Also, the BulkRead
function may be useful:
watermill/message/subscriber/read.go
Line 10 in 63b5247
// BulkRead reads provided amount of messages from the provided channel, until a timeout occurrs or the limit is reached.
func BulkRead(messagesCh <-chan *message.Message, limit int, timeout time.Duration) (receivedMessages message.Messages, all bool) {
I'm closing the issue because all the questions seem to be answered :)
from watermill.
Related Issues (20)
- [watermill-kafka] "read tcp <ip>:<port>: i/o timeout" when kafka rebalances HOT 2
- watermill-sql cannot run in a MariaDB HOT 1
- Does Watermill support publishing delayed (set to a a future time) messages? HOT 5
- [watermill-sql] Use TIMESTAMP WITH TIME ZONE instead of plain TIMESTAMP
- Uses old Nats. HOT 6
- Blocking in GoChannel `sendMessageToSubscriber`
- [watermill-kafka] use github.com/IBM/sarama HOT 2
- nats jetstream consumer always received old ack message HOT 8
- Data doesn't get removed from subscribers and subscribersByTopicLock maps (GoChannel pub/sub)
- Allow for custom labels on prometheus metrics
- Skip First Publisher in Router HOT 3
- EventGroupProcessor does only execute the first registered handler for each event type HOT 3
- Slog with `AddSource: true` is not working correctly due to wrapper in watermill
- PGX Subscriber InvalidIfaceAssign HOT 1
- Log with fields on error in router HOT 3
- s
- MaxOutstandingMessages doesn't seem to be working
- follow-up handler will be broke while before msg handler error, what is the best practice for this situation?
- `msg.Nack` causes infinite loop with gochannel pubsub HOT 4
- Publish message processing delay in metrics Middleware?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from watermill.