Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
ospfd: convert uptime to epoch for ip ospf neigh
Currently, json output of show ip ospf neighbor commands are having "uptime" in "17.515s" format. uptime is converted into epoch format and added json attributes. Supported commands: ``` show ip ospf vrf <vrf-id> neighbor json show ip ospf vrf <VRFNAME> neighbor <neighbor-id> json ``` Sample ip ospf neighbor json output: ``` tor-21# show ip ospf vrf default neighbor swp1 json { "6.0.0.9":[ { "nbrState":"Full\/-", "nbrPriority":1, "converged":"Full", "role":"DROther", "upTimeInMsec":17515, "routerDeadIntervalTimerDueMsec":32482, "upTime":"17.515s", "deadTime":"32.482s", "ospfNeighUptimeEpoch":1691046764, "ospfNeighUptimeEpochStr":"Thu Aug 3 07:12:44 2023\n", "ifaceAddress":"6.0.0.9", "ifaceName":"swp1:6.0.0.17", "linkStateRetransmissionListCounter":0, "linkStateRequestListCounter":0, "databaseSummaryListCounter":0 } ] } tor-21# ``` Ticket:#3541629 Issue:3541629 Testing: UT done Signed-off-by: Sindhu Parvathi Gopinathan's <[email protected]>
- Loading branch information