Advertisement
Guest User

Untitled

a guest
Jan 18th, 2017
60
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.06 KB | None | 0 0
  1. {
  2. "state_events": {
  3. "aliases": {},
  4. "mappings": {
  5. "stateevent": {
  6. "dynamic_templates": [
  7. {
  8. "do_no_analyze_tag_strings": {
  9. "mapping": {
  10. "index": "not_analyzed",
  11. "type": "string"
  12. },
  13. "match_mapping_type": "string",
  14. "path_match": "tags.*"
  15. }
  16. }
  17. ],
  18. "properties": {
  19. "apiKey": {
  20. "type": "string",
  21. "index": "not_analyzed"
  22. },
  23. "eventType": {
  24. "type": "string",
  25. "index": "not_analyzed"
  26. },
  27. "host": {
  28. "type": "string"
  29. },
  30. "labels": {
  31. "type": "string",
  32. "index": "not_analyzed"
  33. },
  34. "message": {
  35. "type": "string"
  36. },
  37. "name": {
  38. "type": "string"
  39. },
  40. "status": {
  41. "type": "string"
  42. },
  43. "tags": {
  44. "properties": {
  45. "key": {
  46. "type": "string",
  47. "index": "not_analyzed"
  48. },
  49. "value": {
  50. "type": "string",
  51. "index": "not_analyzed"
  52. }
  53. }
  54. },
  55. "timestamp": {
  56. "type": "date",
  57. "format": "epoch_millis"
  58. }
  59. }
  60. }
  61. },
  62. "settings": {
  63. "index": {
  64. "creation_date": "1484754908073",
  65. "analysis": {
  66. "analyzer": {
  67. "default": {
  68. "filter": [
  69. "lowercase"
  70. ],
  71. "type": "custom",
  72. "tokenizer": "keyword"
  73. }
  74. }
  75. },
  76. "number_of_shards": "5",
  77. "number_of_replicas": "1",
  78. "uuid": "H9LGDjQiQIapozYtmbo2zA",
  79. "version": {
  80. "created": "2040199"
  81. }
  82. }
  83. },
  84. "warmers": {}
  85. }
  86. }
  87.  
  88. {
  89. "took": 25,
  90. "timed_out": false,
  91. "_shards": {
  92. "total": 5,
  93. "successful": 5,
  94. "failed": 0
  95. },
  96. "hits": {
  97. "total": 1,
  98. "max_score": 1,
  99. "hits": [
  100. {
  101. "_index": "state_events",
  102. "_type": "stateevent",
  103. "_id": "AVmyTdNBRJK0EVTphE4j",
  104. "_score": 1,
  105. "_source": {
  106. "eventType": "simulation1",
  107. "name": "simulation1",
  108. "timestamp": 1484755157,
  109. "tags": [
  110. {
  111. "key": "foo",
  112. "value": "bar"
  113. }
  114. ],
  115. "host": "mc",
  116. "apiKey": "simulator",
  117. "labels": [],
  118. "status": "CLEAR"
  119. }
  120. }
  121. ]
  122. }
  123. }
  124.  
  125. {
  126. "query": {
  127. "bool": {
  128. "must": [
  129. {
  130. "range": {
  131. "timestamp": {
  132. "gte": "20000110T000000.000Z",
  133. "lte": "20200119T000000.000Z",
  134. "format": "basic_date_time"
  135. }
  136. }
  137. }
  138. ]
  139. }
  140. }
  141. }
  142.  
  143. {
  144. "took": 2,
  145. "timed_out": false,
  146. "_shards": {
  147. "total": 5,
  148. "successful": 5,
  149. "failed": 0
  150. },
  151. "hits": {
  152. "total": 0,
  153. "max_score": null,
  154. "hits": []
  155. }
  156. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement