[openstack-dev] [cinder][nova] Question on Cinder client exception handling
Matt Riedemann
mriedem at linux.vnet.ibm.com
Thu May 7 20:37:46 UTC 2015
On 5/7/2015 3:21 PM, Chen CH Ji wrote:
> no, I only want to confirm whether cinder folks is doing this or there
> are already tricks can be used that before submit the change ... thanks
>
> Best Regards!
>
> Kevin (Chen) Ji 纪 晨
>
> Engineer, zVM Development, CSTL
> Notes: Chen CH Ji/China/IBM at IBMCN Internet: jichenjc at cn.ibm.com
> Phone: +86-10-82454158
> Address: 3/F Ring Building, ZhongGuanCun Software Park, Haidian
> District, Beijing 100193, PRC
>
> Inactive hide details for Matt Riedemann ---05/07/2015 10:12:21 PM---On
> 5/6/2015 7:02 AM, Chen CH Ji wrote: > HiMatt Riedemann ---05/07/2015
> 10:12:21 PM---On 5/6/2015 7:02 AM, Chen CH Ji wrote: > Hi
>
> From: Matt Riedemann <mriedem at linux.vnet.ibm.com>
> To: openstack-dev at lists.openstack.org
> Date: 05/07/2015 10:12 PM
> Subject: Re: [openstack-dev] [cinder][nova] Question on Cinder client
> exception handling
>
> ------------------------------------------------------------------------
>
>
>
>
>
> On 5/6/2015 7:02 AM, Chen CH Ji wrote:
> > Hi
> > In order to work on [1] , nova need to know what kind of
> > exception are raised when using cinderclient so that it can handle like
> > [2] did?
> > In this case, we don't need to distinguish the error
> > case based on string compare , it's more accurate and less error leading
> > Anyone is doing it or any other methods I can use to
> > catch cinder specified exception in nova? Thanks
> >
> >
> > [1] https://bugs.launchpad.net/nova/+bug/1450658
> > [2]
> >
> https://github.com/openstack/python-neutronclient/blob/master/neutronclient/v2_0/client.py#L64
> >
> > Best Regards!
> >
> > Kevin (Chen) Ji 纪 晨
> >
> > Engineer, zVM Development, CSTL
> > Notes: Chen CH Ji/China/IBM at IBMCN Internet: jichenjc at cn.ibm.com
> > Phone: +86-10-82454158
> > Address: 3/F Ring Building, ZhongGuanCun Software Park, Haidian
> > District, Beijing 100193, PRC
> >
> >
> >
> __________________________________________________________________________
> > OpenStack Development Mailing List (not for usage questions)
> > Unsubscribe:
> OpenStack-dev-request at lists.openstack.org?subject:unsubscribe
> > http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
> >
>
> Is there anything preventing us from adding a more specific exception to
> cinderclient and then once that's in and released, we can pin the
> minimum version of cinderclient in global-requirements so nova can
> safely use it?
>
> --
>
> Thanks,
>
> Matt Riedemann
>
>
> __________________________________________________________________________
> OpenStack Development Mailing List (not for usage questions)
> Unsubscribe: OpenStack-dev-request at lists.openstack.org?subject:unsubscribe
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
>
>
> __________________________________________________________________________
> OpenStack Development Mailing List (not for usage questions)
> Unsubscribe: OpenStack-dev-request at lists.openstack.org?subject:unsubscribe
> http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev
>
I added some notes to the bug after looking into the cinder code. I
think this would actually be a series of changes if you want something
more specific than the 500 you're getting back from the cinder API
today, and that's going to be several changes (cinder to raise a more
specific error, cinderclient to translate that to a specific exception,
and then nova to handle that).
I'd probably just go with a change to nova to handle the 500 from cinder
and not completely puke and orphan the instance.
--
Thanks,
Matt Riedemann
More information about the OpenStack-dev
mailing list