1 2 3 4 Previous Next 58 Replies Latest reply on Nov 19, 2017 10:57 PM by Yoav Gur

    Elasticsearch Connector

    Adam Lacey

      I've created a beta version of Web Data Connector to Elasticsearch.

       

      The connector is available for download at: mradamlacey/elasticsearch-tableau-connector · GitHub

       

      The connector supports the following:

      • Paging requests to Elasticsearch
      • Basic HTTP authentication
      • Specifying batch size of rows per page
      • Specifying an optional limit to total rows retrieved
      • Specifying the Elasticsearch cluster URL, index name and type to retrieve
      • Specify an option free-from query (using Elasticsearch's Query DSL) to indicated which matches should be retrieved

       

      Known limitations:

      • Not all Elasticsearch data types are supported (like array, object, geo_point, probably some others)
      • There seems to be a bug in the Tableau framework to only send 6 paging requests before an error is displayed of 'Maximum Number of Requests Reached'

       

      I would love to hear feedback.

        • 1. Re: Elasticsearch Connector
          Michael Graf

          This is great Adam. I've gotten all installed with Grunt/Bower and up and running but when I try to run it I get:

           

          "Request error, status code: 0; undefined"

           

          I'm running it on my localhost connecting to a local server. Any advise?

           

          Thanks,

          Mike

          • 2. Re: Elasticsearch Connector
            Adam Lacey

            You usually see that when either:

             

            ·         The host/port you specify is not reachable (check the cluster URL)

             

            ·         CORS error on the request (check that you have enabled CORS in the Elasticsearch config file)

             

            I did push a new version that improves the error handling.

            • 3. Re: Elasticsearch Connector
              Nicolas Brisoux

              Thanks for sharing Adam, I've added it to the list of community connectors in the Featured Content area.

              • 4. Re: Elasticsearch Connector
                Jonas Bergstrom

                A small comment on the limitations:

                 

                The limitations on paging requests is only in the Tableau WDC simulator (part of the SDK). It does not occur when used from within Tableau.

                 

                If you want to adjust the maximum number, just adjust the _MAX_DATA_REQUEST_CALLS variable in Simulator.js.

                 

                Best regards

                 

                Jonas

                • 5. Re: Elasticsearch Connector
                  Michael Graf

                  Yup - it was a CORS issue. I download an extension in chrome to fix this (just because I didn't have immediate access to change the CORS on the server -- Allow-Control-Allow-Origin: * - Chrome Web Store)

                   

                  Thanks,

                  Mike

                  • 6. Re: Elasticsearch Connector
                    Guilherme Thomazi

                    Hi there!

                     

                    The connector works fine but all the timestamp fields are coming as null. Is this something known or something I may have done wrong? My Elasticsearch mapping for this field is correct (the type is date) and we store it as a unix epoch timestamp.

                    Another question, is there a debug mode in the connector where I can see the data flow from connector to tableau?

                     

                    Thanks!

                    • 7. Re: Elasticsearch Connector
                      Nate Bitting

                      Hi Adam,

                       

                      Thanks for posting!  I have everything loaded, but I keep getting this error:

                       

                      Request error, unable to connect to host or CORS request was denied

                       

                      I've configured my elasticsearch.yml with all of the proper settings to allow for CORS (see below).  I have also ensured my host and port information is correct as well. 

                       

                      http.cors.enabled : true

                      script.inline : true

                      script.indexed : true

                      http.cors.allow-origin : "*"

                      http.cors.allow-methods : OPTIONS, HEAD, GET, POST, PUT, DELETE

                      http.cors.allow-headers : X-Requested-With,X-Auth-Token,Content-Type,Content-Length

                      http.jsonp.enable : true

                      cors.enabled : true

                      http.cors.allow-credentials : true

                      http.detailed_errors.enabled : true

                       

                      I'm able to access my elasticsearch DB via a browser (using Sense chrome plugin), but not in Tableau. I cannot figure out what's going on.  Please help!

                      • 8. Re: Elasticsearch Connector
                        Kushal Mehrotra

                        I am running into the same issue. I have all the above mentioned statements configured in elasticsearch.yml. But its giving me this error:-

                        Request error, unable to connect to host or CORS request was denied

                         

                        Please note that if I run the elasticsearch server, and the run the elasticsearch connector, the above error no longer occurs. However, in that case, I get the below error:-

                        Can't find variable: moment

                        file: https://myTableauServer/webdataconnectors/elasticsearch-connector.min.js line: 10

                         

                         

                        Please help me in this. I am new to this and this requirement is urgent.

                        • 9. Re: Elasticsearch Connector
                          Kushal Mehrotra

                          Also, can anyone please tell me what all .js files do I need to include in my html file? When I build using grunt, the html files in dist folder dont have any references except for the 'tablea.uwdc.js'. I have to add the jquery and lodash files explicitly to get to the next stage.

                          • 10. Re: Elasticsearch Connector
                            Kushal Mehrotra

                            Hi Adam,

                                 I am running into the same issue. I have all the above mentioned statements configured in elasticsearch.yml. But its giving me this error:-

                            Request error, unable to connect to host or CORS request was denied

                             

                            Please note that if I run the elasticsearch server, and the run the elasticsearch connector, the above error no longer occurs. However, in that case, I get the below error:-

                            Can't find variable: moment

                            file: https://myTableauServer/webdataconnectors/elasticsearch-connector.min.js line: 10

                             

                             

                            Please help me in this. I am new to this and this requirement is urgent.

                            • 11. Re: Elasticsearch Connector
                              Kushal Mehrotra

                              Hi Nate,

                                          Did you find a workaround to this?

                              • 12. Re: Elasticsearch Connector
                                Nate Bitting

                                Hi Kushal,

                                 

                                Unfortunately, I was not able to find a solution.  I had to get a dashboard built that day, so I couldn't waste anymore time trying to figure it out.  I ended up throwing my data into MySQL and connected to Tableau that way.

                                 

                                -Nate

                                • 13. Re: Elasticsearch Connector
                                  Lev Pevzner

                                  Hi Adam -

                                   

                                  Apologies if this is a beginner question -- but I'm having trouble getting the connector functioning...

                                  I'm trying to run it on Tableau Desktop. The message I get when I run "node index.js" is: "Elasticsearch Tableau Web Data connector server listening at http://:::3000"

                                   

                                  When I go to Tableau Desktop and enter "http://:::3000" into the Web Data Connector, however, nothing happens. And when I use "http://localhost:3000" instead, I get an error message.

                                   

                                  Any thoughts on what I'm doing wrong? Thanks in advance for your help!

                                   

                                  - Lev

                                  • 14. Re: Elasticsearch Connector
                                    Bart De Reu

                                    Hi,

                                     

                                    i'm trying to install and configure this connector , but i'm running into the same issue as some people here. :

                                     

                                    Unable to get Elasticsearch types, unable to connect to host or CORS request was denied

                                     

                                    i've tried everything possible to get rid of this , but no luck. (updating the yml file etc etc)

                                     

                                    Would be GREAT if someone had some more information about this CORS problem

                                     

                                     

                                    thanks allot for the great work so far.

                                     

                                    Bart

                                    1 2 3 4 Previous Next