You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@jclouds.apache.org by Zack Shoylev <no...@github.com> on 2015/03/20 04:57:58 UTC

[jclouds] Fix rackspace volume attach with modernized base tests (#710)

You can view, comment on, or merge this pull request online at:

  https://github.com/jclouds/jclouds/pull/710

-- Commit Summary --

  * Modernize the VolumeAttachmentApiLiveTest
  * Adds rackspace-specific test and fix for the volume-attach extension problem.
  * Make overriding properties easier and more consistent
  * Makes tests more extendable and fixes some issues with Rackspace.

-- File Changes --

    M apis/openstack-cinder/src/main/java/org/jclouds/openstack/cinder/v1/predicates/VolumePredicates.java (13)
    M apis/openstack-nova/pom.xml (6)
    M apis/openstack-nova/src/test/java/org/jclouds/openstack/nova/v2_0/extensions/VolumeAttachmentApiLiveTest.java (244)
    M apis/openstack-nova/src/test/java/org/jclouds/openstack/nova/v2_0/features/ServerApiLiveTest.java (4)
    M apis/openstack-nova/src/test/java/org/jclouds/openstack/nova/v2_0/internal/BaseNovaApiLiveTest.java (48)
    M core/src/test/java/org/jclouds/apis/BaseApiLiveTest.java (11)
    M providers/rackspace-cloudservers-us/pom.xml (6)
    M providers/rackspace-cloudservers-us/src/main/java/org/jclouds/rackspace/cloudservers/us/CloudServersUSProviderMetadata.java (17)
    A providers/rackspace-cloudservers-us/src/main/java/org/jclouds/rackspace/cloudservers/us/config/CloudServersUSHttpApiModule.java (124)
    A providers/rackspace-cloudservers-us/src/test/java/org/jclouds/rackspace/cloudservers/us/compute/extensions/CloudServersUSVolumeAttachmentExtensionLiveTest.java (42)

-- Patch Links --

https://github.com/jclouds/jclouds/pull/710.patch
https://github.com/jclouds/jclouds/pull/710.diff

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/710

Re: [jclouds] Fix rackspace volume attach with modernized base tests (#710)

Posted by Zack Shoylev <no...@github.com>.
This supercedes https://github.com/jclouds/jclouds/pull/709
Meaning we can just merge this and it should fix the issues.

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/710#issuecomment-83887062

Re: [jclouds] Fix rackspace volume attach with modernized base tests (#710)

Posted by Ignasi Barrera <no...@github.com>.
I've run the same test with the RC1 version (without the applied patches) and the volume attachment API is also absent for HP cloud there.

@ccustine @everett-toews @zack-shoylev Is this ok? If not, I think we should report it as a known issue (as no one have complaint about it before and it already existed) and release 1.9.0 with the provided patch. WDYT?

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/710#issuecomment-84935704

Re: [jclouds] Fix rackspace volume attach with modernized base tests (#710)

Posted by Ignasi Barrera <no...@github.com>.
Following the discussion in the other PR, I think I get it now. Cinder is used just to setup the volume, but the attachment api, which is the one being tested here, is the one in Nova, right? In that case lgtm!

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/710#issuecomment-83944727

Re: [jclouds] Fix rackspace volume attach with modernized base tests (#710)

Posted by Chris Custine <no...@github.com>.
@nacx @everett-toews @zack-shoylev I am delivering a project this week so I have been heads down crunching on that, but to be honest I don't totally understand the issue as it related to HP Cloud.  HPs nova supports os-volumes extension and IIRC cinder already has the attachment support baked in. Let me know if I am wrong about that, and specifically let me know if there is any specific test you want me to  run and report.  I tried to run the tests against RC1 and I had failures for other (unrelated) issues so it seems.

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/710#issuecomment-84948440

Re: [jclouds] Fix rackspace volume attach with modernized base tests (#710)

Posted by Ignasi Barrera <no...@github.com>.
Ok, I've opened https://github.com/jclouds/jclouds/pull/711 to fix the attachment in HPCloud. Basically it requires the same attachment extension namespace than Rackspace, and the test needed to be a bit more generic, as the Cinder version provided by HPCloud is 1.0, while the Compute version is v2.

@zack-shoylev @everett-toews I've seen that the RAX UK provider was not updated with the volume attachment changes. Should it be updated too? If so, can you please raise a PR? (I don't have an account there to test it).

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/710#issuecomment-85096609

Re: [jclouds] Fix rackspace volume attach with modernized base tests (#710)

Posted by Ignasi Barrera <no...@github.com>.
I've tried to run the live test on HPCloud as follows:

```bash
mvn test -Plive -Dtest.openstack-nova.endpoint="https://region-a.geo-1.identity.hpcloudsvc.com:35357/v2.0/" \
    -Dtest.openstack-nova.identity="<identity>" \
    -Dtest.openstack-nova.credential="<credential>" \
    -Dtest.openstack-nova.image-id=bec3cab5-4722-40b9-a78a-3489218e22fe \
    -Dtest.openstack-nova.flavor-id=standard.small  \
    -Djclouds.keystone.credential-type=apiAccessKeyCredentials \
    -Dtest.openstack-nova.region=region-a.geo-1
    -Dtest=VolumeAttachmentApiLiveTest
```

But I get the following failure, in [this line](https://github.com/jclouds/jclouds/blob/master/apis/openstack-nova/src/test/java/org/jclouds/openstack/nova/v2_0/extensions/VolumeAttachmentApiLiveTest.java#L84). Is it normal that the attachment api is not available in HPCloud? /cc @ccustine @everett-toews 

```bash
setup(org.jclouds.openstack.nova.v2_0.extensions.VolumeAttachmentApiLiveTest)  Time elapsed: 7.562 sec  <<< FAILURE!
java.lang.IllegalStateException: Optional.get() cannot be called on an absent value
	at com.google.common.base.Absent.get(Absent.java:47)
	at org.jclouds.openstack.nova.v2_0.extensions.VolumeAttachmentApiLiveTest.setup(VolumeAttachmentApiLiveTest.java:84)
```

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/710#issuecomment-84369333

Re: [jclouds] Fix rackspace volume attach with modernized base tests (#710)

Posted by Zack Shoylev <no...@github.com>.
Alright @nacx. I am about to rebase and merge this

---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds/pull/710#issuecomment-84062210