Skip to content

Instantly share code, notes, and snippets.

@parkr
Created January 7, 2014 21:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save parkr/8307395 to your computer and use it in GitHub Desktop.
Save parkr/8307395 to your computer and use it in GitHub Desktop.
# LIST MAPPING
curl -s private:9200/users/_mapping | js
# CREATE MAPPING
curl -XPUT 'private:9200/zo/zo/_mapping' -d '
{
"zo_mapping" : {
"properties" : {
"curationCount" : {"type" : "long" },
"featuredCount" : {"type" : "long" },
"gridDesc" : {"type" : "string" },
"gridExternal" : {"type" : "string" },
"gridImage" : {"type" : "string" },
"gridName" : {"type" : "string" },
"lastUploadDate" : {"type" : "date" },
"numberOfPhotos" : {"type" : "long" },
"siteDomain" : {"type" : "string" },
"siteId" : {"type" : "string" },
"userFirstName" : {"type" : "string" },
"userLastName" : {"type" : "string" },
"userName" : {"type" : "string" },
"userTwitter" : {"type" : "string" },
"userId" : {"type" : "string" }
}
}
}
'
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment