You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

73 lines
3.0 KiB

  1. <?php
  2. use PhpAmqpLib\Message\AMQPMessage;
  3. return [
  4. /* Default connection */
  5. 'default' => env('AMQP_CONNECTION', 'rabbitmq'),
  6. /*Available connections*/
  7. 'connections' => [
  8. 'rabbitmq' => [
  9. 'connection' => [
  10. 'host' => env('AMQP_HOST', 'liwo_rabbitmq_1'),
  11. 'port' => env('AMQP_PORT', 5672),
  12. 'username' => env('AMQP_USERNAME', 'root'),
  13. 'password' => env('AMQP_PASSWORD', 'root'),
  14. 'vhost' => env('AMQP_VHOST', '/'),
  15. 'connect_options' => [],
  16. 'ssl_options' => [],
  17. 'ssl_protocol' => env('AMQP_SSL_PROTOCOL', 'ssl'),
  18. ],
  19. 'channel_id' => null,
  20. 'message' => [
  21. 'content_type' => 'text/plain',
  22. 'delivery_mode' => env('AMQP_MESSAGE_DELIVERY_MODE', AMQPMessage::DELIVERY_MODE_PERSISTENT),
  23. 'content_encoding' => 'UTF-8',
  24. ],
  25. 'exchange' => [
  26. 'name' => env('AMQP_EXCHANGE_NAME', 'activity_exchange'),
  27. 'declare' => env('AMQP_EXCHANGE_DECLARE', false),
  28. 'type' => env('AMQP_EXCHANGE_TYPE', 'headers'),
  29. 'passive' => env('AMQP_EXCHANGE_PASSIVE', false),
  30. 'durable' => env('AMQP_EXCHANGE_DURABLE', true),
  31. 'auto_delete' => env('AMQP_EXCHANGE_AUTO_DEL', false),
  32. 'internal' => env('AMQP_EXCHANGE_INTERNAL', false),
  33. 'nowait' => env('AMQP_EXCHANGE_NOWAIT', false),
  34. 'properties' => [],
  35. ],
  36. 'queue' => [
  37. 'declare' => env('AMQP_QUEUE_DECLARE', false),
  38. 'passive' => env('AMQP_QUEUE_PASSIVE', false),
  39. 'durable' => env('AMQP_QUEUE_DURABLE', true),
  40. 'exclusive' => env('AMQP_QUEUE_EXCLUSIVE', false),
  41. 'auto_delete' => env('AMQP_QUEUE_AUTO_DEL', false),
  42. 'nowait' => env('AMQP_QUEUE_NOWAIT', false),
  43. 'd_properties' => [], // queue_declare properties/arguments
  44. 'b_properties' => [], // queue_bind properties/arguments
  45. ],
  46. 'consumer' => [
  47. 'tag' => env('AMQP_CONSUMER_TAG', ''),
  48. 'no_local' => env('AMQP_CONSUMER_NO_LOCAL', false),
  49. 'no_ack' => env('AMQP_CONSUMER_NO_ACK', false),
  50. 'exclusive' => env('AMQP_CONSUMER_EXCLUSIVE', false),
  51. 'nowait' => env('AMQP_CONSUMER_NOWAIT', false),
  52. 'ticket' => null,
  53. 'properties' => [],
  54. ],
  55. 'qos' => [
  56. 'enabled' => env('AMQP_QOS_ENABLED', false),
  57. 'qos_prefetch_size' => env('AMQP_QOS_PREF_SIZE', 0),
  58. 'qos_prefetch_count' => env('AMQP_QOS_PREF_COUNT', 1),
  59. 'qos_a_global' => env('AMQP_QOS_GLOBAL', false),
  60. ],
  61. ],
  62. ],
  63. ];