zh417233956 opened a new issue #2394:
URL: https://github.com/apache/apisix/issues/2394


   ### Issue description
   访问:http://192.168.5.139/apisix/prometheus/metrics,出现:metrics 500 Internal 
Server Error
   apisix reload 以后正常,几分钟以后,仍然出现:metrics 500 Internal Server Error
   
   ### Environment
   
   * apisix version (cmd: `apisix version`):1.5
   * OS:CentOS 7.6
   
   ### Minimal test code / Steps to reproduce the issue
   1. http://192.168.5.139/apisix/prometheus/metrics 
   
   
   ### What's the actual result? (including assertion message & call stack if 
applicable)
   metrics 500 Internal Server Error
   error.log:
   2020/10/12 12:21:09 [error] 31448#31448: *217543 lua entry thread aborted: 
runtime error: /usr/local/apisix/apisix/plugins/prometheus/exporter.lua:181: 
attempt to compare number with string
   stack traceback:
   coroutine 0:
        /usr/local/apisix/apisix/plugins/prometheus/exporter.lua: in function 
'set_modify_index'
        /usr/local/apisix/apisix/plugins/prometheus/exporter.lua:233: in 
function 'etcd_modify_index'
        /usr/local/apisix/apisix/plugins/prometheus/exporter.lua:262: in 
function 'handler'
        /usr/local/apisix/apisix/plugin.lua:209: in function 'handler'
        /usr/local/apisix//deps/share/lua/5.1/resty/radixtree.lua:739: in 
function 'dispatch'
        /usr/local/apisix/apisix/http/router/radixtree_uri.lua:110: in function 
'match'
        /usr/local/apisix/apisix/init.lua:336: in function 'http_access_phase'
        access_by_lua(nginx.conf:179):2: in main chunk, client: 192.168.6.88, 
server: , request: "GET /apisix/prometheus/metrics HTTP/1.1", host: 
"192.168.5.139:80"
   
   ### What's the expected result?
   


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to