doctrine / search

Generic Search extension for indexing and querying ODM/ORM objects with different text-search engine implementations
http://www.doctrine-project.org
MIT License
273 stars 52 forks source link

Delete from Query, Elastica dependencies. #128

Open Zyqsempai opened 8 years ago

Zyqsempai commented 8 years ago

Here is the main problem: https://github.com/doctrine/search/blob/master/lib/Doctrine/Search/Query.php#L257 Here is two ways. First one: We can create abstract layer for ResultSet, for example Adapter, and wrap all result sets. Second one: We can move query on client level, create QueryInterface and realize it in ElasticSerach namespace for example, and create method in Client, something like Client::createQuery. So each query will work only with his native ResultSet. @MrHash What do you think?

MrHash commented 8 years ago

My hunch is the second choice to create the query and result interfaces and implement for each technology.

Zyqsempai commented 8 years ago

Ok. Deal.