Skip to content

test(config): add missing coverage for pod informer#2409

Merged
vimalk78 merged 1 commit intosustainable-computing-io:mainfrom
vprashar2929:test-cfg-pdinf
Feb 16, 2026
Merged

test(config): add missing coverage for pod informer#2409
vimalk78 merged 1 commit intosustainable-computing-io:mainfrom
vprashar2929:test-cfg-pdinf

Conversation

@vprashar2929
Copy link
Collaborator

No description provided.

@github-actions github-actions bot added the test Adding or updating tests label Feb 7, 2026
@github-actions
Copy link
Contributor

github-actions bot commented Feb 7, 2026

⚠️ Config changes detected in this PR
Please make sure that the config changes are updated in the following places as part of this PR:

  • docs/user/configuration.md
  • compose/dev/kepler-dev/etc/kepler/config.yaml
  • compose/default/kepler/etc/kepler/config.yaml
  • hack/config.yaml
  • manifests/k8s/configmap.yaml
  • manifests/helm/kepler/values.yaml

@github-actions
Copy link
Contributor

github-actions bot commented Feb 7, 2026

📊 Profiling reports are ready to be viewed

⚠️ Variability in pprof CPU and Memory profiles
When comparing pprof profiles of Kepler versions, expect variability in CPU and memory. Focus only on significant, consistent differences.

💻 CPU Comparison with base Kepler
File: kepler
Build ID: e8a9dff740522dead62bd6503cb9fec8d667ff15
Type: cpu
Time: 2026-02-07 13:30:23 UTC
Duration: 120s, Total samples = 4.09s ( 3.41%)
Active filters:
   show=github.com/sustainable-computing-io
Showing nodes accounting for 0.02s, 0.49% of 4.09s total
Dropped 2 nodes (cum <= 0.02s)
      flat  flat%   sum%        cum   cum%
         0     0%     0%      0.19s  4.65%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*gpuInfoCollector).Collect
         0     0%     0%     -0.14s  3.42%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*PowerCollector).Collect
         0     0%     0%     -0.04s  0.98%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*cpuInfoCollector).Collect
    -0.04s  0.98%  0.98%     -0.04s  0.98%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*realProcFS).CPUInfo
         0     0%  0.98%     -0.04s  0.98%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).scheduleNextCollection.func1
     0.04s  0.98%     0%      0.04s  0.98%  github.com/sustainable-computing-io/kepler/internal/resource.(*procFSReader).CPUUsageRatio
         0     0%     0%      0.04s  0.98%  github.com/sustainable-computing-io/kepler/internal/resource.(*resourceInformer).Refresh.func3
         0     0%     0%      0.04s  0.98%  github.com/sustainable-computing-io/kepler/internal/resource.(*resourceInformer).refreshNode
         0     0%     0%      0.03s  0.73%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).Snapshot
         0     0%     0%      0.03s  0.73%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).ensureFreshData
     0.02s  0.49%  0.49%      0.03s  0.73%  github.com/sustainable-computing-io/kepler/internal/resource.(*procFSReader).AllProcs
         0     0%  0.49%      0.02s  0.49%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*PlatformCollector).Collect
     0.02s  0.49%  0.98%      0.02s  0.49%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*PowerCollector).collectProcessMetrics
    -0.02s  0.49%  0.49%     -0.02s  0.49%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).calculateNodePower
    -0.02s  0.49%     0%     -0.02s  0.49%  github.com/sustainable-computing-io/kepler/internal/monitor.newProcess (inline)
         0     0%     0%      0.02s  0.49%  github.com/sustainable-computing-io/kepler/internal/platform/redfish.(*PowerReader).ReadAll
     0.02s  0.49%  0.49%      0.02s  0.49%  github.com/sustainable-computing-io/kepler/internal/platform/redfish.(*PowerReader).readPowerSubsystem
         0     0%  0.49%      0.02s  0.49%  github.com/sustainable-computing-io/kepler/internal/platform/redfish.(*Service).Power
         0     0%  0.49%      0.02s  0.49%  github.com/sustainable-computing-io/kepler/internal/resource.(*resourceInformer).Refresh
    -0.01s  0.24%  0.24%      0.02s  0.49%  github.com/sustainable-computing-io/kepler/internal/resource.(*resourceInformer).refreshProcesses
         0     0%  0.24%     -0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).calculatePower
     0.01s  0.24%  0.49%     -0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).calculateProcessPower
         0     0%  0.49%     -0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).refreshSnapshot
         0     0%  0.49%     -0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).synchronizedPowerRefresh
         0     0%  0.49%     -0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).synchronizedPowerRefresh.func1
    -0.01s  0.24%  0.24%     -0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/monitor.(*Process).Clone (inline)
     0.01s  0.24%  0.49%      0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/resource.(*procWrapper).Cgroups
    -0.01s  0.24%  0.24%     -0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/resource.(*procWrapper).Comm
     0.01s  0.24%  0.49%      0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/resource.WrapProc (inline)
         0     0%  0.49%      0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/resource.computeTypeInfoFromProc.func1
         0     0%  0.49%      0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/resource.containerInfoFromProc
         0     0%  0.49%     -0.01s  0.24%  github.com/sustainable-computing-io/kepler/internal/resource.newProcess
💾 Memory Comparison with base Kepler (Inuse)
File: kepler
Build ID: e8a9dff740522dead62bd6503cb9fec8d667ff15
Type: inuse_space
Time: 2026-02-07 13:32:24 UTC
Duration: 120.02s, Total samples = 11691.30kB 
Active filters:
   show=github.com/sustainable-computing-io
Showing nodes accounting for -2048.51kB, 17.52% of 11691.30kB total
      flat  flat%   sum%        cum   cum%
         0     0%     0% -2560.65kB 21.90%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*PowerCollector).Collect
         0     0%     0% -1536.45kB 13.14%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).Snapshot
 -512.05kB  4.38%  4.38% -1024.20kB  8.76%  github.com/sustainable-computing-io/kepler/internal/monitor.(*Process).Clone (inline)
         0     0%  4.38% -1024.20kB  8.76%  github.com/sustainable-computing-io/kepler/internal/monitor.(*Snapshot).Clone
         0     0%  4.38%  -512.26kB  4.38%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).calculatePower
         0     0%  4.38%  -512.26kB  4.38%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).calculateProcessPower
         0     0%  4.38%  -512.26kB  4.38%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).ensureFreshData
         0     0%  4.38%  -512.26kB  4.38%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).refreshSnapshot
         0     0%  4.38%  -512.26kB  4.38%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).synchronizedPowerRefresh
         0     0%  4.38%  -512.26kB  4.38%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).synchronizedPowerRefresh.func1
 -512.26kB  4.38%  8.76%  -512.26kB  4.38%  github.com/sustainable-computing-io/kepler/internal/monitor.newProcess (inline)
         0     0%  8.76%   512.14kB  4.38%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*gpuInfoCollector).Collect
 -512.14kB  4.38% 13.14%  -512.14kB  4.38%  maps.Copy[go.shape.map[github.com/sustainable-computing-io/kepler/internal/device.EnergyZone]github.com/sustainable-computing-io/kepler/internal/monitor.Usage,go.shape.map[github.com/sustainable-computing-io/kepler/internal/device.EnergyZone]github.com/sustainable-computing-io/kepler/internal/monitor.Usage,go.shape.interface { Energy ; Index int; MaxEnergy github.com/sustainable-computing-io/kepler/internal/device.Energy; Name string; Path string; Power  },go.shape.struct { EnergyTotal github.com/sustainable-computing-io/kepler/internal/device.Energy; Power github.com/sustainable-computing-io/kepler/internal/device.Power }] (inline)
 -512.05kB  4.38% 17.52%  -512.05kB  4.38%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*PowerCollector).collectProcessMetrics
💾 Memory Comparison with base Kepler (Alloc)
File: kepler
Build ID: e8a9dff740522dead62bd6503cb9fec8d667ff15
Type: alloc_space
Time: 2026-02-07 13:32:24 UTC
Duration: 120.02s, Total samples = 201.04MB 
Active filters:
   show=github.com/sustainable-computing-io
Showing nodes accounting for -16.06MB, 7.99% of 201.04MB total
      flat  flat%   sum%        cum   cum%
         0     0%     0%   -11.03MB  5.49%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*gpuInfoCollector).Collect
     -10MB  4.97%  4.97%      -10MB  4.97%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*PowerCollector).collectProcessMetrics
         0     0%  4.97%    -7.55MB  3.75%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).Snapshot
   -6.51MB  3.24%  8.21%    -6.51MB  3.24%  github.com/sustainable-computing-io/kepler/internal/resource.(*procWrapper).CPUTime
         0     0%  8.21%    -6.51MB  3.24%  github.com/sustainable-computing-io/kepler/internal/resource.(*resourceInformer).updateProcessCache
         0     0%  8.21%    -6.51MB  3.24%  github.com/sustainable-computing-io/kepler/internal/resource.populateProcessFields
         0     0%  8.21%    -6.02MB  2.99%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).ensureFreshData
         0     0%  8.21%    -6.01MB  2.99%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*PowerCollector).Collect
         0     0%  8.21%       -6MB  2.98%  github.com/sustainable-computing-io/kepler/internal/resource.(*resourceInformer).Refresh
   -1.02MB  0.51%  8.71%       -6MB  2.98%  github.com/sustainable-computing-io/kepler/internal/resource.(*resourceInformer).refreshProcesses
         0     0%  8.71%    -3.51MB  1.75%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).calculatePower
         0     0%  8.71%    -3.51MB  1.75%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).refreshSnapshot
         0     0%  8.71%    -3.51MB  1.75%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).synchronizedPowerRefresh
         0     0%  8.71%    -3.51MB  1.75%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).synchronizedPowerRefresh.func1
         0     0%  8.71%     2.51MB  1.25%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).scheduleNextCollection.func1
         0     0%  8.71%    -2.05MB  1.02%  github.com/sustainable-computing-io/kepler/internal/resource.computeTypeInfoFromProc.func2
   -2.05MB  1.02%  9.74%    -2.05MB  1.02%  github.com/sustainable-computing-io/kepler/internal/resource.vmInfoFromCmdLine
         0     0%  9.74%    -2.05MB  1.02%  github.com/sustainable-computing-io/kepler/internal/resource.vmInfoFromProc
    2.05MB  1.02%  8.72%     2.05MB  1.02%  github.com/sustainable-computing-io/kepler/internal/resource.(*procFSReader).CPUUsageRatio
         0     0%  8.72%     2.05MB  1.02%  github.com/sustainable-computing-io/kepler/internal/resource.(*resourceInformer).Refresh.func3
         0     0%  8.72%     2.05MB  1.02%  github.com/sustainable-computing-io/kepler/internal/resource.(*resourceInformer).refreshNode
         0     0%  8.72%    -2.01MB  1.00%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*cpuInfoCollector).Collect
   -2.01MB  1.00%  9.72%    -2.01MB  1.00%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*realProcFS).CPUInfo
       2MB  0.99%  8.72%        2MB  0.99%  github.com/sustainable-computing-io/kepler/internal/monitor.newProcess (inline)
    1.53MB  0.76%  7.96%     1.53MB  0.76%  github.com/sustainable-computing-io/kepler/internal/resource.(*procFSReader).AllProcs
   -1.03MB  0.51%  8.47%    -1.53MB  0.76%  github.com/sustainable-computing-io/kepler/internal/monitor.(*Snapshot).Clone
   -0.51MB  0.26%  8.73%     1.49MB  0.74%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).calculateProcessPower
      -1MB   0.5%  9.23%       -1MB   0.5%  maps.Copy[go.shape.map[github.com/sustainable-computing-io/kepler/internal/device.EnergyZone]github.com/sustainable-computing-io/kepler/internal/monitor.Usage,go.shape.map[github.com/sustainable-computing-io/kepler/internal/device.EnergyZone]github.com/sustainable-computing-io/kepler/internal/monitor.Usage,go.shape.interface { Energy ; Index int; MaxEnergy github.com/sustainable-computing-io/kepler/internal/device.Energy; Name string; Path string; Power  },go.shape.struct { EnergyTotal github.com/sustainable-computing-io/kepler/internal/device.Energy; Power github.com/sustainable-computing-io/kepler/internal/device.Power }] (inline)
         0     0%  9.23%        1MB   0.5%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*PlatformCollector).Collect
         0     0%  9.23%        1MB   0.5%  github.com/sustainable-computing-io/kepler/internal/platform/redfish.(*PowerReader).ReadAll
       1MB   0.5%  8.73%        1MB   0.5%  github.com/sustainable-computing-io/kepler/internal/platform/redfish.(*PowerReader).readPowerSubsystem
         0     0%  8.73%        1MB   0.5%  github.com/sustainable-computing-io/kepler/internal/platform/redfish.(*Service).Power
         0     0%  8.73%    -0.52MB  0.26%  github.com/sustainable-computing-io/kepler/internal/resource.computeTypeInfoFromProc.func1
   -0.52MB  0.26%  8.99%    -0.52MB  0.26%  github.com/sustainable-computing-io/kepler/internal/resource.containerInfoFromCgroupPaths
         0     0%  8.99%    -0.52MB  0.26%  github.com/sustainable-computing-io/kepler/internal/resource.containerInfoFromProc
    0.50MB  0.25%  8.74%    -0.50MB  0.25%  github.com/sustainable-computing-io/kepler/internal/monitor.(*Process).Clone (inline)
    0.50MB  0.25%  8.49%     0.50MB  0.25%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).calculateContainerPower
    0.50MB  0.25%  8.24%     0.50MB  0.25%  github.com/sustainable-computing-io/kepler/internal/monitor.(*PowerMonitor).calculatePodPower
         0     0%  8.24%     0.50MB  0.25%  github.com/sustainable-computing-io/kepler/internal/exporter/prometheus/collector.(*PowerCollector).collectVMMetrics
    0.50MB  0.25%  7.99%     0.50MB  0.25%  github.com/sustainable-computing-io/kepler/internal/logger.handlerForFormat.func1

⬇️ Download the Profiling artifacts from the Actions Summary page

📦 Artifact name: profile-artifacts-2409

🔧 Or use GitHub CLI to download artifacts:

gh run download 21780765994 -n profile-artifacts-2409

@vprashar2929 vprashar2929 marked this pull request as ready for review February 9, 2026 14:56
@codecov
Copy link

codecov bot commented Feb 9, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.92%. Comparing base (cdef473) to head (4ffe73a).
⚠️ Report is 1 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2409      +/-   ##
==========================================
+ Coverage   91.91%   91.92%   +0.01%     
==========================================
  Files          54       54              
  Lines        5365     5365              
==========================================
+ Hits         4931     4932       +1     
+ Misses        313      312       -1     
  Partials      121      121              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@vprashar2929 vprashar2929 force-pushed the test-cfg-pdinf branch 2 times, most recently from b3dd087 to 12b870f Compare February 13, 2026 08:14
This commit adds missing coverage for pod informer.

Signed-off-by: vprashar2929 <vibhu.sharma2929@gmail.com>
@vimalk78 vimalk78 merged commit 23cd767 into sustainable-computing-io:main Feb 16, 2026
26 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

test Adding or updating tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants