[EC2] StopInstance response missing instanceset info

Bug #1321239 reported by Swami Reddy
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
High
Swami Reddy

Bug Description

Stoptinstance response elements shown as below:

Sample Request to stop the specified instance:
===
https://ec2.amazonaws.com/?Action=StopInstances
&InstanceId.1=i-10a64379
&AUTHPARAMS
==

Response elements are:
==
":<StopInstancesResponse xmlns=""http://ec2.amazonaws.com/doc/2013-10-15/"">
  <requestId>req-30edb813-5802-4fa2-8a83-9dbcb751264e</requestId>
  <return>true</return>
</StopInstancesResponse>
"

But as per the AWS API reference doc, the response elements shown be as below:
==
<StopInstancesResponse xmlns="http://ec2.amazonaws.com/doc/2014-02-01/">
  <requestId>59dbff89-35bd-4eac-99ed-be587EXAMPLE</requestId>
  <instancesSet>
    <item>
      <instanceId>i-10a64379</instanceId>
      <currentState>
          <code>64</code>
          <name>stopping</name>
      </currentState>
      <previousState>
          <code>16</code>
          <name>running</name>
      </previousState>
  </instancesSet>
</StopInstancesResponse>
===

The <instanceSet> information missing in the response elements.

Tags: ec2
Swami Reddy (swamireddy)
tags: added: ec2
Swami Reddy (swamireddy)
Changed in nova:
importance: Undecided → High
assignee: nobody → Swami Reddy (swamireddy)
Swami Reddy (swamireddy)
Changed in nova:
status: New → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

Fix proposed to branch: master
Review: https://review.openstack.org/95799

Revision history for this message
Jay Pipes (jaypipes) wrote :

Swami, for the StopInstance element in the 2013-10-15 EC2 API version that OpenStack EC2 publishes, the subelement is actually *NOT* instancesSet, but rather InstanceIdSetType, which looks like this:

 <InstancesSet>
   <instanceId>XXXXX</instanceId>
 </instancesSet>

Revision history for this message
Swami Reddy (swamireddy) wrote : Re: [Bug 1321239] Re: [EC2] StopInstance response missing instanceset info

Jay: Thanks for quick review. Can you please share the
link/url for openstack EC2 API ref. document(latest)?

Thanks
Swami

On Wed, May 28, 2014 at 1:48 AM, Jay Pipes <email address hidden>wrote:

> Swami, for the StopInstance element in the 2013-10-15 EC2 API version
> that OpenStack EC2 publishes, the subelement is actually *NOT*
> instancesSet, but rather InstanceIdSetType, which looks like this:
>
> <InstancesSet>
> <instanceId>XXXXX</instanceId>
> </instancesSet>
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1321239
>
> Title:
> [EC2] StopInstance response missing instanceset info
>
> Status in OpenStack Compute (Nova):
> In Progress
>
> Bug description:
> Stoptinstance response elements shown as below:
>
> Sample Request to stop the specified instance:
> ===
> https://ec2.amazonaws.com/?Action=StopInstances
> &InstanceId.1=i-10a64379
> &AUTHPARAMS
> ==
>
> Response elements are:
> ==
> ":<StopInstancesResponse xmlns=""
> http://ec2.amazonaws.com/doc/2013-10-15/"">
> <requestId>req-30edb813-5802-4fa2-8a83-9dbcb751264e</requestId>
> <return>true</return>
> </StopInstancesResponse>
> "
>
> But as per the AWS API reference doc, the response elements shown be as
> below:
> ==
> <StopInstancesResponse xmlns="http://ec2.amazonaws.com/doc/2014-02-01/">
> <requestId>59dbff89-35bd-4eac-99ed-be587EXAMPLE</requestId>
> <instancesSet>
> <item>
> <instanceId>i-10a64379</instanceId>
> <currentState>
> <code>64</code>
> <name>stopping</name>
> </currentState>
> <previousState>
> <code>16</code>
> <name>running</name>
> </previousState>
> </instancesSet>
> </StopInstancesResponse>
> ===
>
> The <instanceSet> information missing in the response elements.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/nova/+bug/1321239/+subscriptions
>

