What is Function as a Service (FaaS)?
Section titled “What is Function as a Service (FaaS)?”Function as a Service (FaaS) runs your code without servers for you to manage. E2E’s FaaS platform is called Functions. You write a function, E2E builds and runs it, and you call it over its own public HTTPS URL. See Functions.
What can I build with Functions?
Section titled “What can I build with Functions?”Functions suits jobs that start from an HTTP request and answer quickly: APIs and webhooks, backends for a frontend, microservices, automation, and data processing. See What you can build.
Which regions is Functions available in?
Section titled “Which regions is Functions available in?”Functions is available only in Delhi.
What does activating Functions do?
Section titled “What does activating Functions do?”Activation sets up Functions for your account. You activate once, before you create your first function. Activation reserves a dedicated outbound IP for the account. From then on, the CPU monthly minimum applies each month. A prepaid account pays the minimum from its prepaid balance when it activates. See Activate Functions.
What runtimes are supported?
Section titled “What runtimes are supported?”Functions run Python, Node.js, Go, C#, or PHP, or your own container image. For every version, see Runtimes and hardware.
Can I run machine learning models on Functions?
Section titled “Can I run machine learning models on Functions?”Yes, on CPU hardware. Add your libraries to a Python runtime’s requirements.txt, or package the
model in a Custom Container Image. If only part of an application should run as a function,
deploy that part alone, such as the inference step, and keep the rest elsewhere. To serve a model
on a GPU, use TIR. See
What you can build.
What is a function handler?
Section titled “What is a function handler?”The handler is the entry point of your function code. It receives the request as an event, runs your logic, and returns a response. In the FastAPI, Flask, and Express runtimes there is no handler. You write an ordinary app with its own routes. See Requests and responses.
How do I deploy a function?
Section titled “How do I deploy a function?”Create a function in one of three ways: write code in the editor from a runtime template, upload a ZIP of your code, or deploy a custom container image. See Create a function, Upload code as a ZIP, and Deploy a custom container image.
What are dedicated replicas?
Section titled “What are dedicated replicas?”Dedicated replicas are instances of a function kept always running to avoid cold starts. A CPU or container function can have 1 to 5. See Keep a function ready with dedicated replicas.
How do I avoid cold starts?
Section titled “How do I avoid cold starts?”For a CPU or container function, turn on Enable Dedicated Replica and set Minimum Replica from 1 to 5. That many instances stay running. See Keep a function ready with dedicated replicas.
What happens when a function receives a large number of requests?
Section titled “What happens when a function receives a large number of requests?”The function scales automatically. More instances start under load, and fewer run when demand drops. See Functions.
What is a function’s URL?
Section titled “What is a function’s URL?”Each function gets its own public HTTPS URL. Copy it from the function’s Info tab. See Call a function.
What outbound IP address do functions use?
Section titled “What outbound IP address do functions use?”All the functions in an account use a dedicated outbound IP reserved when Functions is activated. It is shown as Outbound IP on the Info tab of any function. Every function calls external services from that one address. An external system can allow that address in its firewall, for API integrations or IP-based access control. See Activate Functions.
How can I update my function code after deployment?
Section titled “How can I update my function code after deployment?”Open the function, edit the code, requirements, or environment variables, and click Save. Saving rebuilds and redeploys the function. See Edit a function.
What configuration options are available for functions?
Section titled “What configuration options are available for functions?”You choose memory, timeout, environment variables, and, for CPU and container functions, dedicated replicas. See Create a function.
What are environment variables in functions?
Section titled “What are environment variables in functions?”Environment variables hold configuration, such as database URLs, service endpoints, and application settings, separately from your code. You change a value without changing the code. See Use environment variables.
What does the function execution timeout mean?
Section titled “What does the function execution timeout mean?”Timeout (sec) is the seconds a function can run before it is stopped, from 1 to 600. The default is 15 seconds. See Create a function.
What are the limits of a function?
Section titled “What are the limits of a function?”- Name: up to 40 characters.
- Memory: 128, 256, 512, or 1024 MB. Each size comes with a share of a CPU.
- Timeout (sec): 1 to 600 seconds. The default is 15 seconds.
- ZIP upload: up to 50 MB compressed and 200 MB extracted.
- Ephemeral Storage: 5 GB.
- Dedicated replicas: 1 to 5, for CPU and container functions.
- Request body, in the Python and Node.js HTTP runtimes: 10 MB by default. The init function can raise it up to 1000 MB.
See Create a function and Requests and responses.
How can I monitor function activity?
Section titled “How can I monitor function activity?”The Logs tab shows a function’s runtime logs, and the Monitoring tab shows Memory Usage and Invocation Count charts. See View logs and monitoring.
What are the possible states of a function?
Section titled “What are the possible states of a function?”A function’s Status is one of Creating, Deploying, Running, or Failed. See Create a function.
Why might a function fail during deployment?
Section titled “Why might a function fail during deployment?”A function reads Failed when its build does not succeed. Check that the requirements or package file lists every dependency your code needs, with the right versions. Check that you set the environment variables your code needs, and that the code reads them by the keys you set.
A function refused at Create because its ZIP has no root directory also appears as Failed.
A failed function shows a Build Logs tab on its page. Its Logs tab combines runtime and build logs. See Troubleshooting Functions.
Can I deploy functions using my own container image?
Section titled “Can I deploy functions using my own container image?”Yes. Choose Custom Container Image, and in the Dockerfile tab set the BASE_IMAGE argument to
your public image. A private image, such as one in E2E Container Registry, cannot be used. The
image must be built for linux/amd64 and run as a non-root user. By default the container must
listen on port 8080. See
Deploy a custom container image.
Can functions interact with other cloud services?
Section titled “Can functions interact with other cloud services?”Yes. Functions can connect to databases, object storage, messaging, APIs, and other cloud services through the account’s dedicated outbound IP. See Activate Functions.
How is Functions billed?
Section titled “How is Functions billed?”Functions is billed on the memory your functions use over time, counted in GB-seconds. The CPU monthly minimum includes 4,50,000 GB-seconds of CPU usage. For the rates, see E2E’s pricing page. For how the bill is worked out, see Billing.
Why am I charged for Functions even if I only created and deleted functions?
Section titled “Why am I charged for Functions even if I only created and deleted functions?”The CPU monthly minimum applies for each month in which Functions is active, however little you use. A prepaid account pays it from its prepaid balance when it activates. For a prepaid account, each activation charges the minimum again, even in the same month. The minimum stays on the bill, and is not refunded, if you deactivate later that month. See Billing.
To stop the minimum for later months, delete every function and deactivate Functions. See Deactivate Functions.
Why does my function say it does not adhere to the format?
Section titled “Why does my function say it does not adhere to the format?”You see “Your function code does not adhere to the E2E Function format as suggested, please review your code.” It appears when you create a function whose required files are missing or misnamed. It also appears for a ZIP with no root directory. See Troubleshooting Functions.
What happens if my code is larger than 50 MB?
Section titled “What happens if my code is larger than 50 MB?”A ZIP you upload can be up to 50 MB compressed and 200 MB extracted. A larger ZIP gets “The uploaded ZIP file is too large. Maximum allowed size is 50MB.” See The uploaded ZIP file is too large.
Code you write in the editor is packed into a ZIP when you click Create or Save. Code too large for a 50 MB ZIP gets “Generated ZIP exceeds the 50MB limit.” The function is then not created or saved. See Generated ZIP exceeds the 50MB limit.
How do I delete a function or deactivate Functions?
Section titled “How do I delete a function or deactivate Functions?”Deleting a function removes its running service and its stored code for good. Delete a function with the trash can icon under Actions in the Functions list.
To deactivate Functions, first delete every function. Deactivating releases the account’s outbound IP. If you activate again, you can get a different IP. See Delete a function and Deactivate Functions.