Comment 2 for bug 1782075

Revision history for this message
Sowmya Rao (sowmyaraos) wrote :

Steps to reproduce by providing invalid URL [valid URL with HTTPS option]:
1) Task API from PostMan :

{
    "type": "import",
    "input": {
        "import_from": "https://xxxxxxxxxxxxxxx/log.qcow2",
        "import_from_format": "qcow2",
        "image_properties": {
            "disk_format": "qcow",
            "container_format": "bare",
            "name": "test-create2xxx"
        }

    }
}

Response from Task API :

{
    "status": "pending",
    "created_at": "2018-11-05T10:40:10Z",
    "updated_at": "2018-11-05T10:40:10Z",
    "self": "/v2/tasks/2d35894f-24a5-4ab6-8aba-3950008629e6",
    "result": null,
    "owner": "47441f261db046f9967ef099877369e4",
    "input": {
        "image_properties": {
            "container_format": "bare",
            "disk_format": "qcow",
            "name": "test-create2xxx"
        },
        "import_from_format": "qcow2",
        "import_from": "https://xxxxxxxxxxxxxxx/log.qcow2"
    },
    "message": "",
    "type": "import",
    "id": "2d35894f-24a5-4ab6-8aba-3950008629e6",
    "schema": "/v2/schemas/task"
}

2) Check the Task Progress :
{
    "status": "failure",
    "created_at": "2018-11-05T10:40:10Z",
    "updated_at": "2018-11-05T10:42:18Z",
    "expires_at": "2018-11-07T10:42:18Z",
    "self": "/v2/tasks/2d35894f-24a5-4ab6-8aba-3950008629e6",
    "result": null,
    "owner": "47441f261db046f9967ef099877369e4",
    "input": {
        "image_properties": {
            "container_format": "bare",
            "disk_format": "qcow",
            "name": "test-create2xxx"
        },
        "import_from_format": "qcow2",
        "import_from": "https://xxxxxxxxxxxxxxx/log.qcow2"
    },
    "message": "Task failed due to Internal Error",
    "type": "import",
    "id": "2d35894f-24a5-4ab6-8aba-3950008629e6",
    "schema": "/v2/schemas/task"
}

3) Log in to the VIM and view the Image :

[xxxx@undercloud (overcloudrc) ~]$ glance image-show 02503fd9-d29d-4d78-b31d-b6602a229ad1
+------------------+--------------------------------------+
| Property | Value |
+------------------+--------------------------------------+
| checksum | None |
| container_format | bare |
| created_at | 2018-11-05T10:40:10Z |
| disk_format | qcow |
| id | 02503fd9-d29d-4d78-b31d-b6602a229ad1 |
| locations | [] |
| min_disk | 0 |
| min_ram | 0 |
| name | test-create2xxx |
| owner | 47441f261db046f9967ef099877369e4 |
| protected | False |
| size | None |
| status | saving |
| tags | [] |
| updated_at | 2018-11-05T10:40:10Z |
| virtual_size | None |
| visibility | private |
+------------------+--------------------------------------+