应用引擎BAE-专业版

    关联服务相关接口

    关联服务相关接口

    获取关联的SCS

    方法 API 说明
    GET /v1/env/{envId}/scs 获取环境关联的SCS实例

    返回参数

    参数名称 参数类型 说明
    scsIds List<String> 与环境关联的SCS实例ID列表

    请求示例

    GET /v1/env/baeenv-iix5bwc10hfw/scs HTTP/1.1
    HOST: baepro.bj.baidubce.com
    Authorization: {authorization}
    Content-Type: application/json; charset=utf-8
    x-bce-date: 2016-06-01T23:00:10Z

    返回示例

    HTTP/1.1 200 OK
    Content-Type: application/json; charset=utf-8
    x-bce-request-id: 9ebc57ed-1ff5-480f-b5b1-6847ff54f2b4
    
    {
        "scsIds": ["9280", "9381"]
    }

    设置关联的SCS

    方法 API 说明
    PUT /v1/env/{envId}/scs 设置环境关联的SCS实例

    请求参数

    参数名称 参数类型 是否必须 说明
    scsIds List<String> 必须 与环境关联的SCS实例ID列表

    请求示例

    PUT /v1/env/baeenv-iix5bwc10hfw/scs HTTP/1.1
    HOST: baepro.bj.baidubce.com
    Authorization: {authorization}
    Content-Type: application/json; charset=utf-8
    x-bce-date: 2016-06-01T23:00:10Z
    
    {
        "scsIds": ["9280", "9381"]
    }

    返回示例

    HTTP/1.1 200 OK
    Content-Type: application/json; charset=utf-8
    x-bce-request-id: 9ebc57ed-1ff5-480f-b5b1-6847ff54f2b4

    查找关联指定SCS的BAE环境

    方法 API 说明
    GET /v1/env?scsId={scsId} 查找关联了ID为{scsId}的SCS实例的环境

    请求参数

    参数名称 参数类型 是否必须 说明
    scsId String 必须 查找的SCS实例ID

    返回参数

    参数名称 参数类型 说明
    envs List<env> 请参看获取环境信息中的"env参数列表"

    请求示例

    GET /v1/env?scsId=9280 HTTP/1.1
    HOST: baepro.bj.baidubce.com
    Authorization: {authorization}
    Content-Type: application/json; charset=utf-8
    x-bce-date: 2016-06-01T23:00:10Z

    返回示例

    HTTP/1.1 200 OK
    Content-Type: application/json; charset=utf-8
    x-bce-request-id: 9ebc57ed-1ff5-480f-b5b1-6847ff54f2b4
    
    {
        "envs": [{
            "appId": "baeapp-5atue8m3sxsv",
            "envId": "baeenv-iix5bwc10hfw",
            "envName": "released",
            "domainPrefix": "testapp",
            "domains": [{
                "domain": "testapp.duapp.com",
                "default": true,
                "status": "Active"
            }],
            "code": {
                "versionId": "1",
                "deployTime": "2016-06-01T23:00:10Z"
            },
            "autoDeploy": {
                "enable": false
            },
            "createTime": "2016-06-01T23:00:10Z",
            "instanceAmount": 2,
            "instanceParameters": {
                "cpuInCore": 1,
                "memoryInMB": 1024,
                "diskInGB": 2,
                "bandwidthInMbps": 5
            },
            "loadBalanceParameters": {
                "bandwidthInMbps": 10
            },
            "status": "Running",
            "stopped": false,
            "banned": false,
            "loadBalance": {
                "externalIp": "200.123.123.10",
                "internalIp": "10.44.123.10"  
            }
        }]
    }

    获取关联的RDS

    方法 API 说明
    GET /v1/env/{envId}/rds 获取环境关联的RDS实例

    返回参数

    参数名称 参数类型 说明
    rdsIds List<String> 与环境关联的RDS实例ID列表

    请求示例

    GET /v1/env/baeenv-iix5bwc10hfw/rds HTTP/1.1
    HOST: baepro.bj.baidubce.com
    Authorization: {authorization}
    Content-Type: application/json; charset=utf-8
    x-bce-date: 2016-06-01T23:00:10Z

    返回示例

    HTTP/1.1 200 OK
    Content-Type: application/json; charset=utf-8
    x-bce-request-id: 9ebc57ed-1ff5-480f-b5b1-6847ff54f2b4
    
    {
        "rdsIds": ["9280", "9381"]
    }

    设置关联的RDS

    方法 API 说明
    PUT /v1/env/{envId}/rds 设置环境关联的RDS实例

    请求参数

    参数名称 参数类型 是否必须 说明
    rdsIds List<String> 必须 与环境关联的RDS实例ID列表

    请求示例

    PUT /v1/env/baeenv-iix5bwc10hfw/rds HTTP/1.1
    HOST: baepro.bj.baidubce.com
    Authorization: {authorization}
    Content-Type: application/json; charset=utf-8
    x-bce-date: 2016-06-01T23:00:10Z
    
    {
        "rdsIds": ["9280", "9381"]
    }

    返回示例

    HTTP/1.1 200 OK
    Content-Type: application/json; charset=utf-8
    x-bce-request-id: 9ebc57ed-1ff5-480f-b5b1-6847ff54f2b4

    查找关联指定RDS的环境

    方法 API 说明
    GET /v1/env?rdsId={rdsId} 查找关联了ID为{rdsId}的RDS实例的环境

    请求参数

    参数名称 参数类型 是否必须 说明
    scsId String 必须 查找的RDS实例ID

    返回参数

    参数名称 参数类型 说明
    envs List<env> 请参看获取环境信息中的"env参数列表"

    请求示例

    GET /v1/env?scsId=9280 HTTP/1.1
    HOST: baepro.bj.baidubce.com
    Authorization: {authorization}
    Content-Type: application/json; charset=utf-8
    x-bce-date: 2016-06-01T23:00:10Z

    返回示例

    HTTP/1.1 200 OK
    Content-Type: application/json; charset=utf-8
    x-bce-request-id: 9ebc57ed-1ff5-480f-b5b1-6847ff54f2b4
    
    {
        "envs": [{
            "appId": "baeapp-5atue8m3sxsv",
            "envId": "baeenv-iix5bwc10hfw",
            "envName": "released",
            "domainPrefix": "testapp",
            "domains": [{
                "domain": "testapp.duapp.com",
                "default": true,
                "status": "Active"
            }],
            "code": {
                "versionId": "1",
                "deployTime": "2016-06-01T23:00:10Z"
            },
            "autoDeploy": {
                "enable": false
            },
            "createTime": "2016-06-01T23:00:10Z",
            "instanceAmount": 2,
            "instanceParameters": {
                "cpuInCore": 1,
                "memoryInMB": 1024,
                "diskInGB": 2,
                "bandwidthInMbps": 5
            },
            "loadBalanceParameters": {
                "bandwidthInMbps": 10
            },
            "status": "Running",
            "stopped": false,
            "banned": false,
            "loadBalance": {
                "externalIp": "200.123.123.10",
                "internalIp": "10.44.123.10"  
            }
        }]
    }
    一篇
    环境变量相关接口
    一篇
    端口相关接口