Skip to content

Instantly share code, notes, and snippets.

View joafeldmann's full-sized avatar
👋

Joachim Feldmann joafeldmann

👋
View GitHub Profile
@joafeldmann
joafeldmann / gist:7319552
Created November 5, 2013 14:09
ES versioning
curl -XPUT 'http://localhost:9200/twitter/tweet/1' -d '{
"user" : "kimchy",
"post_date" : "2009-11-15T14:12:12",
"message" : "trying out Elastic Search"
}'
// {"ok":true,"_index":"twitter","_type":"tweet","_id":"1","_version":1}
curl -XPOST localhost:9200/twitter/tweet/1/_update -d '{
"doc": {
//create our "FOO" namespace
window.FOO = window.FOO || {};
FOO.app1 = {
bar : 'foo',
init : function(){
//this wont work as expected since timeout changes scope
/*!
* backbone.collectioncache.js v0.0.2
* Copyright 2012, Tim Branyen (@tbranyen)
* backbone.collectioncache.js may be freely distributed under the MIT license.
*/
(function(window) {
"use strict";
// Dependencies