You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@jclouds.apache.org by Alix Lourme <no...@github.com> on 2018/05/07 11:35:56 UTC

[jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

See [JCLOUDS-1414](https://issues.apache.org/jira/browse/JCLOUDS-1414), documentation about Openstack keystone v2/v3 usage
You can view, comment on, or merge this pull request online at:

  https://github.com/jclouds/jclouds-site/pull/214

-- Commit Summary --

  * #JCLOUDS-1414: Documentation about Openstack Keystone v2/v3 usage

-- File Changes --

    M guides/openstack.md (128)

-- Patch Links --

https://github.com/jclouds/jclouds-site/pull/214.patch
https://github.com/jclouds/jclouds-site/pull/214.diff

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrea Turli <no...@github.com>.
andreaturli approved this pull request.





-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#pullrequestreview-118055261

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
> pointing maybe the reader to the authentication section above instead of using

I have hesitate to do that ... but the current snippet explicits how to retrieve an API (nova, swift, ...) even if v2 is deprecated (v3 needs more code).
So keystone considerations was writted before (hoping that user read it before trying sample).

Perhaps a consensus could be to add a comment before `ContextBuilder` like:
```
// Please refer to 'Keystone v2-v3 authentication' for complete authentication use case
```

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387059221

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrea Turli <no...@github.com>.
Actually @axel3rd I think we should somehow edit `List Servers` and `Swift: Use Containers` paragraphs as well pointing maybe the reader to the authentication section above instead of using 
```
        novaApi = ContextBuilder.newBuilder(provider)
                .endpoint("http://xxx.xxx.xxx.xxx:5000/v2.0/")
                .credentials(identity, credential)
                .modules(modules)
                .buildApi(NovaApi.class);
```
wdyt? 

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387054793

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
axel3rd commented on this pull request.



> +{% highlight java %}
+final Properties overrides = new Properties();
+overrides.put(KeystoneProperties.KEYSTONE_VERSION, "2");
+overrides.put(KeystoneProperties.TENANT_NAME, "myTenant");
+
+ContextBuilder.newBuilder("openstack-nova")
+   .endpoint("https://host:5000/v2.0")
+   .credentials("foo", "bar")
+   .overrides(overrides)
+   .buildApi(NovaApi.class);
+{% endhighlight %}
+
+Will produce when authentication needed: 
+
+    POST https://host:5000/v2.0/tokens HTTP/1.1
+    {

Configure logging to see what exactly is sent is simple (jclouds write the property to set to `true` and SLF4J in debug).

The (little) difficulty in jclouds authentication usage is the option to configure. It depends mainly of OpenStack platform configuration (v2, v3, domains, ...) ... and some manual REST tries on token endpoint could be required to see what is supported by the platform.

So these snippet are to help the user on jclouds usage when it has found its way of auhentication on OpenStack.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#discussion_r187590966

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Ignasi Barrera <no...@github.com>.
One minor comment, but it would help readability if you format the generated json auth example.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387061588

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrew Phillips <no...@github.com>.
demobox commented on this pull request.



> @@ -92,6 +93,220 @@ There are some differences in terminology between jclouds and OpenStack that sho
   </div>
 </div>
 
+## <a id="keystone"></a>Keystone v2-v3 authentication
+
+Openstack Keystone (aka: [OpenStack Identity Service](https://docs.openstack.org/keystone/latest/)) has major changes between v2 and v3 (detail. [Identity API v2.0 and v3 History](https://docs.openstack.org/keystone/latest/contributor/http-api.html)).

[minor] Quite a few instances of "Openstack" (lowercase `s`) rather than "OpenStack" here - is that worth cleaning up?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#pullrequestreview-119285885

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Ignasi Barrera <no...@github.com>.
We can change that. As long as the feature does not break backward compat, I see no problem in adding it in the next bugfix release. It will help adoption and facilitate early testing.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-388055263

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
> Yes ... and perhaps some minor change on properties name in progress ...

Done, 1 line changed:

    overrides.put(KeystoneProperties.PROJECT_DOMAIN_NAME, "default"); // Since jclouds v2.2.0 (see PROJECT_DOMAIN_ID as complement)

Linked with [jclouds#1204](https://github.com/jclouds/jclouds/pull/1204).

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387118744

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Ignasi Barrera <no...@github.com>.
nacx commented on this pull request.



> +
+Openstack Keystone (aka: [OpenStack Identity Service](https://docs.openstack.org/keystone/latest/)) has major changes between v2 and v3 (detail. [Identity API v2.0 and v3 History](https://docs.openstack.org/keystone/latest/contributor/http-api.html)).
+
+Basically to login, you should provide:
+
+* On v2: *tenant*, *user*, *password*.
+* On v3: a *project* (new name for *tenant*), an authentication *domain* for this *project*, a *user*, an authentication *domain* for this *user* (the two domains can be different).
+
+JClouds provide backward compatibility between keystone v2-v3 ... but you should have following section in mind to fully understand the authentication on your Openstack platform (in addition of blog: [OpenStack Keystone V3 Support](https://jclouds.apache.org/blog/2018/01/16/keystone-v3/)).
+
+### v2
+
+This snippet:
+{% highlight java %}
+final Properties overrides = new Properties();
+overrides.put(KeystoneProperties.KEYSTONE_VERSION, "2");

I'd leave it here for clarity. Also as we move forward version 2 will be eventually deprecated and removed, so better encourage users to be explicit about the version being used.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#discussion_r186418467

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Ignasi Barrera <no...@github.com>.
nacx approved this pull request.

Thanks! LGTM.
Since you reference a new keystone property I'd hold this and merge once the changes in Keystone are merged and the new property exists.



-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#pullrequestreview-118007596

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrew Phillips <no...@github.com>.
demobox commented on this pull request.



> +{% highlight java %}
+final Properties overrides = new Properties();
+overrides.put(KeystoneProperties.KEYSTONE_VERSION, "2");
+overrides.put(KeystoneProperties.TENANT_NAME, "myTenant");
+
+ContextBuilder.newBuilder("openstack-nova")
+   .endpoint("https://host:5000/v2.0")
+   .credentials("foo", "bar")
+   .overrides(overrides)
+   .buildApi(NovaApi.class);
+{% endhighlight %}
+
+Will produce when authentication needed: 
+
+    POST https://host:5000/v2.0/tokens HTTP/1.1
+    {

Is there any particular benefit to trying to list the request so exactly here? In my experience, these are the parts of documentation that go stale very quickly.

Can we instead either give the code samples to the user and explain how they can configure logging to see what exactly is being sent (if that is necessary), or describe this a bit more abstractly, e.g. in form of a table?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#pullrequestreview-119286746

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
@demobox : Thanks for the review. I will do it in a // PR (this one merged) after feedback on my remarks.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-388340627

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by jclouds-commentator <no...@github.com>.
  Go to http://d6762342ecf65bd47950-3e336ecb7f68d8dda5e5d435de17b0ef.r3.cf5.rackcdn.com/ to review your changes.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387041036

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
> Since you reference a new keystone property I'd hold this and merge once the changes in Keystone are merged and the new property exists.

Yes ... and perhaps some minor change on properties name in progress ...

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387103146

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
> Perhaps a consensus could be to add a comment before ContextBuilder like [...]:
> One minor comment, but it would help readability if you format the generated json auth example.

Done (without new-line-comma for json, to reduce lines number). Last proposal: [Keystone v2-v3 authentication (and following)](https://eb3572d47d95412306ae-9ba5d3580b14e830c75c09652bfd2f59.ssl.cf5.rackcdn.com/guides/openstack/#keystone)

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387065719

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrew Phillips <no...@github.com>.
> I will do it in a // PR (this one merged) after feedback on my remarks.

Thanks for taking a look! I should add that I think most of my comments are minor, and it's also fine to leave things as they are unless we feel there's really a good reason for a follow-up PR.

And thanks for helping improve the jclouds documentation, of course!

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-388361099

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by jclouds-commentator <no...@github.com>.
  Go to http://e8a2320cb8ee7328bc9a-98112aaa434232edc359e0c94cafc2fa.r90.cf5.rackcdn.com/ to review your changes.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387039696

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by jclouds-commentator <no...@github.com>.
  Go to http://ad99be29f1570e3a80bb-ec8c9f9fa769d9cd6f2ad277a7469fe8.r48.cf5.rackcdn.com/ to review your changes.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387118535

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by jclouds-commentator <no...@github.com>.
  Go to http://393f4caa8037a748294f-756fd4e7d22e69a6f0ff4346cb78ae2b.r35.cf5.rackcdn.com/ to review your changes.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387053460

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Ignasi Barrera <no...@github.com>.
Changes merged and published to the website. Thanks @axel3rd!

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387996647

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Ignasi Barrera <no...@github.com>.
Often these tiny PRs get more review comments and change requests than thousand lines ones! :)

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-388175880

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrew Phillips <no...@github.com>.
demobox commented on this pull request.



> @@ -92,6 +93,220 @@ There are some differences in terminology between jclouds and OpenStack that sho
   </div>
 </div>
 
+## <a id="keystone"></a>Keystone v2-v3 authentication
+
+Openstack Keystone (aka: [OpenStack Identity Service](https://docs.openstack.org/keystone/latest/)) has major changes between v2 and v3 (detail. [Identity API v2.0 and v3 History](https://docs.openstack.org/keystone/latest/contributor/http-api.html)).
+
+Basically to login, you should provide:
+
+* On v2: *tenant*, *user*, *password*.
+* On v3: a *project* (new name for *tenant*), an authentication *domain* for this *project*, a *user*, an authentication *domain* for this *user* (the two domains can be different).
+
+jclouds provides backward compatibility between keystone v2-v3 ... but you should have following section in mind to fully understand the authentication on your Openstack platform (in addition of blog: [OpenStack Keystone V3 Support](https://jclouds.apache.org/blog/2018/01/16/keystone-v3/)).

[minor] "...compatibility between Keystone v2 and v3, but you should keep the following in mind to fully understand authentication against your OpenStack platform:

```
lots of examples
```

See also the recent "OpenStack Keystone v3 Support" blog post.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#pullrequestreview-119286397

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
Some tries about code & list typo, the last looks fine: Openstack [Keystone v2-v3 authentication](https://d6762342ecf65bd47950-3e336ecb7f68d8dda5e5d435de17b0ef.ssl.cf5.rackcdn.com/guides/openstack/#keystone)

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387041537

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by jclouds-commentator <no...@github.com>.
  Go to http://ae4404efef77109c76ca-bf5e3651b7ed971bf54720901bab17d5.r49.cf5.rackcdn.com/ to review your changes.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387063260

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
@nacx : As a "new feature", I didn't thought it was could be integrated in v2.1.x, I will be attentive to the roadmap because this PR doc is perhaps not true:  : [Keystone v2-v3 authentication](https://jclouds.apache.org/guides/openstack/#keystone) (*v3: Project-scoped*)

    overrides.put(KeystoneProperties.PROJECT_DOMAIN_NAME, "default"); // Since jclouds v2.2.0 (see PROJECT_DOMAIN_ID as complement)

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-388049924

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by jclouds-commentator <no...@github.com>.
  Go to http://4c17ddefb1e1845a6081-9bb6552a57750bbb30de030b38a1ebcc.r36.cf5.rackcdn.com/ to review your changes.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387040430

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrea Turli <no...@github.com>.
andreaturli commented on this pull request.



> +
+Openstack Keystone (aka: [OpenStack Identity Service](https://docs.openstack.org/keystone/latest/)) has major changes between v2 and v3 (detail. [Identity API v2.0 and v3 History](https://docs.openstack.org/keystone/latest/contributor/http-api.html)).
+
+Basically to login, you should provide:
+
+* On v2: *tenant*, *user*, *password*.
+* On v3: a *project* (new name for *tenant*), an authentication *domain* for this *project*, a *user*, an authentication *domain* for this *user* (the two domains can be different).
+
+JClouds provide backward compatibility between keystone v2-v3 ... but you should have following section in mind to fully understand the authentication on your Openstack platform (in addition of blog: [OpenStack Keystone V3 Support](https://jclouds.apache.org/blog/2018/01/16/keystone-v3/)).
+
+### v2
+
+This snippet:
+{% highlight java %}
+final Properties overrides = new Properties();
+overrides.put(KeystoneProperties.KEYSTONE_VERSION, "2");

thanks @axel3rd for the quick update

I think from nova code https://github.com/jclouds/jclouds/blob/master/apis/openstack-nova/src/main/java/org/jclouds/openstack/nova/v2_0/NovaApiMetadata.java#L74 the default keystone version is 3 but the extra property would probably not hurt

@demobox @nacx any preference?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#discussion_r186412487

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrea Turli <no...@github.com>.
thanks @axel3rd 


-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387117770

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by jclouds-commentator <no...@github.com>.
  Go to http://44ce6b87f08c84c4a336-587a4214cfc62e403204a0b0eced474e.r98.cf5.rackcdn.com/ to review your changes.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387038294

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by jclouds-commentator <no...@github.com>.
  Go to http://eb3572d47d95412306ae-9ba5d3580b14e830c75c09652bfd2f59.r53.cf5.rackcdn.com/ to review your changes.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387065407

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Ignasi Barrera <no...@github.com>.
Closed #214.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#event-1619360327

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
So very valuable *2 characters* PR ^^ : #215

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-388060585

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrew Phillips <no...@github.com>.
demobox commented on this pull request.



> @@ -146,6 +361,7 @@ public class JCloudsNova implements Closeable {
         String identity = "demo:demo"; // tenantName:userName
         String credential = "devstack";
 
+        // Please refer to 'Keystone v2-v3 authentication' chapter for complete authentication use case

[minor] "section" rather than "chapter"? Also, should this comment perhaps come before the declaration of `String identity`?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#pullrequestreview-119286904

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrew Phillips <no...@github.com>.
demobox commented on this pull request.



> @@ -92,6 +93,220 @@ There are some differences in terminology between jclouds and OpenStack that sho
   </div>
 </div>
 
+## <a id="keystone"></a>Keystone v2-v3 authentication
+
+Openstack Keystone (aka: [OpenStack Identity Service](https://docs.openstack.org/keystone/latest/)) has major changes between v2 and v3 (detail. [Identity API v2.0 and v3 History](https://docs.openstack.org/keystone/latest/contributor/http-api.html)).
+
+Basically to login, you should provide:

[minor] Drop "basically"; just "To login, provide:"?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#pullrequestreview-119285951

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
axel3rd commented on this pull request.



> +
+Openstack Keystone (aka: [OpenStack Identity Service](https://docs.openstack.org/keystone/latest/)) has major changes between v2 and v3 (detail. [Identity API v2.0 and v3 History](https://docs.openstack.org/keystone/latest/contributor/http-api.html)).
+
+Basically to login, you should provide:
+
+* On v2: *tenant*, *user*, *password*.
+* On v3: a *project* (new name for *tenant*), an authentication *domain* for this *project*, a *user*, an authentication *domain* for this *user* (the two domains can be different).
+
+JClouds provide backward compatibility between keystone v2-v3 ... but you should have following section in mind to fully understand the authentication on your Openstack platform (in addition of blog: [OpenStack Keystone V3 Support](https://jclouds.apache.org/blog/2018/01/16/keystone-v3/)).
+
+### v2
+
+This snippet:
+{% highlight java %}
+final Properties overrides = new Properties();
+overrides.put(KeystoneProperties.KEYSTONE_VERSION, "2");

According the Javadoc the [default is 3](https://github.com/jclouds/jclouds/blob/master/apis/openstack-keystone/src/main/java/org/jclouds/openstack/keystone/config/KeystoneProperties.java#L91) ; but I have not verified or really measured the impact to not provide this property ...

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#discussion_r186407829

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
@andreaturli : Thanks for grammar fix & suggestions. Fixed in [Keystone v2-v3 authentication](https://393f4caa8037a748294f-756fd4e7d22e69a6f0ff4346cb78ae2b.ssl.cf5.rackcdn.com/guides/openstack/#keystone). Except about `KeystoneProperties.KEYSTONE_VERSION` ... not sure about that.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#issuecomment-387053975

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Andrea Turli <no...@github.com>.
andreaturli requested changes on this pull request.

thanks @axel3rd it is super useful!

I've left some comments mainly on the snippets: please address them and edit the document accordingly, i.e.  if you replace `Some.class` with `NovaApi.class` make sure you do it all over the places.

Thanks

> @@ -92,6 +93,131 @@ There are some differences in terminology between jclouds and OpenStack that sho
   </div>
 </div>
 
+## <a id="keystone"></a>Keystone v2-v3 authentication
+
+Openstack Keystone (aka: [OpenStack Identity Service](https://docs.openstack.org/keystone/latest/)) has major changes between v2 and v3 (detail. [Identity API v2.0 and v3 History](https://docs.openstack.org/keystone/latest/contributor/http-api.html)).
+
+Basically to login, you should provide:
+
+* On v2: *tenant*, *user*, *password*.
+* On v3: a *project* (new name for *tenant*), an authentication *domain* for this *project*, a *user*, an authentication *domain* for this *user* (the two domains can be different).
+
+JClouds provide backward compatibility between keystone v2-v3 ... but you should have following section in mind to fully understand the authentication on your Openstack platform (in addition of blog: [OpenStack Keystone V3 Support](https://jclouds.apache.org/blog/2018/01/16/keystone-v3/)).

please use `jclouds` or `Apache jclouds`

> @@ -92,6 +93,131 @@ There are some differences in terminology between jclouds and OpenStack that sho
   </div>
 </div>
 
+## <a id="keystone"></a>Keystone v2-v3 authentication
+
+Openstack Keystone (aka: [OpenStack Identity Service](https://docs.openstack.org/keystone/latest/)) has major changes between v2 and v3 (detail. [Identity API v2.0 and v3 History](https://docs.openstack.org/keystone/latest/contributor/http-api.html)).
+
+Basically to login, you should provide:
+
+* On v2: *tenant*, *user*, *password*.
+* On v3: a *project* (new name for *tenant*), an authentication *domain* for this *project*, a *user*, an authentication *domain* for this *user* (the two domains can be different).
+
+JClouds provide backward compatibility between keystone v2-v3 ... but you should have following section in mind to fully understand the authentication on your Openstack platform (in addition of blog: [OpenStack Keystone V3 Support](https://jclouds.apache.org/blog/2018/01/16/keystone-v3/)).

`provides` instead of `provide`

> +
+Openstack Keystone (aka: [OpenStack Identity Service](https://docs.openstack.org/keystone/latest/)) has major changes between v2 and v3 (detail. [Identity API v2.0 and v3 History](https://docs.openstack.org/keystone/latest/contributor/http-api.html)).
+
+Basically to login, you should provide:
+
+* On v2: *tenant*, *user*, *password*.
+* On v3: a *project* (new name for *tenant*), an authentication *domain* for this *project*, a *user*, an authentication *domain* for this *user* (the two domains can be different).
+
+JClouds provide backward compatibility between keystone v2-v3 ... but you should have following section in mind to fully understand the authentication on your Openstack platform (in addition of blog: [OpenStack Keystone V3 Support](https://jclouds.apache.org/blog/2018/01/16/keystone-v3/)).
+
+### v2
+
+This snippet:
+{% highlight java %}
+final Properties overrides = new Properties();
+overrides.put(KeystoneProperties.KEYSTONE_VERSION, "2");

isn't `KEYSTONE_VERSION=2` the default?

> +
+Basically to login, you should provide:
+
+* On v2: *tenant*, *user*, *password*.
+* On v3: a *project* (new name for *tenant*), an authentication *domain* for this *project*, a *user*, an authentication *domain* for this *user* (the two domains can be different).
+
+JClouds provide backward compatibility between keystone v2-v3 ... but you should have following section in mind to fully understand the authentication on your Openstack platform (in addition of blog: [OpenStack Keystone V3 Support](https://jclouds.apache.org/blog/2018/01/16/keystone-v3/)).
+
+### v2
+
+This snippet:
+{% highlight java %}
+final Properties overrides = new Properties();
+overrides.put(KeystoneProperties.KEYSTONE_VERSION, "2");
+
+ContextBuilder.newBuilder(new SomeApiMetadata())

why `new SomeApiMetadata()`? wouldn't be clear with something as generic as `openstack-nova`

> +* On v3: a *project* (new name for *tenant*), an authentication *domain* for this *project*, a *user*, an authentication *domain* for this *user* (the two domains can be different).
+
+JClouds provide backward compatibility between keystone v2-v3 ... but you should have following section in mind to fully understand the authentication on your Openstack platform (in addition of blog: [OpenStack Keystone V3 Support](https://jclouds.apache.org/blog/2018/01/16/keystone-v3/)).
+
+### v2
+
+This snippet:
+{% highlight java %}
+final Properties overrides = new Properties();
+overrides.put(KeystoneProperties.KEYSTONE_VERSION, "2");
+
+ContextBuilder.newBuilder(new SomeApiMetadata())
+   .endpoint("https://host:5000/v2.0")
+   .credentials("myTenant:foo", "bar")
+   .overrides(overrides)
+   .buildApi(Some.class);

why `Some.class` here? I think `NovaApi.class` is a bit better, as it is now in http://jclouds.apache.org/guides/openstack/#nova, wdyt?

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#pullrequestreview-117969130

Re: [jclouds/jclouds-site] Documentation about Openstack Keystone v2/v3 usage (#214)

Posted by Alix Lourme <no...@github.com>.
axel3rd commented on this pull request.



> @@ -92,6 +93,220 @@ There are some differences in terminology between jclouds and OpenStack that sho
   </div>
 </div>
 
+## <a id="keystone"></a>Keystone v2-v3 authentication
+
+Openstack Keystone (aka: [OpenStack Identity Service](https://docs.openstack.org/keystone/latest/)) has major changes between v2 and v3 (detail. [Identity API v2.0 and v3 History](https://docs.openstack.org/keystone/latest/contributor/http-api.html)).

In [official documentation](https://docs.openstack.org/latest/), "S" is in uppercase. I can do the cleanup in a way or the other, but we should choose :)

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-site/pull/214#discussion_r187589481