Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: handle only labels in zapi snapshotpolicy #3444

Merged
merged 1 commit into from
Jan 29, 2025

Conversation

Hardikl
Copy link
Contributor

@Hardikl Hardikl commented Jan 28, 2025

No description provided.

@Hardikl
Copy link
Contributor Author

Hardikl commented Jan 28, 2025

Before the fix:

% ./bin/poller -p sar -c Zapi -o SnapshotPolicy --promPort 19001 
time=2025-01-28T20:00:57.505+05:30 level=INFO source=poller.go:231 msg=Init Poller=sar logLevel=INFO configPath=harvest.yml cwd=/Users/hardikl/Documents/Harvest/harvest version="harvest version 25.01.22-1 (commit de48ebc1) (build date 2025-01-22T19:37:15+0530) darwin/amd64" options="&{Poller:sar Daemon:false Debug:false PromPort:19001 Config:harvest.yml HomePath: LogPath:/var/log/harvest/ LogFormat:plain LogLevel:2 LogToFile:false Version:25.01.22 Hostname:hardikl-mac-0 Collectors:[Zapi] Objects:[SnapshotPolicy] Profiling:0 Asup:false IsTest:false ConfPath:conf ConfPaths:[conf]}"
time=2025-01-28T20:00:57.509+05:30 level=INFO source=poller.go:269 msg="started in foreground" Poller=sar pid=15837
time=2025-01-28T20:00:59.319+05:30 level=INFO source=poller.go:1519 msg="Cluster info" Poller=sar remote="{Name:umeng-aff300-01-02 Model:cdot UUID:cbd1757b-0580-11e8-bd9d-00a098d39e12 Version:9.15.1 Release:NetApp Release Mightysquirrel__9.15.1: Fri May 24 05:03:10 UTC 2024 Serial: IsSanOptimized:false IsDisaggregated:false ZAPIsExist:true HasREST:true IsClustered:true}"
time=2025-01-28T20:00:59.326+05:30 level=INFO source=helpers.go:98 msg="best-fit template" Poller=sar collector=Zapi:SnapshotPolicy path=conf/zapi/cdot/9.8.0/snapshotpolicy.yaml v=9.15.1 jitter=none
time=2025-01-28T20:00:59.329+05:30 level=WARN source=poller.go:828 msg="init collector-object" Poller=sar error="no metrics => failed to parse any" collector=Zapi object=SnapshotPolicy
time=2025-01-28T20:00:59.329+05:30 level=WARN source=poller.go:341 msg="no collectors initialized, stopping" Poller=sar
time=2025-01-28T20:00:59.329+05:30 level=INFO source=poller.go:668 msg="stopping poller" Poller=sar pid=15837

After the fix:

% ./bin/poller -p sar -c Zapi -o SnapshotPolicy --promPort 19001 
time=2025-01-28T20:01:04.791+05:30 level=INFO source=poller.go:231 msg=Init Poller=sar logLevel=INFO configPath=harvest.yml cwd=/Users/hardikl/Documents/Harvest/harvest version="harvest version 25.01.22-1 (commit de48ebc1) (build date 2025-01-22T19:37:15+0530) darwin/amd64" options="&{Poller:sar Daemon:false Debug:false PromPort:19001 Config:harvest.yml HomePath: LogPath:/var/log/harvest/ LogFormat:plain LogLevel:2 LogToFile:false Version:25.01.22 Hostname:hardikl-mac-0 Collectors:[Zapi] Objects:[SnapshotPolicy] Profiling:0 Asup:false IsTest:false ConfPath:conf ConfPaths:[conf]}"
time=2025-01-28T20:01:04.792+05:30 level=INFO source=poller.go:269 msg="started in foreground" Poller=sar pid=15845
time=2025-01-28T20:01:06.619+05:30 level=INFO source=poller.go:1519 msg="Cluster info" Poller=sar remote="{Name:umeng-aff300-01-02 Model:cdot UUID:cbd1757b-0580-11e8-bd9d-00a098d39e12 Version:9.15.1 Release:NetApp Release Mightysquirrel__9.15.1: Fri May 24 05:03:10 UTC 2024 Serial: IsSanOptimized:false IsDisaggregated:false ZAPIsExist:true HasREST:true IsClustered:true}"
time=2025-01-28T20:01:06.623+05:30 level=INFO source=helpers.go:98 msg="best-fit template" Poller=sar collector=Zapi:SnapshotPolicy path=conf/zapi/cdot/9.8.0/snapshotpolicy.yaml v=9.15.1 jitter=none
time=2025-01-28T20:01:06.625+05:30 level=INFO source=poller.go:405 msg="Autosupport scheduled" Poller=sar asupSchedule=24h
time=2025-01-28T20:01:06.625+05:30 level=INFO source=poller.go:415 msg="poller start-up complete" Poller=sar
time=2025-01-28T20:01:06.625+05:30 level=INFO source=httpd.go:50 msg="server listen" Poller=sar exporter=prometheus1 url=http://:19001/metrics
time=2025-01-28T20:01:06.871+05:30 level=INFO source=poller.go:637 msg="updated status" Poller=sar collectors.up=1 collectors.total=1 exporters.up=1 exporters.total=1
time=2025-01-28T20:01:07.370+05:30 level=INFO source=collector.go:601 msg=Collected Poller=sar collector=Zapi:SnapshotPolicy apiMs=741 bytesRx=3067 calcMs=0 exportMs=0 instances=6 instancesExported=6 metrics=54 metricsExported=8 numCalls=1 parseMs=1 pluginInstances=0 pluginMs=0 pollMs=745 renderedBytes=1633 zBegin=1738074666625
time=2025-01-28T20:01:07.719+05:30 level=INFO source=poller.go:1426 msg=Metadata Poller=sar remote.name=umeng-aff300-01-02 remote.version=9.15.1 version="harvest version 25.01.22-1 (commit de48ebc1) (build date 2025-01-22T19:37:15+0530) darwin/amd64" mem.liveHeapMB=0 mem.heapMB=0 mem.heapGoalMB=4 mem.rssMB=13 mem.maxRssMB=13 uptimeSeconds=2
time=2025-01-28T20:04:07.366+05:30 level=INFO source=collector.go:601 msg=Collected Poller=sar collector=Zapi:SnapshotPolicy apiMs=739 bytesRx=3067 calcMs=0 exportMs=0 instances=6 instancesExported=6 metrics=54 metricsExported=8 numCalls=1 parseMs=1 pluginInstances=0 pluginMs=0 pollMs=743 renderedBytes=1633 zBegin=1738074846623
time=2025-01-28T20:07:07.363+05:30 level=INFO source=collector.go:601 msg=Collected Poller=sar collector=Zapi:SnapshotPolicy apiMs=741 bytesRx=3067 calcMs=0 exportMs=0 instances=6 instancesExported=6 metrics=54 metricsExported=8 numCalls=1 parseMs=1 pluginInstances=0 pluginMs=0 pollMs=743 renderedBytes=1633 zBegin=1738075026620
time=2025-01-28T20:10:07.512+05:30 level=INFO source=collector.go:601 msg=Collected Poller=sar collector=Zapi:SnapshotPolicy apiMs=892 bytesRx=3067 calcMs=0 exportMs=0 instances=6 instancesExported=6 metrics=54 metricsExported=8 numCalls=1 parseMs=1 pluginInstances=0 pluginMs=0 pollMs=893 renderedBytes=1633 zBegin=1738075206618

@rahulguptajss rahulguptajss merged commit 3c6a2a6 into main Jan 29, 2025
10 checks passed
@rahulguptajss rahulguptajss deleted the hl_snapshot_policy_fix branch January 29, 2025 05:57
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.

no metrics => failed to parse any error seen in snapshotpolicy zapi collector
3 participants