[openstack-dev] [openstackclient] Image create-or-update

2015-06-02 Thread Marek Aufart

Hi,

I have a question related to openstack image create command v1 from 
python-openstackclient.


It behaves like create-or-update (if image with *name* specified for 
create already existed, it is updated). Actually it looks, that it is in 
collision with glance, which allows create multiple images with same 
names instead of update one.


Is the create-or-update approach still wanted?

Related code:
https://github.com/openstack/python-openstackclient/blob/master/openstackclient/image/v1/image.py#L247-L269

Thanks.

--
Marek Aufart

Email: mauf...@redhat.com

IRC: maufart / aufi on freenode

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev


Re: [openstack-dev] [openstackclient] Image create-or-update

2015-06-03 Thread Marek Aufart

Hi Steve,

yes, it makes sense, thanks for clarification.

Flag --or-update for image create cmd looks as a good solution.

Marek

On 2.6.2015 23:34 Steve Martinelli wrote:

I'm thinking that the current approach is probably how we want to keep
things. I can't imagine many other projects being okay with multiple
create calls with the same name.
Though if you're really adamant about including that support, we could
include a new flag (--or-update) that performs the update if it's found,
otherwise it continues with a new create.

Does that make sense?

Thanks,

Steve Martinelli
OpenStack Keystone Core

Marek Aufart  wrote on 06/02/2015 10:55:20 AM:

 > From: Marek Aufart 
 > To: openstack-dev@lists.openstack.org
 > Date: 06/02/2015 10:55 AM
 > Subject: [openstack-dev] [openstackclient] Image create-or-update
 >
 > Hi,
 >
 > I have a question related to openstack image create command v1 from
 > python-openstackclient.
 >
 > It behaves like create-or-update (if image with *name* specified for
 > create already existed, it is updated). Actually it looks, that it is in
 > collision with glance, which allows create multiple images with same
 > names instead of update one.
 >
 > Is the create-or-update approach still wanted?
 >
 > Related code:
 > https://github.com/openstack/python-openstackclient/blob/master/
 > openstackclient/image/v1/image.py#L247-L269
 >
 > Thanks.
 >
 > --
 > Marek Aufart
 >
 > Email: mauf...@redhat.com
 >
 > IRC: maufart / aufi on freenode
 >
 >
__
 > OpenStack Development Mailing List (not for usage questions)
 > Unsubscribe:
openstack-dev-requ...@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-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev




--
Marek Aufart

Engineer, OpenStack Management UI team, Red Hat

Email: mauf...@redhat.com
Cell: +420 737 366 697
IRC: maufart / aufi on freenode

__
OpenStack Development Mailing List (not for usage questions)
Unsubscribe: openstack-dev-requ...@lists.openstack.org?subject:unsubscribe
http://lists.openstack.org/cgi-bin/mailman/listinfo/openstack-dev