grafana / grafana/pyroscope

Custom labels added using pyroscope dotnet nuget are not available

Open
#4,280 9 comments 0 reactions 0 assignees View on GitHub
Dominant language
Go
Stars
11.7k
Forks
802
Avg merge
1d 19h
Merged PRs (30d)
80

Description

I am trying to add custom labels for one of my webapi

snippet:
```csharp
public ActionResult> GetTestList()
{
IEnumerable result = new List();
Pyroscope.LabelSet labels = Pyroscope.LabelSet.Empty.BuildUpon()
.Add("api_endpoint", "getunittestslist")
.Build();
Pyroscope.LabelsWrapper.Do(labels, () =>
{
result = TestService.GetTestsIds();
});

return StatusCode(200, result.ToList());
}
```
I have added 5 seconds of delay internally to test latency

The following are env variables:
#Profiling
DOTNET_EnableDiagnostics: 1
DOTNET_EnableDiagnostics_IPC: 0
DOTNET_EnableDiagnostics_Debugger: 0
DOTNET_EnableDiagnostics_Profiler: 1
PYROSCOPE_PROFILING_ENABLED: 1
PYROSCOPE_LABELS: pod_name:$(POD_NAME),node_name:$(NODE_NAME),pod_ip:$(POD_IP)
CORECLR_ENABLE_PROFILING: 1
CORECLR_PROFILER: '{BD1A650D-AC5D-4896-B64F-D6FA25D6B26A}'
CORECLR_PROFILER_PATH: /pyro/Pyroscope.Profiler.Native.so
LD_PRELOAD: /pyro/Pyroscope.Linux.ApiWrapper.x64.so
PYROSCOPE_PROFILING_CONTENTION_ENABLED: true
PYROSCOPE_PROFILING_CPU_ENABLED: true
PYROSCOPE_PROFILING_WALLTIME_ENABLED: true
PYROSCOPE_PROFILING_EXCEPTION_ENABLED: true
PYROSCOPE_PROFILING_ALLOCATION_ENABLED: true
PYROSCOPE_PROFILING_LOCK_ENABLED: true
PYROSCOPE_PROFILING_HEAP_ENABLED: true
LD_LIBRARY_PATH: /pyro
PYROSCOPE_SERVER_ADDRESS: "http://pyroscope-distributor.pyroscope.svc.cluster.local:4040"
PYROSCOPE_APPLICATION_NAME: "stest-api"

#### To Reproduce
Steps to reproduce the behavior:

Use Pyroscope and try to send it to default

#### Expected behavior

Expecting the custom labels added using pyroscope nuget

#### Environment

- Infrastructure:

AKS
- Deployment tool: [e.g., helm, jsonnet]
Helm/Argocd

Contributor guide

No contributing guide indexed for this repository

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.