Skip to content

Instantly share code, notes, and snippets.

@dylkreisman
dylkreisman / gist:861960d9b9f939c1c88ff47849d57176
Created September 9, 2021 19:17
Launchpad template example
{
"app_name": "Basic Redis caching example in Nodejs", //Name of the app
"description": "Showcases how to implement caching in NodeJS", // One line description
"hidden": false, // Can be "true" or "false". If true, this app won't show up in the
Launchpad.
"rank": 20, // This is used to sort the apps in the Launchpad. 1 to 20 are reserved. Enter
greater than 20
"type": "Building Block", //Can be "Building Block" or "Full App"
"contributed_by": "Redis Labs", // Can be "Redis Labs" or "Community" or "Partner"
"repo_url": "https://github.com/redis-developer/basic-caching-demo-nodejs", //This is the
{
"app_name": "", //Name of the app
"description": "", // One line description
"hidden": "", // Can be "true" or "false". If true, this app won't show up in the Launchpad.
"rank": "", // This is used to sort the apps in the Launchpad. 1 to 20 are reserved. Enter
greater than 20
"type": "", //Can be "Building Block" or "Full App"
"contributed_by": "", // Can be "Redis Labs" or "Community" or "Partner"
"repo_url": "", //This is the Github Repo's URL.
"download_url": "",//This is a direct link to Github's download button so people can download it
redis.cloud:6379> SET myDoc '{"colors": ["green"]}'
OK
redis.cloud:6379> JSON.GET myDoc colors[0]
"\"green\""
5) 1) Result processors profile
2) 1) Type
2) Index
3) Time
4) "0.040000000000000001"
5) Counter
6) (integer) 2
3) 1) Type
2) Scorer
3) Time
4) 1) Iterators profile
2) 1) Type
2) UNION
3) Query type
4) "FUZZY - hello"
5) Time
6) "0.025999999999999999"
7) Counter
8) (integer) 2
9) Child iterators
2) 1) Parsing time
2) "0.90900000000000003"
3) 1) Pipeline creation time
2) "0.105"
2) 1) 1) Total profile time
2) "1.552"
redis.cloud:6379> JSON.SET myDoc . '{"user":{"name":"John
Smith","hp":1000, "dmg":150}}'
OK
redis.cloud:6379> FT.CREATE myIdx ON JSON SCHEMA $.user.name AS name TEXT
OK