检测到您已登录华为云国际站账号,为了您更好的体验,建议您访问国际站服务网站 https://www.huaweicloud.com/intl/zh-cn
不再显示此消息
添加事件源 函数创建以后,可以为函数添加事件源,本例通过配置DIS测试事件,模拟DIS输入数据,步骤如下。 用户进入DISDemo函数详情页,在“代码”页签下,选择配置测试事件,如图1所示,弹出“配置测试事件页”。 图1 配置测试事件 在“配置测试事件页”,输入配置信息,如图2所示。
构建函数程序 编辑函数程序 打开创建的函数iotdemo,复制以下坐标转换代码,仅供测试不建议用于生产用途,用户也可以根据自己的需要修改。 # -*- coding:utf-8 -*- import json import math from math import pi def
trigger_metadata_list Array of TriggerMetadataList objects 触发信息列表 temp_detail TempDetail object user_data String 用户数据 encrypted_user_data String 加密用户数据
status String 异步调用状态,支持5种状态 WAIT: 等待 RUNNING: 执行中 SUCCESS: 执行成功 FAIL: 执行失败 DISCARD: 请求丢弃 枚举值: WAIT RUNNING SUCCESS FAIL DISCARD error_message String
准备 案例实现的功能是将DIS数据格式转换,存储到表格存储服务中,所以需要先在表格存储服务创建集群,在创建集群时需要使用虚拟私有云。 创建函数之前,需要创建委托,给FunctionGraph函数赋权,确保FunctionGraph函数能够访问到DIS和CloudTable资源。 创建虚拟私有云
准备 创建IoTDA 转发规则前,需要先创建IoTDA实例,在正常的使用中还需要创建产品,设备。在本案例中仅进行测试,只需要先创建IoTDA实例。 创建IoTDA IoT实例 登录IoTDA控制台,左侧导航栏选择“IoTDA实例”,进入选择界面。 在“IoTDA实例”界面右侧,单击“购买实例
build(); ShowLtsLogDetailsRequest request = new ShowLtsLogDetailsRequest(); try { ShowLtsLogDetailsResponse response = client
作。 步骤二:创建APIG专享版触发器 购买并创建函数的APIG专享版触发器。 步骤三:配置客户端开始AI对话 下载并配置第三方客户端,部署DeepSeek-R1蒸馏模型开始AI对话,可选择以下任一客户端进行部署: 方式一:ChatBox(支持Windows、macOS、Linux、安卓、IOS、Web)(推荐使用)
public static void main(String[] args) { // The AK and SK used for authentication are hard-coded or stored in plaintext, which has great
public static void main(String[] args) { // The AK and SK used for authentication are hard-coded or stored in plaintext, which has great
public static void main(String[] args) { // The AK and SK used for authentication are hard-coded or stored in plaintext, which has great
public static void main(String[] args) { // The AK and SK used for authentication are hard-coded or stored in plaintext, which has great
serverless.yml # Contains 4 functions that do Users CRUD operations and the Users database posts/ serverless.yml # Contains 4 functions that
public static void main(String[] args) { // The AK and SK used for authentication are hard-coded or stored in plaintext, which has great
Result 参数 参数类型 描述 resource_id String 资源ID resource_detail ListEnterpriseResourceDetail object tags Array of KvItem objects 标签列表 sys_tags Array
最大长度:64 枚举值: success fail timeout output Object 工作流的执行结果,JSON格式,仅在status为success时有值 errors Array of SyncExecutionNodeErrorDetail objects 流程执行错误信息,仅在status为fail时有值
服务韧性 华为云数据中心按规则部署在全球各地,所有数据中心都处于正常运营状态,无一闲置。数据中心互为灾备中心,如一地出现故障,系统在满足合规政策前提下自动将客户应用和数据转离受影响区域,保证业务的连续性。为了减少由硬件故障、自然灾害或其他灾难带来的服务中断,华为云为所有数据中心提供灾难恢复计划。
public static void main(String[] args) { // The AK and SK used for authentication are hard-coded or stored in plaintext, which has great
public static void main(String[] args) { // The AK and SK used for authentication are hard-coded or stored in plaintext, which has great
None 操作指导 函数工作流 使用AI绘画Stable-Diffusion 02:33 使用AI绘画Stable-Diffusion 函数工作流 介绍如何使用空白模板创建函数 03:15 使用空白模板创建函数 函数工作流 介绍如何使用APIG触发器 02:10 使用APIG触发器