Advertisement
Guest User

Pushshift BETA ES Comment Mapping

a guest
Apr 15th, 2018
189
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 3.77 KB | None | 0 0
  1. {
  2. "settings": {
  3. "index.codec": "best_compression",
  4. "index.shard.check_on_startup": "checksum",
  5. "index": {
  6. "number_of_shards": 4,
  7. "number_of_replicas": 0,
  8. "sort.field" : "created_utc",
  9. "sort.order" : "desc"
  10. },
  11. "analysis": {
  12. "analyzer": {
  13. "lowercase": {
  14. "type": "custom",
  15. "filter": ["lowercase"],
  16. "tokenizer": "whitespace"
  17. }
  18. },
  19. "normalizer": {
  20. "my_normalizer": {
  21. "type": "custom",
  22. "char_filter": [],
  23. "filter": ["lowercase", "asciifolding"]
  24. }
  25. }
  26. }
  27. },
  28. "mappings": {
  29. "comment": {
  30. "_routing": {
  31. "required": false
  32. },
  33. "_all": {
  34. "enabled": false
  35. },
  36. "_source": {
  37. "enabled": true,
  38. "excludes": ["id","utc_hour_of_week","length","user_removed","mod_removed","utc_hour_of_day"]
  39. },
  40. "dynamic": "false",
  41. "properties": {
  42. "body": {
  43. "type": "text"
  44. },
  45. "edited": {
  46. "type": "boolean"
  47. },
  48. "nest_level": {
  49. "type": "integer"
  50. },
  51. "mod_removed": {
  52. "type": "boolean"
  53. },
  54. "user_removed": {
  55. "type": "boolean"
  56. },
  57. "reply_delay": {
  58. "type": "integer"
  59. },
  60. "sub_reply_delay": {
  61. "type": "integer"
  62. },
  63. "utc_hour_of_week": {
  64. "type": "short"
  65. },
  66. "utc_hour_of_day": {
  67. "type": "short"
  68. },
  69. "length": {
  70. "type": "short"
  71. },
  72. "created_utc": {
  73. "type": "date",
  74. "format": "epoch_second"
  75. },
  76. "distinguished": {
  77. "type": "keyword",
  78. "normalizer": "my_normalizer"
  79. },
  80. "link_id": {
  81. "type": "integer"
  82. },
  83. "gilded": {
  84. "type": "byte",
  85. "coerce": false,
  86. "null_value": 0
  87. },
  88. "id": {
  89. "type": "long"
  90. },
  91. "parent_id": {
  92. "type": "long",
  93. "null_value": 0
  94. },
  95. "score": {
  96. "type": "integer",
  97. "coerce": false,
  98. "null_value": 0
  99. },
  100. "subreddit": {
  101. "type": "keyword",
  102. "normalizer": "my_normalizer"
  103. },
  104. "author_flair_text": {
  105. "type": "keyword",
  106. "normalizer": "my_normalizer"
  107. },
  108. "author_flair_css_class": {
  109. "type": "keyword",
  110. "normalizer": "my_normalizer"
  111. },
  112. "author": {
  113. "type": "keyword",
  114. "normalizer": "my_normalizer",
  115. "fields" : {
  116. "comp" : {
  117. "type": "completion"
  118. }
  119. }
  120. }
  121. }
  122. }
  123. }
  124. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement