Code Monkey home page Code Monkey logo

elasticsearch-changes-plugin's Introduction

Elasticsearch Changes Plugin

The Elasticsearch Changes plugin is a plugin for Elasticsearch that tracks changes to indices and makes this information available
through a REST service. It provides information on node basis. So if you want the complete change information you have to query all nodes in your cluster.

Installation

Run bin/plugin -install derryx/elasticsearch-changes-plugin

Configuration

You can set the length of the history buffer with the setting changes.history.size. The default is 100.

Usage

Point your browser to http://localhost:9200/_changes/ to see changes for all indices.
If you want to see changes only for one or a list of indices you can use http://localhost:9200/foo,bar,baz/_changes/.

You will get a response like this:

{
  "twitter" : {
    "lastChange" : 1330372696400,
    "changes" : [ {
      "type" : "CREATE",
      "id" : "qf310jYSSK2OsM0fWEXyIA",
      "timestamp" : 1330372680742,
      "version" : 1
    }, {
      "type" : "INDEX",
      "id" : "1",
      "timestamp" : 1330372689220,
      "version" : 2
    }, {
      "type" : "DELETE",
      "id" : "1",
      "timestamp" : 1330372696400,
      "version" : 3
    } ]
  },
  "bubu" : {
    "lastChange" : 1330369466133,
    "changes" : [ ]
  }
}

The timestamp is a UNIX timestamp in milliseconds (epoch midnight, January 1, 1970 UTC).

See changes after a given timestamp

If you want to see only changes after a given timestamp you can add the parameter since to the request (for example http://localhost:9200/_changes/?since=1330282941692 ). The timestamp again is a UNIX timestamp (in milliseconds).

Wait for a index change to happen

You can make your request wait for a change to happen with the parameter wait. Additionally you can give a timeout parameter (in milliseconds).
(example: http://localhost:9200/_changes/?wait=true&timeout=60000 ). The default timeout is 15 minutes.

Version mapping

  • Change Plugin 0.1.x → Elasticsearch 0.18.x
  • Change Plugin 0.2.x → Elasticsearch 0.19.x

Other information

See project’s GitHub pages for details.

elasticsearch-changes-plugin's People

Contributors

derryx avatar

Watchers

Christian Hochfilzer avatar James Cloos avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.