go-vmware-nsxt icon indicating copy to clipboard operation
go-vmware-nsxt copied to clipboard

Incomplete Struct `NodeStatusProperties`

Open schmikei opened this issue 3 years ago • 0 comments

Is your feature request related to a problem? Please describe.

I'm running NSX 3.1.2 in GCP and noticing some missing info on at least one struct.

The NodeStatusProperties struct is missing a corresponding cpu_usage object when retrieved from the Fabric API.

Endpoint hit: /api/v1/fabric/nodes/status?node_ids=c175ac2a-1070-46ca-8422-4119b9b126da

And /api/v1/transport-nodes/9c9df875-4f16-4298-b02b-c48aeed198c4/status link

{...
            "system_status": {
                "cpu_cores": 8,
                "dpdk_cpu_cores": 4,
                "non_dpdk_cpu_cores": 4,
                "disk_space_total": 162333740,
                "disk_space_used": 4710732,
                 ...
                "cpu_usage": {
                    "highest_cpu_core_usage_dpdk": 0.02,
                    "avg_cpu_core_usage_dpdk": 0.01,
                    "highest_cpu_core_usage_non_dpdk": 9.25,
                    "avg_cpu_core_usage_non_dpdk": 6.48
                },
                "edge_mem_usage": ...
                "mem_cache": 2761640,
                "mem_total": 32734844,
                "mem_used": 16683928,
                "source": "cached",
                "swap_total": 0,
                "swap_used": 0,
                "system_time": 1650917111000,
                "uptime": 16863459000
            },

Describe the solution you'd like

Add the missing struct fields with omitempty flags. Should be pretty straightforward I think.

Describe alternatives you've considered

I believe that this code may be autogenerated otherwise I would have made a PR but figured it was going to be a trivial feature request!

Let me know if you need any more details.

Additional context

No response

schmikei avatar Apr 26 '22 17:04 schmikei