Skip to content

Instantly share code, notes, and snippets.

@ctindel
Created December 24, 2016 19:15
Show Gist options
  • Save ctindel/bcf5dcd39188be5ec3447624c0c4eea6 to your computer and use it in GitHub Desktop.
Save ctindel/bcf5dcd39188be5ec3447624c0c4eea6 to your computer and use it in GitHub Desktop.
RT Traffic Speed Too Fast
GET nyc_traffic/data/_search
{
"query": {
"range" : {
"speed" : {
"gt" : 100
}
}
}
}
Results:
{
"took": 86,
"timed_out": false,
"_shards": {
"total": 5,
"successful": 5,
"failed": 0
},
"hits": {
"total": 3562,
"max_score": 1,
"hits": [
{
"_index": "nyc_traffic",
"_type": "data",
"_id": "4616309 2016-10-21T08:49:15Z",
"_score": 1,
"_source": {
"linkId": "4616309",
"name": "CBE E AMSTERDAM AVE(U/LVL) - MORRIS AVE",
"borough": "Bronx",
"owner": "NYC_DOT_LIC",
"polyline": "eyhxFxzfbMjBiJpCiQjAoKL_GMiIUqKk@}^CgTBcFN_H",
"polylineLvl": "BBBBBBBBBBB",
"speed": 141.05,
"travelTime": 30,
"status": 0,
"timestamp": "2016-10-21T08:49:15Z",
"@timestamp": "2016-10-21T08:49:15Z"
}
},
...
]
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment