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

Please update the documentation #147

Open
bernji opened this issue Mar 31, 2016 · 5 comments
Open

Please update the documentation #147

bernji opened this issue Mar 31, 2016 · 5 comments

Comments

@bernji
Copy link

bernji commented Mar 31, 2016

Hi,

I know all developers hate to write documentations. So do I.
But now, as I am a user of your plugin, I am kind of left alone. The documentation provided is very old.

But the worst:
I am using grails 2.x and would like to upgrade to the newest version of EL as possible. I cannot find any reference which version I could use.

As I notices. Most developers of grails plugins have 2 different branches: one for grais 2.x and one for grails 3.x

To which version can I upgrade?

@puneetbehl
Copy link
Collaborator

@bernji The latest version 0.1.0 has been released over https://grails.org/plugin/elasticsearch with the support of Elasticsearch 2.x for Grails 2.x. I'll work on updating the documentation. For the time being you could refer to Documentation here and feel free to reach out to me in case you face any issues.

@puneetbehl
Copy link
Collaborator

Updated documentation. Please let me know if you find any issues with it.

@glont
Copy link

glont commented Apr 24, 2016

Hi,

First of all the documentation seems overall pretty good as far as i can see, thanks.

One thing the documentation does currently not explain is how to use aggregations. As far as i understand the aggregations should appear in the result map of the elasticSearchService.search function. The commit 276dfe1 where this functionallity was first added did not help me all that much and that is as far as i got by looking through the code.

What i tried was to add a aggs section in the Closure given to the elasticSearchService.search Method. Something like:

{
    bool { ... }
    aggs {
        aggregationName {
            terms {field: "fieldName"}
        }
    }
}

Which did not change the result. It seems to completly ignore the aggs part of the query. I also tried it with aggregations instead of aggs

Also adding a query around the bool did throw a MethodNotFound Exception, so the following did not work at all:

{
    query { 
        bool { ... }
     }
    aggs { ... }
}

In one of the issues (#87) it was explained how to use the elasticSearchHelper.withElasticSearch function. But for that i would need Classes, which do not come with the plugin (at least version 0.1.0, because I still need to use grails 2.4.x). I guess when using the elasticSearchHelper one also needs to have all of elasticSearch in the classpath or maybe only the Java API?

@puneetbehl
Copy link
Collaborator

Thanks for the feedback @glont. I will surely look into this over coming weekend and try to update documentation.

@vonovak
Copy link

vonovak commented Apr 28, 2016

+1 for aggs documentation. Previously, I ended up coding them using the java interface which definitely isn't as readable as the groovy way.

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

No branches or pull requests

4 participants