Skip to content

Commit

Permalink
Revert "[processor/k8sattributes] Rename k8sattributes processor inte… (
Browse files Browse the repository at this point in the history
open-telemetry#23431)

…rnal metrics (open-telemetry#23369)"

This reverts commit 42bca6f.

Revert it until
open-telemetry#23369 (comment)
is resolved to avoid adding it to the next release

Co-authored-by: Ziqi Zhao <zhaoziqi9146@gmail.com>
  • Loading branch information
dmitryax and fatsheep9146 authored Jun 16, 2023
1 parent 6ad0589 commit 8869951
Show file tree
Hide file tree
Showing 3 changed files with 18 additions and 38 deletions.
20 changes: 0 additions & 20 deletions .chloggen/k8sattribute-rename-metric.yaml

This file was deleted.

Original file line number Diff line number Diff line change
Expand Up @@ -27,17 +27,17 @@ func init() {
}

var (
mPodsUpdated = stats.Int64("processor.k8sattributes.pods.updated", "Number of pod update events received", "1")
mPodsAdded = stats.Int64("processor.k8sattributes.pods.added", "Number of pod add events received", "1")
mPodsDeleted = stats.Int64("processor.k8sattributes.pods.deleted", "Number of pod delete events received", "1")
mPodTableSize = stats.Int64("processor.k8sattributes.pods.table_size", "Size of table containing pod info", "1")
mIPLookupMiss = stats.Int64("processor.k8sattributes.ip_lookup_misses", "Number of times pod by IP lookup failed.", "1")
mNamespacesUpdated = stats.Int64("processor.k8sattributes.namespaces.updated", "Number of namespace update events received", "1")
mNamespacesAdded = stats.Int64("processor.k8sattributes.namespaces.added", "Number of namespace add events received", "1")
mNamespacesDeleted = stats.Int64("processor.k8sattributes.namespaces.deleted", "Number of namespace delete events received", "1")
mReplicaSetsUpdated = stats.Int64("processor.k8sattributes.replicasets.updated", "Number of ReplicaSet update events received", "1")
mReplicaSetsAdded = stats.Int64("processor.k8sattributes.replicasets.added", "Number of ReplicaSet add events received", "1")
mReplicaSetsDeleted = stats.Int64("processor.k8sattributes.replicasets.deleted", "Number of ReplicaSet delete events received", "1")
mPodsUpdated = stats.Int64("otelsvc/k8s/pod_updated", "Number of pod update events received", "1")
mPodsAdded = stats.Int64("otelsvc/k8s/pod_added", "Number of pod add events received", "1")
mPodsDeleted = stats.Int64("otelsvc/k8s/pod_deleted", "Number of pod delete events received", "1")
mPodTableSize = stats.Int64("otelsvc/k8s/pod_table_size", "Size of table containing pod info", "1")
mIPLookupMiss = stats.Int64("otelsvc/k8s/ip_lookup_miss", "Number of times pod by IP lookup failed.", "1")
mNamespacesUpdated = stats.Int64("otelsvc/k8s/namespace_updated", "Number of namespace update events received", "1")
mNamespacesAdded = stats.Int64("otelsvc/k8s/namespace_added", "Number of namespace add events received", "1")
mNamespacesDeleted = stats.Int64("otelsvc/k8s/namespace_deleted", "Number of namespace delete events received", "1")
mReplicaSetsUpdated = stats.Int64("otelsvc/k8s/replicaset_updated", "Number of ReplicaSet update events received", "1")
mReplicaSetsAdded = stats.Int64("otelsvc/k8s/replicaset_added", "Number of ReplicaSet add events received", "1")
mReplicaSetsDeleted = stats.Int64("otelsvc/k8s/replicaset_deleted", "Number of ReplicaSet delete events received", "1")
)

var viewPodsUpdated = &view.View{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -61,31 +61,31 @@ func TestMetrics(t *testing.T) {
}
tests := []testCase{
{
"processor.k8sattributes.pods.added",
"otelsvc/k8s/pod_added",
RecordPodAdded,
},
{
"processor.k8sattributes.pods.deleted",
"otelsvc/k8s/pod_deleted",
RecordPodDeleted,
},
{
"processor.k8sattributes.pods.updated",
"otelsvc/k8s/pod_updated",
RecordPodUpdated,
},
{
"processor.k8sattributes.ip_lookup_misses",
"otelsvc/k8s/ip_lookup_miss",
RecordIPLookupMiss,
},
{
"processor.k8sattributes.namespaces.added",
"otelsvc/k8s/namespace_added",
RecordNamespaceAdded,
},
{
"processor.k8sattributes.namespaces.updated",
"otelsvc/k8s/namespace_updated",
RecordNamespaceUpdated,
},
{
"processor.k8sattributes.namespaces.deleted",
"otelsvc/k8s/namespace_deleted",
RecordNamespaceDeleted,
},
}
Expand Down

0 comments on commit 8869951

Please sign in to comment.