Questions tagged [rabbitmq-exchange]

In RabbitMQ, messages are not published directly to a queue. Instead, the producer sends messages to an exchange. Use this tag only if your question is about the RabbitMQ Exchanges, or if the question revolves around the routing keys or message queues to which the exchange delivers the message for end publishing.

RabbitMQ is a message broker based on the AMPQ protocol.

Exchanges are AMQP entities where messages are sent. Exchanges take a message and route it into zero or more queues. The routing algorithm used depends on the exchange type and rules called bindings. AMQP 0-9-1 brokers provide four exchange types:

  • Direct exchange: (empty string) and amq.direct
  • Fanout exchange: amq.fanout
  • Topic exchange: amq.topic
  • Headers exchange: amq.match (and amq.headers in RabbitMQ)

Besides the exchange type, exchanges are declared with a number of attributes, the most important of which are:

  • Name
  • Durability (exchanges survive broker restart)
  • Auto-delete (exchange is deleted when all queues have finished using it)
  • Arguments (these are broker-dependent)

Exchanges can be durable or transient. Durable exchanges survive broker restart, whereas transient exchanges do not (they have to be redeclared when the broker comes back online). Not all scenarios and use cases require exchanges to be durable.

RabbitMQ is open source message broker software (sometimes called message-oriented middleware) that implements the Advanced Message Queuing Protocol (AMQP). The RabbitMQ server is written in the Erlang programming language and is built on the Open Telecom Platform framework for clustering and failover. Client libraries to interface with the broker are available for all major programming languages.

419 questions
1
vote
1 answer

Is there any limit for maximum number of TCP connections that can be made from a container to RabbitMQ

I am new in rabbitmq, So i am facing a in rabbitmq like "The connection cannot support anymore channels.Consider creating a new connection". So my doubt is can we create multiple tcp connections to rabbitmq from a single docker conatiner? Is there…
1
vote
2 answers

how can i stop the consumer if the queue is empty RabbitMQ?

so im new to RabbitMQ, i have implemented a simple producer-consumer and for my use case i need to stop the consumer if the queue is empty but i can't find any solution. sender: connection = pika.BlockingConnection( …
1
vote
2 answers

Why is Stream protocol connnection socket closed and how to open it

Currently I have a lot of log messages [warn] <0.7396.12> Stream protocol connection socket #Port<0.65372> closed [warn] <0.7421.12> Stream protocol connection socket #Port<0.65377> closed [warn] <0.7438.12> Stream protocol connection socket…
wwww
  • 760
  • 1
  • 11
  • 20
1
vote
0 answers

Rabbit MQ idle Queue not handling first message

We have a RabbitMQ queue that sometimes goes idle. Whenever we have 2 or more exchanges on this queue, the first one is missing and everything is OK for the others. It seems like the first one "wakes" the queue up but is not handled correctly. Is…
1
vote
0 answers

Central place for RabbitMQ queue binding management in a microservice-based app

I'm working on a microservice-based application. It is built of ca. 30 microservices and as usually some of them communicate with each other over RabbitMQ. Such services have names of exchanges, queues and routing keys in their configuration file…
ka3ak
  • 2,435
  • 2
  • 30
  • 57
1
vote
1 answer

RabbitMQ bulk consuming messages solution

I'm using RabbitMQ as a queue of different messages. When I consume this messages with two different consumers from one queue, I process them and insert processing results to a DB: def consumer_callback(self, channel, delivery_tag, properties,…
1
vote
2 answers

MassTransit exchange to exchange bindings benefit

The document said Published messages are routed to a receive endpoint queue by message type, using exchanges and exchange bindings. A service's receive endpoints do not affect other services or their receive endpoints, as long as they do not share…
Charlie
  • 2,141
  • 3
  • 19
  • 35
1
vote
1 answer

basicNack and basicReject in RabbitMQ

1.what is mean by message in bulk in basicNack The AMQP 0-9-1 specification defines the basic.reject method that allows clients to reject individual, delivered messages, instructing the broker to either discard them or requeue them. Unfortunately,…
1
vote
1 answer

How to organize exchanges and queues in rabbitmq to use with async CQRS buses

I'm scaffolding my backend application and I want to use CQRS and rabbitmq with it (I'm pretty new to rabbitmq). For that, I have specified different vhosts for my prod and dev environments, but I'm not sure how to use exchanges and queues for…
Isaac
  • 1,436
  • 2
  • 15
  • 29
1
vote
1 answer

What is the use of add_callback_threadsafe() method in pika?

From the description in the pika documentation, I can't quite get what add_callback_threadsafe() method does. It says, "Requests a call to the given function as soon as possible in the context of this connection’s thread". Specifically, which event…
sherlock
  • 2,397
  • 3
  • 27
  • 44
1
vote
1 answer

Microservices Not responding after subscribing to RabbitMQ fanout exchange

My .net core3.1 web application has say 4 microservices (MasterMS, PartyMS, ProductMS, PurchaseMS) and uses Rabbitmq as message broker. In one specific scenario, the MasterMS publishes an event (insert/update in Company table) to Rabbitmq exchange…
1
vote
1 answer

getting method not found exception while consuming rabbitmq message

Have created on consumer class to consume message from rabbitMQ GUI. but when i am publishing any message from rabbitMQ GUI its giving error class not found. and continuously error is printing on console. may be problem is rabbitGUI sending message…
1
vote
1 answer

How to setup RabbitMQ Dynamic Shovel in SSL

I want to setup a Shovel in which the destination RabbitMQ is configured to be TLS enabled. I am unable to create a Shovel and the shovel stays in a starting state. I have two different RabbitMQ instance in two separate docker container, one of them…
Suvojit
  • 379
  • 1
  • 7
  • 22
1
vote
1 answer

In RabbitMQ is there a way for making sure the consumer consumes the message and then only the flow continues?

I have some code after the consumer consumes, right now since the message queue is asynchronous the flow will continue even if the message is not consumed by the consumer. I want to wait till the consumer receives the message and till then the flow…
Akshay
  • 31
  • 4
1
vote
1 answer

Which is the best way to move data from exchange to another exchange for two differents RabbitMQ servers?

the thing is I have two RabbitMQ cluster servers (prod and dev) and in the prod server I have an exchange where external applications push data, but they only can push the data in one server I need to move the data from that prod exchange to a dev…
CarlosS
  • 161
  • 1
  • 13