You are viewing a free preview of this lesson.
Subscribe to unlock all 10 lessons in this course and every other course on LearningBro.
OCI Functions is a serverless compute platform that lets you run code without managing infrastructure. Built on the open-source Fn Project, OCI Functions provides a standards-based, event-driven compute service.
OCI Functions lets you:
OCI Functions is based on the Fn Project, an open-source, container-native serverless platform.
graph TD
T["Trigger (HTTP, Event, Schedule)"] --> F["OCI Functions: Container (Your Code)"]
F --> R["Response / Output"]
| Runtime | Versions |
|---|---|
| Java | 8, 11, 17 |
| Python | 3.8, 3.9, 3.11 |
| Node.js | 14, 18 |
| Go | 1.19+ |
| Ruby | 2.7 |
| C# | .NET 6 |
| Custom | Any language via a Docker image |
Since functions are packaged as containers, you can use any language with a custom Docker image.
An application is a logical grouping of functions:
A function is a single unit of code within an application:
Call a function using the OCI CLI or SDK:
oci fn function invoke --function-id <ocid> --body '{"name": "world"}'
Expose functions as HTTP endpoints using OCI API Gateway:
graph LR
G1["GET /api/users"] --> GW1["OCI API Gateway"]
GW1 --> Fn1["OCI Function (get-users)"]
P1["POST /api/orders"] --> GW2["OCI API Gateway"]
GW2 --> Fn2["OCI Function (create-order)"]
Trigger functions in response to OCI events:
Subscribe to continue reading
Get full access to this lesson and all 10 lessons in this course.