Created
          June 11, 2014 19:19 
        
      - 
      
- 
        Save blooberr/0ea66f9676a7b987b44a to your computer and use it in GitHub Desktop. 
Revisions
- 
        blooberr created this gist Jun 11, 2014 .There are no files selected for viewingThis file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters. Learn more about bidirectional Unicode charactersOriginal file line number Diff line number Diff line change @@ -0,0 +1,21 @@ myhost = "localhost" @es = Elasticsearch::Client.new host: myhost, port: 9200, log: true @es.create index: "hello", type: "world", id: "someitem", body: { text: "yup", count: 1 } @es.indices.put_alias index: "hello", name: "alias-hello" @es.search index: "alias-hello" @es.indices.close index: "alias-hello" @es.search index: "alias-hello", ignore_unavailable: true ## throws error @es.search index: "xxxxzzzzwrongindex", ignore_unavailable: true ## doesn't throw error. Expected behavior.