← Back to team overview

yahoo-eng-team team mailing list archive

[Bug 1558876] [NEW] Inconsistent URLs reported from discovery endpoints

 

Public bug reported:

TLDR; the URLs returned from /, /v2.0 and /v3 are inconsistent.

In detail:
GET / returns
v3.4: http://172.16.14.31:35357/v3/
v2.0: http://172.16.14.31:35357/v2.0/

GET /v2.0 returns
http://172.16.14.31:35357/v2.0/

GET /v3 returns:
http://192.168.14.31:5000/v3/

Notice the /v3 URL is different, it reflects the public endpoint and the others are the admin endpoints.
The end effect is that 'openstack catalog list' (or any openstack CLI command) hangs when I access the v3 API because it gets redirected to an IP that I can't connect to (my client side can only see admin URLs).

More detail:

My catalog has the following in it:

+-----------+--------------------------------------+
| Field     | Value                                |
+-----------+--------------------------------------+
| endpoints | regionOne                            |
|           |   admin: http://172.16.14.31:35357   |
|           | regionOne                            |
|           |   internal: http://172.16.14.31:5000 |
|           | regionOne                            |
|           |   public: http://192.168.14.31:5000  |
|           |                                      |
| id        | 4709cfbbba2747f680750d0bcb31ef51     |
| name      | Identity Service                     |
| type      | identity                             |
+-----------+--------------------------------------+

Querying at /

$ curl http://172.16.14.20:35357/|python -m json.tool
{
    "versions": {
        "values": [
            {
                "id": "v3.4",
                "links": [
                    {
                        "href": "http://172.16.14.31:35357/v3/";,
                        "rel": "self"
                    }
                ],
                "media-types": [
                    {
                        "base": "application/json",
                        "type": "application/vnd.openstack.identity-v3+json"
                    }
                ],
                "status": "stable",
                "updated": "2015-03-30T00:00:00Z"
            },
            {
                "id": "v2.0",
                "links": [
                    {
                        "href": "http://172.16.14.31:35357/v2.0/";,
                        "rel": "self"
                    },
                    {
                        "href": "http://docs.openstack.org/";,
                        "rel": "describedby",
                        "type": "text/html"
                    }
                ],
                "media-types": [
                    {
                        "base": "application/json",
                        "type": "application/vnd.openstack.identity-v2.0+json"
                    }
                ],
                "status": "stable",
                "updated": "2014-04-17T00:00:00Z"
            }
        ]
    }
}

Querying at /v2.0:

$ curl http://172.16.14.20:35357/v2.0|python -m json.tool
{
    "version": {
        "id": "v2.0",
        "links": [
            {
                "href": "http://172.16.14.31:35357/v2.0/";,
                "rel": "self"
            },
            {
                "href": "http://docs.openstack.org/";,
                "rel": "describedby",
                "type": "text/html"
            }
        ],
        "media-types": [
            {
                "base": "application/json",
                "type": "application/vnd.openstack.identity-v2.0+json"
            }
        ],
        "status": "stable",
        "updated": "2014-04-17T00:00:00Z"
    }
}

And at /v3.0:

$ curl  http://172.16.14.20:35357/v3|python -m json.tool
{
    "version": {
        "id": "v3.4",
        "links": [
            {
                "href": "http://192.168.14.31:5000/v3/";,
                "rel": "self"
            }
        ],
        "media-types": [
            {
                "base": "application/json",
                "type": "application/vnd.openstack.identity-v3+json"
            }
        ],
        "status": "stable",
        "updated": "2015-03-30T00:00:00Z"
    }
}

** Affects: keystone
     Importance: Undecided
         Status: New

-- 
You received this bug notification because you are a member of Yahoo!
Engineering Team, which is subscribed to OpenStack Identity (keystone).
https://bugs.launchpad.net/bugs/1558876

Title:
  Inconsistent URLs reported from discovery endpoints

Status in OpenStack Identity (keystone):
  New

Bug description:
  TLDR; the URLs returned from /, /v2.0 and /v3 are inconsistent.

  In detail:
  GET / returns
  v3.4: http://172.16.14.31:35357/v3/
  v2.0: http://172.16.14.31:35357/v2.0/

  GET /v2.0 returns
  http://172.16.14.31:35357/v2.0/

  GET /v3 returns:
  http://192.168.14.31:5000/v3/

  Notice the /v3 URL is different, it reflects the public endpoint and the others are the admin endpoints.
  The end effect is that 'openstack catalog list' (or any openstack CLI command) hangs when I access the v3 API because it gets redirected to an IP that I can't connect to (my client side can only see admin URLs).

  More detail:

  My catalog has the following in it:

  +-----------+--------------------------------------+
  | Field     | Value                                |
  +-----------+--------------------------------------+
  | endpoints | regionOne                            |
  |           |   admin: http://172.16.14.31:35357   |
  |           | regionOne                            |
  |           |   internal: http://172.16.14.31:5000 |
  |           | regionOne                            |
  |           |   public: http://192.168.14.31:5000  |
  |           |                                      |
  | id        | 4709cfbbba2747f680750d0bcb31ef51     |
  | name      | Identity Service                     |
  | type      | identity                             |
  +-----------+--------------------------------------+

  Querying at /

  $ curl http://172.16.14.20:35357/|python -m json.tool
  {
      "versions": {
          "values": [
              {
                  "id": "v3.4",
                  "links": [
                      {
                          "href": "http://172.16.14.31:35357/v3/";,
                          "rel": "self"
                      }
                  ],
                  "media-types": [
                      {
                          "base": "application/json",
                          "type": "application/vnd.openstack.identity-v3+json"
                      }
                  ],
                  "status": "stable",
                  "updated": "2015-03-30T00:00:00Z"
              },
              {
                  "id": "v2.0",
                  "links": [
                      {
                          "href": "http://172.16.14.31:35357/v2.0/";,
                          "rel": "self"
                      },
                      {
                          "href": "http://docs.openstack.org/";,
                          "rel": "describedby",
                          "type": "text/html"
                      }
                  ],
                  "media-types": [
                      {
                          "base": "application/json",
                          "type": "application/vnd.openstack.identity-v2.0+json"
                      }
                  ],
                  "status": "stable",
                  "updated": "2014-04-17T00:00:00Z"
              }
          ]
      }
  }

  Querying at /v2.0:

  $ curl http://172.16.14.20:35357/v2.0|python -m json.tool
  {
      "version": {
          "id": "v2.0",
          "links": [
              {
                  "href": "http://172.16.14.31:35357/v2.0/";,
                  "rel": "self"
              },
              {
                  "href": "http://docs.openstack.org/";,
                  "rel": "describedby",
                  "type": "text/html"
              }
          ],
          "media-types": [
              {
                  "base": "application/json",
                  "type": "application/vnd.openstack.identity-v2.0+json"
              }
          ],
          "status": "stable",
          "updated": "2014-04-17T00:00:00Z"
      }
  }

  And at /v3.0:

  $ curl  http://172.16.14.20:35357/v3|python -m json.tool
  {
      "version": {
          "id": "v3.4",
          "links": [
              {
                  "href": "http://192.168.14.31:5000/v3/";,
                  "rel": "self"
              }
          ],
          "media-types": [
              {
                  "base": "application/json",
                  "type": "application/vnd.openstack.identity-v3+json"
              }
          ],
          "status": "stable",
          "updated": "2015-03-30T00:00:00Z"
      }
  }

To manage notifications about this bug go to:
https://bugs.launchpad.net/keystone/+bug/1558876/+subscriptions