# Logstash RabbitMQ input with lazy queue

**URL:** <https://discuss.elastic.co/t/logstash-rabbitmq-input-with-lazy-queue/185221>\
**Category:** Logstash\
**Created:** [June 11, 2019, 2:49pm UTC](https://discuss.elastic.co/t/logstash-rabbitmq-input-with-lazy-queue/185221 "2019-06-11T14:49:29Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![pszemesy](https://avatars.discourse-cdn.com/v4/letter/p/e8c25b/32.png) [@pszemesy](https://discuss.elastic.co/u/pszemesy)\
**Post date:** [June 11, 2019, 2:49pm UTC](https://discuss.elastic.co/t/logstash-rabbitmq-input-with-lazy-queue/185221/1 "2019-06-11T14:49:29Z")

</div>

Hi,

I would like to load data from RabbitMQ with Logstash with the following pipeline:  
input {  
rabbitmq {  
host =\> "xxx.xxx.xxx.xxx"  
port =\> 5672  
user =\> "guest"  
password =\> "guest"  
queue =\> "test\_queue"  
durable =\> true  
}  
}  
filter {  
}  
output {  
stdout {  
codec =\> rubydebug  
}

file {  
codec =\> json  
path =\> "/data/rabbit/test-%{+YYYY-MM-dd}.json"  
}  
}

I receive the following error in the logstash-plain.log:  
Error while setting up connection for rabbitmq input! Will retry. {:message=\>"#method\<channel.close\>(reply-code=406, reply-text=PRECONDITION\_FAILED - inequivalent arg 'x-queue-mode' for queue 'test\_queue' in vhost '/': received none but current is the value 'lazy' of type 'longstr', class-id=50, method-id=10)"

Please help me with this pipeline!  
Thx

---

<div class="post-metadata">

**Author:** ![pszemesy](https://avatars.discourse-cdn.com/v4/letter/p/e8c25b/32.png) [@pszemesy](https://discuss.elastic.co/u/pszemesy)\
**Post date:** [June 12, 2019, 11:49am UTC](https://discuss.elastic.co/t/logstash-rabbitmq-input-with-lazy-queue/185221/2 "2019-06-12T11:49:21Z")

</div>

I was stupid!  
The answer is:  
arguments =\> {  
"x-queue-mode" =\> "lazy"  
}

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)\
**Post date:** [July 10, 2019, 11:49am UTC](https://discuss.elastic.co/t/logstash-rabbitmq-input-with-lazy-queue/185221/3 "2019-07-10T11:49:24Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
