rufuspollock-okfn / facetview

FacetView is a pure javascript frontend for ElasticSearch.
291 stars 91 forks source link

FacetView Not working #15

Closed karansingh1000 closed 12 years ago

karansingh1000 commented 12 years ago

Hi,

I am not able to get it to work. When i connect facetview to ElasticSearch i am getting this error: SyntaxError: invalid label

This same issue seems to be coming in the demo site.

Please help Thanks alot Jaskaran

karansingh1000 commented 12 years ago

working now :-) This is pretty great stuff!!

markmacgillivray commented 12 years ago

Great! Glad you got it going. Might push some more updates this week too.

karansingh1000 commented 12 years ago

Superb! Looking froward to getting the new updates :-) thanks alot...

carchrae commented 12 years ago

I'm getting this as well - what did you change between getting the error and it working @karansingh1000 ?

carchrae commented 12 years ago

ugh - got it. it was a few things.

the error is because the JS code was expecting a JSONP response and not a JSON response. after spending some time trying to get elasticsearch to respond with JSONP i looked at the facetview code - and realized that 'search_index' meant the server type as compared to the 'index' on elastic search. facepalm.

so the reason the error appeared is because i had changed 'search_index' to one of the actual indexes on my ES instance. what this really meant was that faceview switched to a different query string (non-elastic seach) and so it broke. once i changed it back, magico, works.

search_index really could be a better named variable.

karansingh1000 commented 12 years ago

Hi Carchrae,

I made the mistake by updating the below variable: "search_index":"elasticsearch"

I though this variable was for the index in ES. Now it all works really good.

cheers Karan

Nyamkhand commented 11 years ago

Hi Karan, can you make the video about above problem. I'm new to elasticsearch and facetview. Even I can make work the elasticsearch and es-head on my localhost, I don't know how to connect elasticsearch to facetview. Also I don't know how to make work facetview too.