Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add full-text and term level queries specific to Elasticsearch #5

Merged
merged 8 commits into from
Mar 15, 2017

Conversation

jciolek
Copy link
Collaborator

@jciolek jciolek commented Mar 14, 2017

Summary

This pull requests deals with #1 by enabling three full-text queries in the adapter:

  • $match (Es: match)
  • $phrase (Es: match_phrase)
  • $phrase_prefix (Es: match_phrase_prefix)

As a bonus, there is also one term level query thrown into the mix:

  • $prefix (Es: prefix)

And the simplest query there is:

  • $all (Es: match_all)

The implementation is fairly simple, as the existing parser for query parameters is easily extendable. I have added relevant tests.

I did not want to introduce long query names (e.g. $match_phrase_prefix) and at the same time did not want ambiguous acronyms, so went for a compromise.

Other Information

This PR also deals with testing the adapter on several versions of Elasticsearch. So far we had several branches, each for a different Es version. It was ok as a starting point, but quickly became cumbersome, so I have gathered all variations in one Travis config and slightly changed the test entry point as well as the test app in order to choose Es setup for 2.4 or 5.x based on env variable (ES_VERSION).

Docs PR already filed.

@daffl daffl merged commit b9eae67 into feathersjs-ecosystem:master Mar 15, 2017
@daffl
Copy link
Member

daffl commented Mar 15, 2017

Released as v0.2.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants