Skip to content

Conversation

@leoparente
Copy link
Contributor

This pull request standardizes the logging of readiness messages across several backend components by unifying the log message format and the key used for version information. Instead of using different keys for each backend (e.g., worker_version, snmp_discovery_version), all readiness logs now use the key version. This makes log parsing and monitoring more consistent and easier to maintain.

Logging consistency improvements:

  • Standardized the readiness log message in device_discovery.go to use "version" as the key instead of "device_discovery_version".
  • Standardized the readiness log message in network_discovery.go to use "version" as the key instead of "network_discovery_version".
  • Standardized the readiness log message in opentelemetry_infinity.go to use "version" as the key instead of "opentelemetry_infinity_version".
  • Standardized the readiness log message in pktvisor.go to use "version" as the key instead of "pktvisor_version".
  • Standardized the readiness log message in snmp_discovery.go to use "version" as the key instead of "snmp_discovery_version".
  • Standardized the readiness log message in worker.go to use "version" as the key instead of "worker_version".

Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Standardizes readiness logging across multiple agent backends by using a consistent log message format and a unified structured logging key (version) for backend version reporting.

Changes:

  • Replaced backend-specific version keys (e.g., worker_version, snmp_discovery_version) with a single key: version.
  • Normalized the readiness “got version” log line formatting across the updated backends.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated no comments.

Show a summary per file
File Description
agent/backend/worker/worker.go Uses version as the structured log key for readiness version logging.
agent/backend/snmpdiscovery/snmp_discovery.go Uses version as the structured log key for readiness version logging.
agent/backend/pktvisor/pktvisor.go Uses version as the structured log key for readiness version logging.
agent/backend/opentelemetryinfinity/opentelemetry_infinity.go Uses version as the structured log key for readiness version logging.
agent/backend/networkdiscovery/network_discovery.go Uses version as the structured log key for readiness version logging.
agent/backend/devicediscovery/device_discovery.go Uses version as the structured log key for readiness version logging.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions
Copy link

Go test coverage

STATUS ELAPSED PACKAGE COVER PASS FAIL SKIP
🟢 PASS 1.06s github.com/netboxlabs/orb-agent/agent 44.5% 6 0 0
🟢 PASS 31.89s github.com/netboxlabs/orb-agent/agent/backend 75.2% 40 0 0
🟢 PASS 6.03s github.com/netboxlabs/orb-agent/agent/backend/devicediscovery 66.5% 4 0 0
🟢 PASS 0.98s github.com/netboxlabs/orb-agent/agent/backend/mocks 0.0% 0 0 0
🟢 PASS 6.04s github.com/netboxlabs/orb-agent/agent/backend/networkdiscovery 58.3% 4 0 0
🟢 PASS 4.02s github.com/netboxlabs/orb-agent/agent/backend/opentelemetryinfinity 45.2% 2 0 0
🟢 PASS 4.03s github.com/netboxlabs/orb-agent/agent/backend/pktvisor 67.0% 2 0 0
🟢 PASS 6.04s github.com/netboxlabs/orb-agent/agent/backend/snmpdiscovery 58.3% 4 0 0
🟢 PASS 7.04s github.com/netboxlabs/orb-agent/agent/backend/worker 67.4% 5 0 0
🟢 PASS 1.01s github.com/netboxlabs/orb-agent/agent/config 100.0% 6 0 0
🟢 PASS 1.38s github.com/netboxlabs/orb-agent/agent/configmgr 49.9% 32 0 0
🟢 PASS 2.71s github.com/netboxlabs/orb-agent/agent/configmgr/fleet 65.5% 141 0 0
🟢 PASS 1.02s github.com/netboxlabs/orb-agent/agent/otlpbridge 42.2% 8 0 0
🟢 PASS 1.01s github.com/netboxlabs/orb-agent/agent/policies 98.9% 18 0 0
🟢 PASS 1.03s github.com/netboxlabs/orb-agent/agent/policymgr 71.6% 11 0 0
🟢 PASS 1.02s github.com/netboxlabs/orb-agent/agent/redact 81.6% 84 0 0
🟢 PASS 18.58s github.com/netboxlabs/orb-agent/agent/secretsmgr 48.9% 54 0 0
🟢 PASS 1.02s github.com/netboxlabs/orb-agent/agent/telemetry 81.7% 19 0 0
🟢 PASS 1.01s github.com/netboxlabs/orb-agent/agent/version 100.0% 1 0 0

Total coverage: 60.1%

@leoparente leoparente merged commit 5b6af5f into develop Jan 29, 2026
11 checks passed
@leoparente leoparente deleted the chore/backend-versions branch January 29, 2026 20:38
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants