Skip to content

[Feature]: [P/D] Expose kv_transfer metrics (print to console, and to promethus) #21784

@lk-chen

Description

@lk-chen

🚀 The feature, motivation and pitch

Now P/D is supported in latest release, it would be great to expose metrics like kv_xfer_time, kv_xfer_bytes, kv_xfer_num_blocks etc. to both console and prometheus, for performance monitoring.

I think we can break the work into several parts

  1. pipe the metrics from nixl_connector all the way to model_runner , this can be further broken into
    a. change interface of get_finished to return not only ids, ideally a new class to aggregate all the infomation
    b. add metrics to the new class, it's worth discussion wether we want aggregated stats (avg, sum) or raw stats
  2. consume the metrics from logger, in vllm/v1/metrics/loggers.py
  3. consume the metrics from promethus logger, to be done in vllm/v1/metrics/loggers.py

Alternatives

No response

Additional context

No response

Before submitting a new issue...

  • Make sure you already searched for relevant issues, and asked the chatbot living at the bottom right corner of the documentation page, which can answer lots of frequently asked questions.

cc @NickLucche @robertgshaw2-redhat @kouroshHakha @ruisearch42

Metadata

Metadata

Assignees

No one assigned

    Labels

    feature requestNew feature or requeststaleOver 90 days of inactivity

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions