Skip to content

[xcvrd] add support for logging mux_metrics events into state DB#185

Merged
vdahiya12 merged 2 commits intosonic-net:masterfrom
vdahiya12:metrics
May 17, 2021
Merged

[xcvrd] add support for logging mux_metrics events into state DB#185
vdahiya12 merged 2 commits intosonic-net:masterfrom
vdahiya12:metrics

Conversation

@vdahiya12
Copy link
Contributor

@vdahiya12 vdahiya12 commented May 13, 2021

Signed-off-by: vaibhav-dahiya [email protected]

Description

This PR adds support for logging events for change requests received by xcvrd from swss into state DB.
a typical log would look like this:
1) "xcvrd_switch_standby_start"
2) "2021-05-13 10:01:15.690835"
3) "xcvrd_switch_standby_end"
4) "2021-05-13 10:01:15.696051"

where the key-value pairs signify the type of event requested out of
active/standby/unknown and the timestamp associated with the event.

Motivation and Context

This is required for xcvrd to log the events which it receives in form of requests from swss or any other module into the DB. The timestamp will be useful for debugging the timeline of an event processing from a perspective of other modules as well as xcvrd itself.

How Has This Been Tested?

ran the changes on starlab testbed, by changing the file in the container.

Additional Information (Optional)

@lgtm-com

This comment has been minimized.

Signed-off-by: vaibhav-dahiya <[email protected]>
@vdahiya12 vdahiya12 merged commit e60804c into sonic-net:master May 17, 2021
qiluo-msft pushed a commit that referenced this pull request May 18, 2021
* [xcvrd] add support for logging mux_metrics events into state DB

Description
This PR adds support for logging events for change requests received by xcvrd from swss into state DB.
a typical log would look like this:
1) "xcvrd_switch_standby_start"
2) "2021-05-13 10:01:15.690835"
3) "xcvrd_switch_standby_end"
4) "2021-05-13 10:01:15.696051"

where the key-value pairs signify the type of event requested out of
active/standby/unknown and the timestamp associated with the event.

Motivation and Context
This is required for xcvrd to log the events which it receives in form of requests from swss or any other module into the DB. The timestamp will be useful for debugging the timeline of an event processing from a perspective of other modules as well as xcvrd itself.

How Has This Been Tested?
ran the changes on starlab testbed, by changing the file in the container.

Signed-off-by: vaibhav-dahiya <[email protected]>
@vdahiya12 vdahiya12 deleted the metrics branch May 21, 2021 00:23
andywongarista pushed a commit to andywongarista/sonic-platform-daemons that referenced this pull request Jun 30, 2021
…ic-net#185)

* [xcvrd] add support for logging mux_metrics events into state DB

Description
This PR adds support for logging events for change requests received by xcvrd from swss into state DB.
a typical log would look like this:
1) "xcvrd_switch_standby_start"
2) "2021-05-13 10:01:15.690835"
3) "xcvrd_switch_standby_end"
4) "2021-05-13 10:01:15.696051"

where the key-value pairs signify the type of event requested out of
active/standby/unknown and the timestamp associated with the event.

Motivation and Context
This is required for xcvrd to log the events which it receives in form of requests from swss or any other module into the DB. The timestamp will be useful for debugging the timeline of an event processing from a perspective of other modules as well as xcvrd itself.

How Has This Been Tested?
ran the changes on starlab testbed, by changing the file in the container.

Signed-off-by: vaibhav-dahiya <[email protected]>
vdahiya12 pushed a commit to vdahiya12/sonic-platform-daemons that referenced this pull request Apr 4, 2022
…et#185)

Add a generic function that returns a list of asics on module. Vendors will implement their own for their platform.

The function could be used for collecting fabric asic info in each module and populating into CHASSIS_STATE_DB (sonic-net#175). To simplify the change, all fabric cards in system should be identical in terms of number of asics in a card.
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.

3 participants