2016-03-01 78 views
0

我有一个兔子配置文件,它包含一个JSON。据我所知,通过使用我可以配置RabbitMQ,但我不知道我必须把该文件或如何运行它。RabbitMQ配置脚本

{ 
    "rabbit_version": "3.5.6", 
    "users": [{ 
      "name": "guest", 
      "password_hash": "GAd/n+dflOQhAEnqkF6y2V0TMrU=", 
      "tags": "administrator" 
     } 
    ], 
    "vhosts": [{ 
      "name": "/" 
     } 
    ], 
    "permissions": [{ 
      "user": "guest", 
      "vhost": "/", 
      "configure": ".*", 
      "write": ".*", 
      "read": ".*" 
     } 
    ], 
    "parameters": [], 
    "policies": [], 
    "queues": [{ 
      "name": "stream.service.postpaid", 
      "vhost": "/", 
      "durable": true, 
      "auto_delete": false, 
      "arguments": {} 
     }, { 
      "name": "stream.smart.dl.postpaid", 
      "vhost": "/", 
      "durable": true, 
      "auto_delete": false, 
      "arguments": {} 
     }, { 
      "name": "stream.smart.postpaid", 
      "vhost": "/", 
      "durable": true, 
      "auto_delete": false, 
      "arguments": { 
       "x-max-length": 100000, 
       "x-dead-letter-exchange": "decoder.dl.sn", 
       "x-message-ttl": 60000 
      } 
     } 
    ], 
    "exchanges": [{ 
      "name": "decoder.sn", 
      "vhost": "/", 
      "type": "topic", 
      "durable": true, 
      "auto_delete": false, 
      "internal": false, 
      "arguments": {} 
     }, { 
      "name": "decoder.dl.sn", 
      "vhost": "/", 
      "type": "topic", 
      "durable": true, 
      "auto_delete": false, 
      "internal": false, 
      "arguments": {} 
     } 
    ], 
    "bindings": [{ 
      "source": "decoder.dl.sn", 
      "vhost": "/", 
      "destination": "stream.smart.dl.postpaid", 
      "destination_type": "queue", 
      "routing_key": "SMART.POSTPAID", 
      "arguments": {} 
     }, { 
      "source": "decoder.sn", 
      "vhost": "/", 
      "destination": "stream.service.postpaid", 
      "destination_type": "queue", 
      "routing_key": "SERVICE.POSTPAID", 
      "arguments": {} 
     }, { 
      "source": "decoder.sn", 
      "vhost": "/", 
      "destination": "stream.smart.postpaid", 
      "destination_type": "queue", 
      "routing_key": "SMART.POSTPAID", 
      "arguments": {} 
     } 
    ] 
} 

回答

0

只要找到它。

我们可以使用web界面通过外壳

rabbitmqadmin -q进口rabbit.config

导入文件或下面的命令