Revision history for this message
Swami Reddy (swamireddy) wrote :

Jay - Could you please share the 2013-10-15 EC2 API version that openstack EC2 published?

Revision history for this message
Swami Reddy (swamireddy) wrote :

Hi Jay - I have checked the 2013-10-15 WSDL file for SotpInstance response.
It shows as below:
==
"StopInstancesResponseType"
  req requestid type is string

   instanceSet Type is "InstanceStateChangeSetType"
==

But as per youf comment - the instanceSet type is ÏnstanceSetIdType. Please
confirm the same.

Thanks
Swami

On Wed, May 28, 2014 at 1:48 AM, Jay Pipes <email address hidden>
wrote:

> Swami, for the StopInstance element in the 2013-10-15 EC2 API version
> that OpenStack EC2 publishes, the subelement is actually *NOT*
> instancesSet, but rather InstanceIdSetType, which looks like this:
>
> <InstancesSet>
> <instanceId>XXXXX</instanceId>
> </instancesSet>
>
> --
> You received this bug notification because you are subscribed to the bug
> report.
> https://bugs.launchpad.net/bugs/1321239
>
> Title:
> [EC2] StopInstance response missing instanceset info
>
> Status in OpenStack Compute (Nova):
> In Progress
>
> Bug description:
> Stoptinstance response elements shown as below:
>
> Sample Request to stop the specified instance:
> ===
> https://ec2.amazonaws.com/?Action=StopInstances
> &InstanceId.1=i-10a64379
> &AUTHPARAMS
> ==
>
> Response elements are:
> ==
> ":<StopInstancesResponse xmlns=""
> http://ec2.amazonaws.com/doc/2013-10-15/"">
> <requestId>req-30edb813-5802-4fa2-8a83-9dbcb751264e</requestId>
> <return>true</return>
> </StopInstancesResponse>
> "
>
> But as per the AWS API reference doc, the response elements shown be as
> below:
> ==
> <StopInstancesResponse xmlns="http://ec2.amazonaws.com/doc/2014-02-01/">
> <requestId>59dbff89-35bd-4eac-99ed-be587EXAMPLE</requestId>
> <instancesSet>
> <item>
> <instanceId>i-10a64379</instanceId>
> <currentState>
> <code>64</code>
> <name>stopping</name>
> </currentState>
> <previousState>
> <code>16</code>
> <name>running</name>
> </previousState>
> </instancesSet>
> </StopInstancesResponse>
> ===
>
> The <instanceSet> information missing in the response elements.
>
> To manage notifications about this bug go to:
> https://bugs.launchpad.net/nova/+bug/1321239/+subscriptions
>

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/95799
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=502fa4875a3975990cbdf84fc0f846f7ede8fa92
Submitter: Jenkins
Branch: master

commit 502fa4875a3975990cbdf84fc0f846f7ede8fa92
Author: Swami Reddy <email address hidden>
Date: Sat Jul 12 08:21:25 2014 +0530

    Add instanceset info to StopInstance response

    Currently stopinstance response missing the instanceset
    information with InstanceID, current state and previous
    state details. It just returns the "True".

    As per the AWS EC2 API reference document, the StopInstance
    response elements should include the instanceset information
    as below:
    <StopInstancesResponse xmlns="http://ec2.amazonaws.com/doc/2014-02-01/">
      <requestId>req-a7326465-5ce2-4ed6-ab89-394b38cca85f</requestId>
      <instancesSet>
        <item>
          <instanceId>i-00000001</instanceId>
          <currentState>
            <code>80</code>
            <name>stopped</name>
          </currentState>
          <previousState>
            <code>16</code>
            <name>running</name>
          </previousState>
        </item>
      </instancesSet>
    </StopInstancesResponse>

    Included the instanceset into stopinstance response elements
    and updated the test cases for stopinstance response elements
    in nova/tests/api/ec2/test_cloud.py file.

    Closes-bug: #1321239

    Change-Id: I4d8a6faf2689a7df71920183682fd1e403ce2a42

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
milestone: none → juno-3
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in nova:
milestone: juno-3 → 2014.2
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.