- Mastering RabbitMQ
- Emrah Ayanoglu Yusuf Ayta? Dotan Nahum
- 496字
- 2021-07-23 14:52:50
The configuration file
The RabbitMQ environment variables mostly gives the control of location of files and directories, whereas the RabbitMQ configuration file gives the control of the engine, such as authentication, performance, memory limit, disc limit, exchanges, queues, bindings, and so on. The configuration
file is by default located in /etc/rabbitmq/rabbitmq.config
for Unix-based computers and $RABBITMQ_SERVER\etc\rabbitmq.config
for Windows-based computers, as discussed in the previous sections.
RabbitMQ has many configuration variables; however, we will discuss the most important ones here:
auth_mechanisms
: This is used to supports different types of authentication mechanisms. You can change the different type of authentication mechanism using this variable.default_user
: This is used as a default user to access the RabbitMQ server using the RabbitMQ client. Thedefault_user
variable simply defines the username of the default user.default_pass
: This is similar to thedefault_user
variable, as it simply defines the default user's password.default_permission
: This is similar todefault_user
anddefault_pass
. This variable describes the permissions of the default user.disk_free_limit
: This is used to controls the disk size for storing the messages into the disk. This variable defines the free disk size to give an alert to the RabbitMQ server administrator.heartbeat
: This is a configuration variable that indicates the time interval between beats. A beat is a packet sent from the broker to the client, and back so that the broker can understand whether a client is still connected or not and to keep a line open where some network equipment may cut it due to inactivity. In other protocols, such as the old and time-tested Internet Relay Chat (IRC), this trick was also known as ping-pong.hipe_compile
: As a default property, RabbitMQ is compiled with the default Erlang compiler; however, we can compile with the high performance Erlang compiler. RabbitMQ server is compiled at startup. Hipe compiling results in later start; however, Hipe Compile gives 20%-40% performance gain on message broker operations. Withhipe_compile
variable, we can control whether RabbitMQ will be compiled through high performance Erlang compiler or not.log_levels
: We have logs to control and trace the application for each of the software applications. Logs have different levels to show log messages according to its log level, that is, error, warning, and information. With this variable, you can decide on the log level.tcp_listeners
: This is the same as the server applications, such as FTP server, Mail server, and so on. The RabbitMQ server binds on the IP and port of the operating system. You can change its binding port and IP with thetcp_listeners
variable.ssl_listeners
: Whenever clients listen to the server with SSL, the RabbitMQ server uses a different IP and port. Thessl_listeners
variable just defines the IP and port of the SSL client connections.vm_memory_high_watermark
: Free memory size is reasonably important for the RabbitMQ server. RabbitMQ alerts the memory problem with the given free memory ratio invm_memory_high_watermark
.
The following table describes the most of the important variables with given default values:
Configuration Variables:

推薦閱讀
- Java Web及其框架技術
- Practical DevOps
- Java深入解析:透析Java本質的36個話題
- JavaScript從入門到精通(第3版)
- 網店設計看這本就夠了
- Drupal 8 Configuration Management
- 數據結構與算法分析(C++語言版)
- R Data Analysis Cookbook(Second Edition)
- Mastering Xamarin.Forms(Second Edition)
- 微信小程序開發與實戰(微課版)
- 汽車人機交互界面整合設計
- Angular Design Patterns
- Drupal Search Engine Optimization
- Implementing Microsoft Dynamics NAV(Third Edition)
- Android 游戲開發大全(第二版)