Bug 969097 - RHEVM-CLI: "power management user name" flag usage, wasn't updated as in help and auto complete
Summary: RHEVM-CLI: "power management user name" flag usage, wasn't updated as in help...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: Red Hat Enterprise Virtualization Manager
Classification: Red Hat
Component: ovirt-engine-restapi
Version: 3.2.0
Hardware: Unspecified
OS: Unspecified
unspecified
medium
Target Milestone: ---
: 3.3.0
Assignee: Ori Liel
QA Contact: Barak Dagan
URL:
Whiteboard: infra
Depends On:
Blocks: 970237 977354
TreeView+ depends on / blocked
 
Reported: 2013-05-30 16:03 UTC by Barak Dagan
Modified: 2016-02-10 19:12 UTC (History)
8 users (show)

Fixed In Version: is2
Doc Type: Bug Fix
Doc Text:
Clone Of:
: 970237 (view as bug list)
Environment:
Last Closed: 2014-01-21 22:16:46 UTC
oVirt Team: Infra
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
oVirt gerrit 15299 0 None None None Never

Description Barak Dagan 2013-05-30 16:03:50 UTC
Description of problem:
Flag was changed from power-management-username to power-management-user_name in both help and auto completion, however the cli works with the old name, while rejecting the new one. 

Version-Release number of selected component (if applicable):

SF 17.3

backend version: 3.2
sdk version    : 3.2.0.11
cli version    : 3.2.0.9
python version : 2.6.6.final.0

How reproducible:
100%

Steps to Reproduce:

1. Using auto completion:
[RHEVM shell (connected)]# update host 'rose02' --storage_manager-priority 5 --power_management-user_name 'user'


error: "user_name" is invalid argument segment.

2. Using old flag
[RHEVM shell (connected)]# update host 'rose02' --storage_manager-priority 5 --power_management-username 'user'

id                                : 739107e5-6dc2-4506-926f-aae9009e6f03
name                              : rose02
address                           : rose02.qa.lab.tlv.redhat.com
....

3. help:
[RHEVM shell (connected)]# help add host

USAGE
  
  add <type> [parent identifiers] [command options]
  
DESCRIPTION
  
  Creates a new object or adds existent with type host. See 'help add' for generic
  help on creating objects.
  
ATTRIBUTE OPTIONS
  
  The following options are available for objects with type host:
  
...
    * [--power_management-enabled: boolean]
    * [--power_management-address: string]
    * [--power_management-user_name: string]
    * [--power_management-password: string]

Actual results:


Expected results:


Additional info:

Comment 6 Barak Dagan 2013-07-01 16:09:57 UTC
Verified on SF18.2

RSDL:

1) href="/api/hosts" rel="add">
<parameter required="false" type="xs:string"><name>host.power_management.username</name>
</parameter>

2) href="/api/hosts/{host:id}" rel="update">
<parameter required="false" type="xs:string"><name>host.power_management.username</name>
</parameter>

REST:

1) Update PM

PUT request content is --  url:api/hosts/24a98a45-c1e6-40b0-851d-f6e70aafaf7b body: <host>
<power_management type="apc_snmp">
<enabled>true</enabled>
<address>1.1.1.2</address>
<username>aaa</username>
<password>pswrd</password>
<options>
   <option name="slot" value="2"/>
</options>
<pm_proxies>
   <pm_proxy>
       <type>cluster</type>
   </pm_proxy>
   <pm_proxy>
     <type>dc</type>
   </pm_proxy>
</pm_proxies>

<agents>
	   <agent type="apc_snmp">
	   <address>1.1.1.2</address>
	   <username>aaa</username>
	   <password>pswrd</password>
	   <concurrent>false</concurrent>
	   <order>1</order>   
	   </agent>
</agents>
</power_management>
</host>

Comment 7 Barak Dagan 2013-07-02 08:42:23 UTC
Verified on IS3
---------------

Comment 9 Itamar Heim 2014-01-21 22:16:46 UTC
Closing - RHEV 3.3 Released

Comment 10 Itamar Heim 2014-01-21 22:23:27 UTC
Closing - RHEV 3.3 Released


Note You need to log in before you can comment on or make changes to this bug.