Friday, January 2, 2015

elasticsearch-river-rabbitmq

  1. Installation
    1. bin/plugin -install elasticsearch/elasticsearch-river-rabbitmq/2.3.0
  2. River Creation
    1. curl -XPUT 'localhost:9200/_river/my_river/_meta' -d '{
          "type" : "rabbitmq",
          "rabbitmq" : {
              "host" : "localhost",
              "port" : 5672,
              "user" : "guest",
              "pass" : "guest",
              "vhost" : "/",
              "queue" : "elasticsearch",
              "exchange" : "elasticsearch",
              "routing_key" : "elasticsearch",
              "exchange_declare" : true,
              "exchange_type" : "direct",
              "exchange_durable" : true,
              "queue_declare" : true,
              "queue_bind" : true,
              "queue_durable" : true,
              "queue_auto_delete" : false,
              "heartbeat" : "30m",
              "qos_prefetch_size" : 0,
              "qos_prefetch_count" : 10,
              "nack_errors" : true
          },
          "index" : {
              "bulk_size" : 100,
              "bulk_timeout" : "10ms",
              "ordered" : false,
              "replication" : "default"
          }
      }'
    2. ...
          "rabbitmq" : {
              "addresses" : [
                  {
                      "host" : "rabbitmq-host1",
                      "port" : 5672
                  },
                  {
                      "host" : "rabbitmq-host2",
                      "port" : 5672
                  }
              ],
              "user" : "guest",
              "pass" : "guest",
              "vhost" : "/",
              ...
          }
          ...
  3. Reference
    1. https://github.com/elasticsearch/elasticsearch-river-rabbitmq/blob/master/README.md

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.