Comment 0 for bug 1452835

Revision history for this message
Hampapur Ajay (hajay) wrote :

There is scope for improvements in exception handling in api-server and vnc-openstack extension in following areas:

1. Raise exceptions but defer handling(abort etc.) from bottom of call stacks to upper-layers giving them a chance to handle gracefully if possible. (e.g. vnc_cfg_ifmap.py:dbe_read should raise NoIdError but not transform into error-message. In update notification context it is a valid situation and can be handled gracefully)
2. There are patterns of
      ok, result = <some-callable>()
      if not ok:
          <error handling>
      This should be enhanced to also catch exceptions that can be handled gracefully vs not with appropriate error message in latter case.
3. Currently api-server returns human-readable strings on exceptions. Enhance to also append a json part that can be used in machine invocation contexts to generate exceptions on the remote end.
4. It would be good to send exception information (gracefully handled or otherwise) to collector.