geoip-stats.asciidoc 2.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128
  1. [[geoip-stats-api]]
  2. === GeoIP stats API
  3. ++++
  4. <titleabbrev>GeoIP stats</titleabbrev>
  5. ++++
  6. Gets statistics about the <<geoip-processor,`geoip` processor>>, including
  7. download statistics for GeoIP2 databases used with it.
  8. [source,console]
  9. ----
  10. GET _ingest/geoip/stats
  11. ----
  12. [[geoip-stats-api-request]]
  13. ==== {api-request-title}
  14. `GET _ingest/geoip/stats`
  15. [[geoip-stats-api-prereqs]]
  16. ==== {api-prereq-title}
  17. * If the {es} {security-features} are enabled, you must have the `monitor` or
  18. `manage` <<privileges-list-cluster,cluster privilege>> to use this API.
  19. * If <<ingest-geoip-downloader-enabled,`ingest.geoip.downloader.enabled`>> is
  20. disabled and no custom databases are configured, this API returns zero values and an empty `nodes` object.
  21. [role="child_attributes"]
  22. [[geoip-stats-api-response-body]]
  23. ==== {api-response-body-title}
  24. `stats`::
  25. (object)
  26. Download statistics for all GeoIP2 databases.
  27. +
  28. .Properties of `stats`
  29. [%collapsible%open]
  30. ====
  31. `successful_downloads`::
  32. (integer)
  33. Total number of successful database downloads.
  34. `failed_downloads`::
  35. (integer)
  36. Total number of failed database downloads.
  37. `total_download_time`::
  38. (integer)
  39. Total milliseconds spent downloading databases.
  40. `database_count`::
  41. (integer)
  42. Current number of databases available for use.
  43. `skipped_updates`::
  44. (integer)
  45. Total number of database updates skipped.
  46. ====
  47. `nodes`::
  48. (object)
  49. Statistics for each node.
  50. +
  51. .Properties of `nodes`
  52. [%collapsible%open]
  53. ====
  54. `<node_id>`::
  55. (object)
  56. Downloaded databases for the node. The field key is the node ID.
  57. +
  58. .Properties of `<node_id>`
  59. [%collapsible%open]
  60. =====
  61. `databases`::
  62. (array of objects)
  63. Downloaded databases for the node.
  64. +
  65. .Properties of `databases` objects
  66. [%collapsible%open]
  67. ======
  68. `name`::
  69. (string)
  70. Name of the database.
  71. ======
  72. `cache_stats`::
  73. (object)
  74. GeoIP cache stats for the node.
  75. +
  76. .Properties of `cache_stats`
  77. [%collapsible%open]
  78. ======
  79. `count`::
  80. (Long)
  81. Number of cached entries.
  82. `hits`::
  83. (Long)
  84. The number of enrich lookups served from cache.
  85. `misses`::
  86. (Long)
  87. The number of times geoIP lookups couldn't be
  88. served from cache.
  89. `evictions`::
  90. (Long)
  91. The number cache entries evicted from the cache.
  92. `hits_time_in_millis`::
  93. (Long)
  94. The amount of time in milliseconds spent fetching data from the cache on successful cache hits only.
  95. `misses_time_in_millis`::
  96. (Long)
  97. The amount of time in milliseconds spent fetching data from the cache and the backing GeoIP2 database and updating the
  98. cache, on cache misses only.
  99. ======
  100. `files_in_temp`::
  101. (array of strings)
  102. Downloaded database files, including related license files. {es} stores these
  103. files in the node's <<es-tmpdir,temporary directory>>:
  104. `$ES_TMPDIR/geoip-databases/<node_id>`.
  105. =====
  106. ====