检测到您已登录华为云国际站账号,为了您更好的体验,建议您访问国际站服务网站 https://www.huaweicloud.com/intl/zh-cn
不再显示此消息
描述 error_code String 错误码 error_msg String 错误信息 请求示例 当前租户函数别名列表。 GET https://{Endpoint}/v2/{project_id}/fgs/functions/{function_urn}/aliases 响应示例
错误码 error_msg String 错误信息 请求示例 创建名为event-xx,内容为{"k":"v"}的测试事件。 POST https://{Endpoint}/v2/{project_id}/fgs/functions/{function_urn}/events {
error_code String 错误码 error_msg String 错误信息 请求示例 查询指定函数的版本别名信息。 GET https://{Endpoint}/v2/{project_id}/fgs/functions/{function_urn}/aliases/{alias_name}
href String 超链接地址 display_name String 云服务名称 表5 RepoInfo 参数 参数类型 描述 https_url String http地址 web_url String 存储库链接 repo_status String 存储库状态 error_msg
描述 error_code String 错误码 error_msg String 错误信息 请求示例 查询租户预留实例列表。 GET https://{Endpoint}/v2/{project_id}/fgs/functions/reservedinstances 响应示例 状态码:
请求示例 创建键值对分别为"testKey1:testValue1"、"testKey2:testValue2"的资源标签。 POST https://{Endpoint}/v2/{project_id}/{resource_type}/{resource_id}/tags/create
"execution succeed: Return to access service information through http/https,", "warning" : "1. configure the serveraddress environment variables
error_code String 错误码 error_msg String 错误信息 请求示例 将函数预留实例数量更新为3。 PUT https://{Endpoint}/v2/{project_id}/fgs/functions/{function_urn}/reservedinstances
参数类型 描述 error_code String 错误码 error_msg String 错误信息 请求示例 查询资源实例。 POST https://{Endpoint}/v2/{project_id}/{resource_type}/resource-instances/{action}
"execution succeed: Return to access service information through http/https,", "warning" : "1. configure the serveraddress environment variables
"6578de50-9a18-48fa-b84e-b2d36636e433", "owner" : "public", "link" : "https://{obs_endpoint}/functionstage-examples/fg_test_pandas_1.1.3.zip",
描述 error_code String 错误码 error_msg String 错误信息 请求示例 获取函数预留实例配置列表 GET https://{Endpoint}/v2/{project_id}/fgs/functions/reservedinstanceconfigs 响应示例
上面的例子是APIG触发器的事件类型,如果是其他触发器类型需要修改main函数的内容,例如cts触发器修改为runtime.Register(CtsTest),目前只支持注册一个入口。 当函数的事件源是APIG时,相关约束条件请参考Base64解码和返回结构体的说明。 编译和打包 函数代码编译完成后,按照如下方式编译和打包。
e.printStackTrace(); System.out.println(e.getHttpStatusCode()); System.out.println(e.getRequestId());
json import requests def handler (event, context): domainId = "https://{Endpoint}" url = "/v2/{project_id}/fgs/functions/{func-urn}/reservedinstances"
e.printStackTrace(); System.out.println(e.getHttpStatusCode()); System.out.println(e.getRequestId());
e.printStackTrace(); System.out.println(e.getHttpStatusCode()); System.out.println(e.getRequestId());
描述 error_code String 错误码 error_msg String 错误信息 请求示例 获取指定函数代码信息。 GET https://{Endpoint}/v2/{project_id}/fgs/functions/{function_urn}/code 响应示例
e.printStackTrace(); System.out.println(e.getHttpStatusCode()); System.out.println(e.getRequestId());
e.printStackTrace(); System.out.println(e.getHttpStatusCode()); System.out.println(e.getRequestId());