[jira] [Created] (JCLOUDS-795) S3 should retry on 500 InternalError

2014-12-17 Thread Andrew Gaul (JIRA)
Andrew Gaul created JCLOUDS-795: --- Summary: S3 should retry on 500 InternalError Key: JCLOUDS-795 URL: https://issues.apache.org/jira/browse/JCLOUDS-795 Project: jclouds Issue Type: Improvement

[jira] [Created] (JCLOUDS-794) generic S3 provider should not provide default endpoint

2014-12-17 Thread Andrew Gaul (JIRA)
Andrew Gaul created JCLOUDS-794: --- Summary: generic S3 provider should not provide default endpoint Key: JCLOUDS-794 URL: https://issues.apache.org/jira/browse/JCLOUDS-794 Project: jclouds Issue

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
I don't like having two accessors for the same information either but we're choosing between the lesser of two evils here. If you only had `complexMetadata`, you'd be forcing users to always write code like Object value = image.getComplexMetadata().get("key"); if (value instanceof List)

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread monitorjbl
> super(id, name, links, uuid, tenantId, userId, updated, created, > hostId, accessIPv4, accessIPv6, status, null, flavor, keyName, configDrive, > addresses, metadata, extendedStatus, extendedAttributes, diskConfig); > } >} > } > + > + @Singleton > + public

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread monitorjbl
> + server.enqueue(addCommonHeaders(new > MockResponse().setBody(stringFromResource("/access.json"; > + server.enqueue(addCommonHeaders(new > MockResponse().setBody(stringFromResource("/image_list_with_block_device_mapping_object.json"; > + > + try { > + NovaApi nov

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> + server.enqueue(addCommonHeaders(new > MockResponse().setBody(stringFromResource("/access.json"; > + server.enqueue(addCommonHeaders(new > MockResponse().setBody(stringFromResource("/image_list_with_block_device_mapping_array.json"; > + > + try { > + NovaApi nova

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> + server.enqueue(addCommonHeaders(new > MockResponse().setBody(stringFromResource("/access.json"; > + server.enqueue(addCommonHeaders(new > MockResponse().setBody(stringFromResource("/image_list_with_block_device_mapping_object.json"; > + > + try { > + NovaApi nov

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> + @Override > + public Image deserialize(JsonElement jsonElement, Type type, > JsonDeserializationContext context) > + throws JsonParseException { > + JsonObject json = jsonElement.getAsJsonObject(); > + > + Map complexMetatdata = null; > + Map meta

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> @@ -271,6 +282,10 @@ public Resource getServer() { >return this.metadata; > } > > + public Map getComplexMetadata() { Put the Javadoc on both `getComplexMetadata()` and `getMetadata()`. Don't worry about the lack of Javadoc elsewhere in this class at the moment. It's these meth

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> }) > protected ServerInternalWithoutImage(String id, @Nullable String > name, java.util.Set links, @Nullable String uuid, String tenantId, > - String userId, Date updated, Date created, > @Nullable String hostId, @Nullable String accessIPv4,

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread monitorjbl
I think what @everett-toews was saying though is that `` is always going to be more common, so it's not desirable to force casting on every call to `getMetadata()`. It might make more sense to *only* populate `complexMetadata` with non-string data, because you're always guaranteed to get someth

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread monitorjbl
> +package org.jclouds.openstack.nova.v2_0.features; > + > +import com.google.common.collect.FluentIterable; > +import com.squareup.okhttp.mockwebserver.MockResponse; > +import com.squareup.okhttp.mockwebserver.MockWebServer; > +import org.jclouds.openstack.nova.v2_0.NovaApi; > +import org.jclouds.

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread monitorjbl
> @@ -271,6 +282,10 @@ public Resource getServer() { >return this.metadata; > } > > + public Map getComplexMetadata() { Where should I put that documentation? I didn't see much javadoc in this class. --- Reply to this email directly or view it on GitHub: https://github.com/jclouds

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread monitorjbl
> @@ -86,6 +86,7 @@ public static Status fromValue(String v) { >protected int minRam; >protected Resource server; >protected Map metadata = ImmutableMap.of(); Good question! I don't know if this is common enough in the greater community to warrant that, personally. I'm bas

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread monitorjbl
> + @Override > + public Image deserialize(JsonElement jsonElement, Type type, > JsonDeserializationContext context) > + throws JsonParseException { > + JsonObject json = jsonElement.getAsJsonObject(); > + > + Map complexMetatdata = null; > + Map meta

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread monitorjbl
> }) > protected ServerInternalWithoutImage(String id, @Nullable String > name, java.util.Set links, @Nullable String uuid, String tenantId, > - String userId, Date updated, Date created, > @Nullable String hostId, @Nullable String accessIPv4,

[jira] [Updated] (JCLOUDS-655) com.google.gson.JsonSyntaxException on trying to start a new instance with openstack

2014-12-17 Thread Everett Toews (JIRA)
[ https://issues.apache.org/jira/browse/JCLOUDS-655?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Everett Toews updated JCLOUDS-655: -- Assignee: Taylor Jones > com.google.gson.JsonSyntaxException on trying to start a new instance

Re: [jclouds-labs-openstack] Glance v2 implementation (#77)

2014-12-17 Thread Everett Toews
Nothing happening here. It's long past time to close this PR. I'll leave it to @inbarsto to choose a path forward. Considering the [Api/Provider Writing Practices](https://cwiki.apache.org/confluence/pages/viewpage.action?pageId=49578594) a fresh start may be in order. --- Reply to this email d

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Ignasi Barrera
I don't like having two accessors for the same information, but this is going to be temporal. I'm OK with the change as long as we mark the deprecation and properly document it. --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds/pull/626#issuecomment-673571

Re: [jclouds-labs-openstack] Support OpenStack Heat StackApi list() method (#159)

2014-12-17 Thread Everett Toews
>return props; > } > > + @Override > + @BeforeClass(groups = "live") > + public void setup() { > + super.setup(); > + String providedRegion = System.getProperty("test." + > LocationConstants.PROPERTY_REGION); > + if (providedRegion != null) { > +regions =

Re: [jclouds-labs-openstack] Support OpenStack Heat StackApi list() method (#159)

2014-12-17 Thread Everett Toews
> + > + try { > + HeatApi heatApi = api(server.getUrl("/").toString(), > "openstack-heat", overrides); > + StackApi api = heatApi.getStackApi("RegionOne"); > + > + AutoStack stack = api.get("simple_stack", > "3095aefc-09fb-4bc7-b1f0-f21a304e864c"); > + System.

Re: [jclouds-labs-openstack] Support OpenStack Heat StackApi list() method (#159)

2014-12-17 Thread Everett Toews
> + for (Method m : methods) { > +System.out.println(m.getName()); > + } > + > + /* > + * Check request > + */ > + assertThat(server.getRequestCount()).isEqualTo(2); > + assertAuthentication(server); > + assertRequest(ser

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Ignasi Barrera
> + @Override > + public Image deserialize(JsonElement jsonElement, Type type, > JsonDeserializationContext context) > + throws JsonParseException { > + JsonObject json = jsonElement.getAsJsonObject(); > + > + Map complexMetatdata = null; > + Map meta

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Ignasi Barrera
> @@ -86,6 +86,7 @@ public static Status fromValue(String v) { >protected int minRam; >protected Resource server; >protected Map metadata = ImmutableMap.of(); Should this field be marked `@Deprecated` and properly redirect to the new one int he javadoc? --- Reply to this

Re: [jclouds-labs-openstack] Support OpenStack Heat StackApi list() method (#159)

2014-12-17 Thread Everett Toews
> + /** > + * @param capabilities The capabilities of this Stack. > + * @return The builder object. > + * @see Stack#getCapabilities() > + */ > + public T capabilities(Set capabilities) { > + this.capabilities = capabilities; > + return self(); > +

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
I think this is a reasonable way to approach this and not break backwards compatibility or force the user to always deal with `Map` when the more common case is `Map` @nacx @inbarsto Since you were kind enough to reply to the [Dealing with different JSON value types in a Map](http://mail-archi

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> + } > +], > +"checksum": "32c08d302f9206668030d47789b77858", > +"min_ram": "1", > +"disk_format": "qcow2", > +"image_name": "Ubuntu LTS 14.04", > +"bdm_v2": "True", > +"image_id": "cfefefc1-eba2-4b1e-9b07-a8c74a872d65", > +"

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> +package org.jclouds.openstack.nova.v2_0.features; > + > +import com.google.common.collect.FluentIterable; > +import com.squareup.okhttp.mockwebserver.MockResponse; > +import com.squareup.okhttp.mockwebserver.MockWebServer; > +import org.jclouds.openstack.nova.v2_0.NovaApi; > +import org.jclouds.

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> @@ -271,6 +282,10 @@ public Resource getServer() { >return this.metadata; > } > > + public Map getComplexMetadata() { Both `getComplexMetadata()` and `getMetadata()` will need to be documented very well. Please explain why each one exists and that `metadata` will always be a su

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> + @Override > + public Image deserialize(JsonElement jsonElement, Type type, > JsonDeserializationContext context) > + throws JsonParseException { > + JsonObject json = jsonElement.getAsJsonObject(); > + > + Map complexMetatdata = null; > + Map meta

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> super(id, name, links, uuid, tenantId, userId, updated, created, > hostId, accessIPv4, accessIPv6, status, null, flavor, keyName, configDrive, > addresses, metadata, extendedStatus, extendedAttributes, diskConfig); > } >} > } > + > + @Singleton > + public

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> @@ -56,9 +61,10 @@ > @Singleton > public Map provideCustomAdapterBindings() { >return ImmutableMap.of( > -HostResourceUsage.class, new HostResourceUsageAdapter(), > -ServerWithSecurityGroups.class, new > ServerWithSecurityGroupsAdapter(), > -Se

Re: [jclouds] Fix for JCLOUDS-655 (#626)

2014-12-17 Thread Everett Toews
> }) > protected ServerInternalWithoutImage(String id, @Nullable String > name, java.util.Set links, @Nullable String uuid, String tenantId, > - String userId, Date updated, Date created, > @Nullable String hostId, @Nullable String accessIPv4,

[jira] [Commented] (JCLOUDS-664) Azure compute support

2014-12-17 Thread Andrea Turli (JIRA)
[ https://issues.apache.org/jira/browse/JCLOUDS-664?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14249993#comment-14249993 ] Andrea Turli commented on JCLOUDS-664: -- Hi [~Bhash90], Good start! I think OSImageT

Re: [jclouds-labs] [JCLOUDS-702] JCloud ProfitBricks provider implementation (#72)

2014-12-17 Thread Ignasi Barrera
Thanks @devcsrj! I'll have a look at the PR this week so you can move forward. --- Reply to this email directly or view it on GitHub: https://github.com/jclouds/jclouds-labs/pull/72#issuecomment-67297972