Overview
This document describes how to create, edit, and delete an edge function, and how to configure the rules that trigger the function.
Creating and Deploying a Function
1. Log in to the EdgeOne console and choose Edge function > Function Management on the left sidebar. 2. On the Edge function page, click Create function.
3. On the Create edge function page, configure the parameters and click Create and deploy.
Parameters: Function: (Required) It can contain only 2-30 letters, digits, and hyphens and must start with a letter and end with a digit or letter.
Description: (Optional) It can contain up to 60 characters.
4. If you see the following pop-up dialog box, the deployment is successful.
Configuring a Triggering Rule
1. After the function is deployed successfully, click Add triggering rule.
2. On the Add triggering rule page, specify the matching type, operator, and value as needed.
Editing the Function
1. If the deployed function does not meet your expectations, go to the Edge function page, find the function name and then click it. Enter the function information page.
2. Modify the code and click Save and deploy. If you have configured a triggering rule for the function, a note will be displayed as follows:
Deleting the Function
1. If you want to delete the function, go to the Edge function page, find the function, and then click Delete in the Operation column.
2. In the pop-up dialog box, click OK.
Note:
Once deleted, the function cannot be restored. The triggering rules of the function will also be deleted.
Was this page helpful?