|
Post by jameslundberg on Jul 7, 2022 17:47:43 GMT
Does anyone know where...I would think it's the flask module...the entry point for the REST api calls coming in from a client is?
Like the place to start debugging the handling of an incoming curl or redfishtool command hitting the api?
|
|
|
Post by mraineri on Jul 7, 2022 20:30:09 GMT
In the vast majority of cases, this will be on a separate entity altogether (usually a BMC), and you will likely not be able to debug at that level.
However, I know you're currently using the Redfish Interface Emulator, so that is something you can certainly debug on your own system. I'm not entirely familiar with the inner workings of the emulator, but I do suspect it's somewhere in flask would be the starting point. It seems like the bulk of operations are offloaded to the "RedfishAPI" class found in emulator.py. That might be a good starting point to examine where things start getting handled. If you look for "@g.app.route" emulator.py, that seems to be how some of the initial hooks into flask are mapped.
|
|
|
Post by jameslundberg on Jul 7, 2022 22:26:39 GMT
Redfish Implementation Diagram.xlsx (16.03 KB) Sorry to be such a nub (minnow) still. But how do I setup a new system using these latest schema's. I'm not clear on the approach to build a simple blade server. I see the mockup setup, but how do I use the latest schema's and put our data in there. I noticed that you HAVE to use Python 3.6+ now because of that "xxxx: yyy" syntax error. It feels like I have till Monday to get this thing rolling or they want me to try it with interlinking Flask api's which ...duaaaa... that's what Redfish is...so I don't wanna do that even really. These should be the scheme's we need: Chassis Chassis.v1_20_0.json ComputerSystem ComputerSystem.v1_18_0.json Managers Manager.v1_15_0.json TaskService TaskService.v1_2_0.json SessionService SessionService.v1_1_8.json AccountService AccountService.v1_11_0.json EventService EventService.v1_8_0.json Registries AttributeRegistry.v1_3_6.json CompositionService CompositionService.v1_2.0.json
|
|
|
Post by jleung on Jul 8, 2022 15:23:39 GMT
Your question is regarding an implementation of the Redfish Service. DMTF specifies the interface, but is agnostic regarding implementations. Implementations can be in the BMC (baseboard management control) or a software agent. Open-source implementations can be found.
Since you mention flask, the Redfish Interface Emulator does use the flask package, in addition to flask-restful and flask_httpauth packages. If you do use the Emulator, note the README.md describes how to pass the -debug flag into flask for deep debugging.
|
|
|
Post by jameslundberg on Jul 8, 2022 23:19:06 GMT
Seems like RedfishEventListener would be useful in listening to the actual client requests so I'm going to play with that.
|
|