Awesome
ElasticsearchServiceProvider
A Silex Service Provider for the official Elasticsearch Client.
Installation
{
"require": {
"xmarcos/elasticsearch-service-provider": "dev-master"
}
}
Usage
use Silex\Application;
use xmarcos\Silex\ElasticsearchServiceProvider
$app = new Application();
$app->register(new ElasticsearchServiceProvider(), [
'elasticsearch.params' => [
'hosts' => [
'127.0.0.1:9200'
],
'logging' => false
]
]);
$app['elasticsearch']->ping();
License
MIT License