diff options
author | Carson Labrado <clabrado@google.com> | 2022-06-01 19:01:52 +0300 |
---|---|---|
committer | Ed Tanous <ed@tanous.net> | 2022-06-15 03:22:52 +0300 |
commit | a7a80296f731ef1069d3ecfbd3069668fb71cd68 (patch) | |
tree | d2d7ec05983bdeb6e37daea2c10b0fe6a284d9b5 /redfish-core/lib | |
parent | cec58fe39551f162a9aec9ebbb359876f8f2e762 (diff) | |
download | bmcweb-a7a80296f731ef1069d3ecfbd3069668fb71cd68.tar.xz |
bmcweb: Set Retry Policy Valid Response Codes
Allows individual retry policies to specify what HTTP response codes
are considered valid. Sets functions for the EventService and
Redfish Aggregation retry policies. Those functions expect a
response code and return an error code based on what the response
code is.
This change is needed because EventService only considers 2XX codes
to be valid. Any code outside of that range would trigger a retry
attempt. Redfish Aggregation by design will need to return
errors outside of that range such as 404. It should not retry to
send a message when it receives a 404 from a satellite BMC.
Right now 404 is the only error code that is handled differently
between the services. Going forward, Redfish Aggregation will
likely want to allow other error codes as its functionality is
expanded.
Tested:
Used Redfish-Event-Listener with ssh port forwarding to create 3
subscriptions. I then closed the ssh connection and sent a test
event. Bmcweb made 3 retry attempts for each subscription. At
that point the max retry amount (as defined by EventService) was
reached and bmcweb stop attempting to resend the messages.
There were no errors when the Redfish-Event-Listener was correctly
connected. Test events resulted in messages being sent for each
subscription.
Signed-off-by: Carson Labrado <clabrado@google.com>
Change-Id: Ifdfaf638d28982ed18998f3ca05280a288e0020a
Diffstat (limited to 'redfish-core/lib')
0 files changed, 0 insertions, 0 deletions