mradamlacey / elasticsearch-tableau-connector

Tableau Web Data Connector for Elasticsearch
MIT License
149 stars 64 forks source link

"Invalid Elasticsearch URL" error, but the connector is pulling index and type data correctly #58

Closed chuchurocket27 closed 7 years ago

chuchurocket27 commented 7 years ago

My Elasticsearch URL is http://lgb-es-01:9200. When I populate the "Elasticsearch URL" with this, I can see and select my index and types correctly. But hitting "Preview" or "Submit" causes an "Elasticsearch URL is not a valid URL" error.

Running ES 5.4, Tableau 10.2.0.

chuchurocket27 commented 7 years ago

The issue is in app.js it looks like:

var isValidUrl = function (str) {
        var pattern = new RegExp

Looks like the regex does not expect numbers to be at the end of the URL.

My suggestion is to not validate the URL at all, since an "Unable to get Elasticsearch indices" error will occur if the URL doesn't point to a valid ES server anyway.

mradamlacey commented 7 years ago

Yes, will update the regex, look for a fix for this soon. thanks for identifying.