Skip to content

feature(prometheus): support to collect metric overhead #1534

@membphis

Description

@membphis

we can take an example at latency, here is the fake code:

overhead_time = ngx.now() - ngx.req.start_time() - ctx.var.upstream_response_time

https://github.com/apache/incubator-apisix/blob/master/apisix/plugins/prometheus/exporter.lua#L53

https://github.com/apache/incubator-apisix/blob/master/apisix/plugins/prometheus/exporter.lua#L80-L81

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions