0.0.5 • Published 11 years ago

elasticsearch-thrift v0.0.5

Weekly downloads
21
License
-
Repository
github
Last release
11 years ago

ElasticSearch thrift

Basic Elasticsearch thrift transport protocol wrapper

Install

npm install elasticsearch-thrift

Usage

var search,
ElasticSearch = require('../elasticsearch-thrift');

search = new ElasticSearch({
	servers: [{
		host: 'localhost',
		port: 9500
	}]}, function() {
	console.log('connected');

	search.closeConnections();

	search.get({uri: '_stats'}, function(err, res){
		console.log(err, res);
		search.closeConnections();
	});
});

Elasticsearch configuration

To use Elasticsearch with thrift first you must install thrift plugin by executing :

bin/plugin -install elasticsearch/elasticsearch-transport-thrift/1.2.0

And set few configuration options

thrift:
	port: 9500 # any of your choice
	frame: 1mb # node thrift module currently only supports framed transport protocol

Thrift file is taken from official Elasticsearch thrift transport repo schema

0.0.5

11 years ago

0.0.4

11 years ago

0.0.3

11 years ago

0.0.2

12 years ago

0.0.1

12 years ago