We have moved our forum to GitHub Discussions. For questions about Phalcon v3/v4/v5 you can visit here and for Phalcon v6 here.

Elasticsearch and Models/CollectionsManager

So, I want to use Elasticsearch as my main source of data and would like to use Phalcon bult-in ODM. How ever it seems only to be design for Mongo, is there any example out there to add a different adapter or manipulate it in some easy way? Since I want to make use of the ODM and the Models I do not want to build my own adapters and model system for this.



98.9k

Phalcon's ODM is highly tied to MongoDB and currently is not possible change or add the database backend it works with.



15.2k
edited Sep '16

I have build a simple adapter for elasticsearch, most of logic is based on phalcon's model source code, you can give a try on git https://github.com/code100/ModelElastic