You need to enable JavaScript to run this app.
Volcano Engine Function as a Service

Volcano Engine Function as a Service

Copy page
Download PDF
Functions
Testing functions
Copy page
Download PDF
Testing functions
After a function is released, you can initiate a function test in the console. veFaaS will simulate a specified trigger to send a request to your online function and display the test results to verify whether the behavior of the function meets your expectations.​
Background information​
veFaaS supports both synchronous invocation and asynchronous tasks. If the asynchronous task feature is not enabled, the synchronous invocation method is used by default.​
Prerequisites​
A function has been released. For specific operations, see Releasing functions.​
Limits​
  • You can perform an online test only on released function revisions. To test the updated function code, you need to release the updated code first.​
  • The trigger test request must be in JSON format.​
  • When a canary version exists, test requests are randomly routed to the new and old function versions based on the traffic percentage.​
  • For synchronous invocation, online testing cannot be performed on functions whose execution time exceeds 30 seconds. The system will return an execution timeout error.​
tip​
veFaaS supports both synchronous invocation and asynchronous tasks. For functions for which the asynchronous task feature is not enabled, the synchronous invocation method is used by default.​
  • In test requests for APIG triggers, the method must be in all uppercase letters.​
Procedure​
  1. Log in to the veFaaS console.​
  1. In the top navigation bar, select the target region.​
  1. In the function list, find the function to be tested and click its name.​
  1. On the function details page, click Test in the upper-right corner.​
  1. In the Function test panel, select the type of trigger for testing.​
  1. (Optional) Modify the default test request as needed. The request after modification must be in the JSON format.​
tip​
  • Reset: Reset the test request to the default test request.​
  • Format: Format and arrange multiple JSON data entries in the same line.​
  1. Click Test to execute the function test.​
Operation result​
  • Function test succeeds​
  • For a function with asynchronous task disabled, synchronous invocation is used by default. The console displays an execution summary, including CPU consumption during the request, function memory consumption, and function execution duration, and the response result of the function.​
  • For a function with asynchronous tasks enabled, the console will return the RequestID. Click View details to view the execution status of the current task in the asynchronous task list.​
  • Function test fails​
  • The console will display execution logs to help you troubleshoot.​
​
Last updated: 2026.08.19 14:06:05