PHPackages                             sherlock/sherlock - 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. sherlock/sherlock

AbandonedLibrary[Search &amp; Filtering](/categories/search)

sherlock/sherlock
=================

PHP Client for Elasticsearch

v0.1.16(12y ago)119252.6k27[20 issues](https://github.com/polyfractal/sherlock/issues)[5 PRs](https://github.com/polyfractal/sherlock/pulls)MITPHPPHP &gt;=5.3.9

Since Feb 24Pushed 10y ago8 watchersCompare

[ Source](https://github.com/polyfractal/sherlock)[ Packagist](https://packagist.org/packages/sherlock/sherlock)[ Docs](https://sherlockphp.org)[ RSS](/packages/sherlock-sherlock/feed)WikiDiscussions master Synced 1mo ago

READMEChangelogDependencies (4)Versions (19)Used By (0)

Sherlock
========

[](#sherlock)

*Sherlock* is a PHP (&gt;=5.3.9) client for [ElasticSearch](http://www.elasticsearch.org/). *Sherlock* can be used to search and manage ElasticSearch clusters.

Sherlock is Unmaintained! DO NOT USE!
-------------------------------------

[](#sherlock-is-unmaintained-do-not-use)

Sherlock is no longer maintained and should not be considered a usable Elasticsearch client for anything remotely resembling a production environment. It is *not* compatible with Elasticsearch 1.0+, nor does it have complete API coverage of Elasticsearch 0.90.x

*Please* use the official Elasticsearch client (which I wrote, and maintaine):

The official client is actively maintained and well-tested against ES and PHP versions.

If you are interested in updating Sherlock to use the official client, please open a ticket and let me know! I'd love to see the syntax of Sherlock on top of the new client...but I just don't have time myself.

Features
--------

[](#features)

- One-to-one mapping with ElasticSearch's API and query DSL.
- Option to use powerful ORM-like interface, associative arrays or raw JSON
- Concurrent request streaming with RollingCurl and cURL multi-handle
- Autodetection of cluster nodes and subsequent round-robin requests to the entire cluster
- Configurable logging capabilities

Disclaimer
----------

[](#disclaimer)

Sherlock should be considered **Alpha** status. Use in production at your own risk! The current 0.1 branch is in maintenance mode - I'm only fixing bugs and accepting PRs.

The new 0.2 branch that is coming *will* break backwards compatibility in places. The new 0.2 branch, however, should be a lot easier to maintain and I'll likely be promoting it to true 1.0 status soon after release (along with associated SemVer, backwards compatibility, etc).

Resources
---------

[](#resources)

- Read the [Quickstart Guide](http://sherlockphp.com/quickstart/)
- Read the [Full Documentation](http://sherlockphp.com/documentation/)
- [Roadmap for Sherlock](Roadmap.md)
- [Changelog](Changelog.md)

Installation via Composer
-------------------------

[](#installation-via-composer)

The recommended method to install *Sherlock* is through [Composer](http://getcomposer.org).

1. Add `sherlock/sherlock` as a dependency in your project's `composer.json` file:

    ```
     {
         "require": {
             "sherlock/sherlock": "~0.1.0"
         }
     }

    ```

    *Note*: If you would like to use the latest stable development version, specify `dev-master` in your composer file instead of `0.1.*`. Master is kept at the most recent, stable development version but may not be tagged and pushed to Packagist yet. Unstable dev versions are kept secluded in the `develop` branch.
2. Download and install Composer:

    ```
     curl -s http://getcomposer.org/installer | php

    ```
3. Install your dependencies:

    ```
     php composer.phar install

    ```
4. Require Composer's autoloader

    Composer also prepares an autoload file that's capable of autoloading all of the classes in any of the libraries that it downloads. To use it, just add the following line to your code's bootstrap process:

    ```
