Skip to content

Conversation

@lec-bit
Copy link
Contributor

@lec-bit lec-bit commented Mar 26, 2025

What type of PR is this?
/kind feature

What this PR does / why we need it:

Which issue(s) this PR fixes:
Fixes #

Special notes for your reviewer:

Does this PR introduce a user-facing change?:


@kmesh-bot
Copy link
Collaborator

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by:
Once this PR has been reviewed and has the lgtm label, please assign hzxuzhonghu for approval. For more information see the Kubernetes Code Review Process.

The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@lec-bit lec-bit changed the title metric metric in ads Mar 26, 2025
@lec-bit lec-bit force-pushed the metric-dev branch 3 times, most recently from d0c04d7 to 61843df Compare March 27, 2025 11:22
@lec-bit
Copy link
Contributor Author

lec-bit commented Mar 27, 2025

I use src pod name and dst svc name or pod name as label

[root@kmesh-zsph4 kmesh]# curl http://10.244.1.5:15020/status/metric

HELP kmesh_tcp_ads_connections_closed_total The total number of TCP connections closed to a ads

TYPE kmesh_tcp_ads_connections_closed_total gauge

kmesh_tcp_ads_connections_closed_total{destination_pod_address="10.244.1.10",destination_pod_port="-",destination_svc_name="fortio-server-deployment-7cd9f46f6d-s6nw4.default",reporter="source",source_pod_address="10.244.1.9",source_pod_name="fortio-client-deployment-79d94fc67c-6fh4k.default",source_pod_port="-"} 8
kmesh_tcp_ads_connections_closed_total{destination_pod_address="10.244.1.11",destination_pod_port="-",destination_svc_name="fortio-server-deployment-7cd9f46f6d-mkp75.default",reporter="source",source_pod_address="10.244.1.9",source_pod_name="fortio-client-deployment-79d94fc67c-6fh4k.default",source_pod_port="-"} 8

HELP kmesh_tcp_ads_connections_opened_total The total number of TCP connections opened to a ads

TYPE kmesh_tcp_ads_connections_opened_total gauge

kmesh_tcp_ads_connections_opened_total{destination_pod_address="10.244.1.10",destination_pod_port="-",destination_svc_name="fortio-server-deployment-7cd9f46f6d-s6nw4.default",reporter="source",source_pod_address="10.244.1.9",source_pod_name="fortio-client-deployment-79d94fc67c-6fh4k.default",source_pod_port="-"} 8
kmesh_tcp_ads_connections_opened_total{destination_pod_address="10.244.1.11",destination_pod_port="-",destination_svc_name="fortio-server-deployment-7cd9f46f6d-mkp75.default",reporter="source",source_pod_address="10.244.1.9",source_pod_name="fortio-client-deployment-79d94fc67c-6fh4k.default",source_pod_port="-"} 8

HELP kmesh_tcp_ads_received_bytes_total The size of the total number of bytes received in response to a ads over a TCP connection.

TYPE kmesh_tcp_ads_received_bytes_total gauge

kmesh_tcp_ads_received_bytes_total{destination_pod_address="10.244.1.10",destination_pod_port="-",destination_svc_name="fortio-server-deployment-7cd9f46f6d-s6nw4.default",reporter="source",source_pod_address="10.244.1.9",source_pod_name="fortio-client-deployment-79d94fc67c-6fh4k.default",source_pod_port="-"} 2.547308e+06
kmesh_tcp_ads_received_bytes_total{destination_pod_address="10.244.1.11",destination_pod_port="-",destination_svc_name="fortio-server-deployment-7cd9f46f6d-mkp75.default",reporter="source",source_pod_address="10.244.1.9",source_pod_name="fortio-client-deployment-79d94fc67c-6fh4k.default",source_pod_port="-"} 2.578883e+06

HELP kmesh_tcp_ads_sent_bytes_total The size of the total number of bytes sent in response to a ads over a TCP connection.

TYPE kmesh_tcp_ads_sent_bytes_total gauge

kmesh_tcp_ads_sent_bytes_total{destination_pod_address="10.244.1.10",destination_pod_port="-",destination_svc_name="fortio-server-deployment-7cd9f46f6d-s6nw4.default",reporter="source",source_pod_address="10.244.1.9",source_pod_name="fortio-client-deployment-79d94fc67c-6fh4k.default",source_pod_port="-"} 33988
kmesh_tcp_ads_sent_bytes_total{destination_pod_address="10.244.1.11",destination_pod_port="-",destination_svc_name="fortio-server-deployment-7cd9f46f6d-mkp75.default",reporter="source",source_pod_address="10.244.1.9",source_pod_name="fortio-client-deployment-79d94fc67c-6fh4k.default",source_pod_port="-"} 34409

HELP promhttp_metric_handler_errors_total Total number of internal errors encountered by the promhttp metric handler.

TYPE promhttp_metric_handler_errors_total counter

promhttp_metric_handler_errors_total{cause="encoding"} 0
promhttp_metric_handler_errors_total{cause="gathering"} 0

@LiZhenCheng9527 LiZhenCheng9527 changed the title metric in ads metric in Kernel Native Mode Apr 3, 2025
@LiZhenCheng9527 LiZhenCheng9527 changed the title metric in Kernel Native Mode metrics in Kernel Native Mode Apr 3, 2025
Signed-off-by: lec-bit <glfhzmy@126.com>
@yp969803
Copy link
Contributor

@lec-bit you can also update the code to include periodic updation of metrics in native mode, like we are doing in workload mode #1298

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants