Avoid constructing the whole resource tree at connect()
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
python-redfish |
Triaged
|
Undecided
|
Unassigned |
Bug Description
This bug is related to [0] which points out that python-redfish is extremely verbose, perhaps, this one describes the reason for that.
Basically, as soon as you invoke connect()[1] python-redfish will follow pretty much all links to the resources in the Redfish tree and build objects from it, even if you only need to get a single one (say one System, which represents a "Node" in Ironic).
One thing that I've learned working in Ironic is that BMCs are fragile, I worry about the way things are architected in python-redfish because a simple connect could hammer the BMC with many requests at once, the more resources you have, say 1000 resources (between Systems, Managers and Chassis), this is going to be 7000+ requests at startup (Note, this is just an approximately number, keep reading.)
Back to [0], the example I'm using here contains only 1 System, 1 Chassis and 1 Manager [2]. This is enough for python-redfish to send 21 requests [3] and produce 1000+ lines of debug code (mostly for dumping the representation of the objects it creates) at the very first connect().
With the simulator this is not a problem, but I'm afraid that with a real piece of hardware this is going to be problematic.
[0] https:/
[1] For example:
import redfish
redfish.
[2] http://
[3] http://
More info:
----------
The tests are running the Redfish simulator version 1.0.0 (DSP2043), direct link: https:/
With the mockup server: https:/
description: | updated |
summary: |
- Avoid constructing the whole resources tree at connect() + Avoid constructing the whole resource tree at connect() |
description: | updated |
description: | updated |
description: | updated |
description: | updated |
description: | updated |
Changed in python-redfish: | |
milestone: | none → 0.6 |
FYI, we are testing the library against real hardware:
- HPE BL460C G9 server using ILO4
- Moonshot server using ILOCM
- m510x cartridge using a "custom" ILO4.
So far, we didn't see issues with those hardware.
The issue is more related to the time to gather the data. ILO4 are using fast processor, so it takes time to retrieve the data.
Maybe we need to add a "switch" to select the part we want to retrieve (system, chassis...). We will think about that.
As well, maybe we should implement a refresh method, to update data without the need to reconnect.