PHPackages                             headoo/elasticsearch-bundle - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. [Search &amp; Filtering](/categories/search)
4. /
5. headoo/elasticsearch-bundle

ActiveSymfony-bundle[Search &amp; Filtering](/categories/search)

headoo/elasticsearch-bundle
===========================

ElasticSearch Bundle

v0.5.1(6y ago)43464[2 issues](https://github.com/Headoo/ElasticSearchBundle/issues)MITPHPPHP &gt;=7.0

Since Apr 14Pushed 6y ago6 watchersCompare

[ Source](https://github.com/Headoo/ElasticSearchBundle)[ Packagist](https://packagist.org/packages/headoo/elasticsearch-bundle)[ Docs](https://github.com/Headoo/ElasticSearchBundle)[ RSS](/packages/headoo-elasticsearch-bundle/feed)WikiDiscussions master Synced 3d ago

READMEChangelog (7)Dependencies (10)Versions (23)Used By (0)

ElasticSearchBundle
===================

[](#elasticsearchbundle)

[![Build Status](https://camo.githubusercontent.com/86b156c3e3ae579733310ecade0f232cd5221f8a31cd955cc86b0f04744a6cdf/68747470733a2f2f7472617669732d63692e6f72672f486561646f6f2f456c617374696353656172636842756e646c652e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/Headoo/ElasticSearchBundle)[![Code Climate](https://camo.githubusercontent.com/d047d95a98f2a8ef7cfd1c819d53b1590312b3ef275711d845da2e430aac5ac7/68747470733a2f2f636f6465636c696d6174652e636f6d2f6769746875622f486561646f6f2f456c617374696353656172636842756e646c652f6261646765732f6770612e737667)](https://codeclimate.com/github/Headoo/ElasticSearchBundle)[![Latest Stable Version](https://camo.githubusercontent.com/b8c22dc956ebe4cb986026943399778ca4db3fc42f41dd62cda53831eb972e92/68747470733a2f2f706f7365722e707567782e6f72672f686561646f6f2f656c61737469637365617263682d62756e646c652f762f737461626c65)](https://packagist.org/packages/headoo/elasticsearch-bundle)[![codecov](https://camo.githubusercontent.com/c7f7b45ae766661dd04a2766ce17204e92d749eeb72c55a32df86968181d496c/68747470733a2f2f636f6465636f762e696f2f67682f486561646f6f2f456c617374696353656172636842756e646c652f6272616e63682f6d61737465722f67726170682f62616467652e737667)](https://codecov.io/gh/Headoo/ElasticSearchBundle)

ElasticSearchBundle is a Symfony2/3 Bundle designed for simply use ElasticSearch 5.x with Doctrine 2.x

Installation
------------

[](#installation)

Via Composer

```
$ composer require headoo/elasticsearch-bundle
```

or in composer.json file

```
"headoo/elasticsearch-bundle": "dev-master"
```

Register the bundle in `app/AppKernel.php`:

```
public function registerBundles()
{
    return array(
        // ...
        new Headoo\ElasticSearchBundle\HeadooElasticSearchBundle(),
        // ...
    );
}
```

Configuration
-------------

[](#configuration)

Configure your connections and mappings in `config.yml` : And we will linked this to a PHP config. You can use what you want. I prefer this instead yml, it's more in a ElasticSearch way.

```
imports:
    - { resource: elastic.php }
headoo_elastic_search:
    connections: %elastica_connections%
    mappings: %elastica_mappings%
services:
    name.of.your.transformer.service:
        class: Name\NameBundle\Entity\Transformer\EntityTransformer
```

I give you an example of the `elastic.php`.

```
