We run all the PHP clients for Elasticsearch (if we miss one, send a PR!) and ask them to perform a lot of requests, we compute some statistics about it.
More than the speed or memory, this benchmark is also about usage, API and examples for each clients.
They are configured the same way:
- no logs
- two nodes cluster (as we run a test with the master node down, to test fallback)
- keep alive on the connection (if possible)
- ruflin/elastica: v0.90.5.0
- sherlock/sherlock: dev-master
- elasticsearch/elasticsearch: v0.4.2
- nervetattoo/elasticsearch: v2.3.0
Runned with PHP 5.3 on Ubuntu 12.04.
elasticsearch | sherlock | elastica | nervetattoo | |
---|---|---|---|---|
getDocument | 9772 | 2235 | 1549 | 1109 |
searchDocument | 5753 | 2518 | 1859 | 1118 |
searchDocumentWithFacet | 5803 | 3109 | 2047 | 1057 |
searchOnDisconnectNode | 12419 | 0 | 2859 | 0 |
searchSuggestion | 7015 | 0 | 24582 | 2203 |
indexRefresh | 4916 | 0 | 1489 | 1502 |
indexStats | 5107 | 0 | 1674 | 1402 |
Total time | 55564 | 11004 | 37088 | 9844 |
Memory | 28311552 | 12320768 | 10747904 | 8388608 |
Boot Elasticsearch on the default port and run ./bin/run-all.sh
.
This benchmark is part of an article describing Elasticsearch PHP clients.