当前位置:网站首页>channel. Detailed explanation of queuedeclare parameters
channel. Detailed explanation of queuedeclare parameters
2022-07-07 08:49:00 【Mikaelemmmm】
channel.QueueDeclare(name, durable, autoDelete, exclusive, noWait, args)
name: The queue name
durable: Persistent or not , The queue declaration is stored in memory by default , If rabbitmq Restart will lose , If you want to exist after restart, you need to make the queue persistent , Save to Erlang Self contained Mnesia In the database , When rabbitmq The database will be read after restart
autoDelete: Whether to automatically delete the queue after data consumption in the queue is completed , Whether the queue is automatically deleted after the last consumer disconnects , Can pass RabbitMQ Management, View the number of consumers in a queue , When consumers = 0 The queue will be deleted automatically
exclusive: Is it exclusive , It does two things , One : When the connection is closed connection.close() Whether the queue will be automatically deleted ; Two : Whether the queue is private private, If not exclusive , You can use both consumers to access the same queue , No problem , If it's exclusive , Lock the current queue , Other channels channel It's not accessible , If forced access, an exception will be reported :com.rabbitmq.client.ShutdownSignalException: channel error; protocol method: #method<channel.close>(reply-code=405, reply-text=RESOURCE_LOCKED - cannot obtain exclusive access to locked queue 'queue_name' in vhost '/', class-id=50, method-id=20) Generally equal to true It is used in the scenario that only one consumer can consume in a queue
noWait: Whether to wait for the server to return
args: Related parameters , At present, it is generally nil
边栏推荐
- oracle一次性说清楚,多种分隔符的一个字段拆分多行,再多行多列多种分隔符拆多行,最终处理超亿亿。。亿级别数据量
- POJ - 3616 Milking Time(DP+LIS)
- opencv之图像分割
- redis故障处理 “Can‘t save in background: fork: Cannot allocate memory“
- 说一个软件创业项目,有谁愿意投资的吗?
- 【踩坑】nacos注册一直连接localhost:8848,no available server
- Data type - integer (C language)
- let const
- 对API接口或H5接口做签名认证
- Why choose cloud native database
猜你喜欢

Merge sort and non comparison sort

IP地址的类别

Greenplum 6.x common statements

Data type - floating point (C language)

National standard gb28181 protocol video platform easygbs adds streaming timeout configuration
![[Yugong series] February 2022 U3D full stack class 005 unity engine view](/img/19/dc1b2f74b9ec5f5808de3049793862.jpg)
[Yugong series] February 2022 U3D full stack class 005 unity engine view

oracle一次性说清楚,多种分隔符的一个字段拆分多行,再多行多列多种分隔符拆多行,最终处理超亿亿。。亿级别数据量

Compilation and linking of programs

数字三角形模型 AcWing 1027. 方格取数

Greenplum 6.x reinitialization
随机推荐
详解华为应用市场2022年逐步减少32位包体上架应用和策略
Through the "last mile" of legal services for the masses, fangzheng Puhua labor and personnel law self-service consulting service platform has been frequently "praised"
[wechat applet: cache operation]
更改当前文件夹及文件夹下文件日期shell脚本
[kuangbin]专题十五 数位DP
[Yugong series] February 2022 U3D full stack class 005 unity engine view
調用華為遊戲多媒體服務的創建引擎接口返回錯誤碼1002,錯誤信息:the params is error
Greenplum6.x重新初始化
How to integrate app linking services in harmonyos applications
Data analysis methodology and previous experience summary 2 [notes dry goods]
Greenplum6.x-版本变化记录-常用手册
About using CDN based on Kangle and EP panel
GOLand idea intellij 无法输入汉字
let const
AVL balanced binary search tree
Componentspace2022, assertions, protocols, bindings, and configuration files
IP guard helps energy enterprises improve terminal anti disclosure measures to protect the security of confidential information
[Chongqing Guangdong education] accounting reference materials of Nanjing University of Information Engineering
idea里使用module项目的一个bug
POJ - 3616 Milking Time(DP+LIS)