# Apache OpenWhisk — Open Source Serverless Cloud Platform > Apache OpenWhisk is a serverless functions platform that lets you deploy event-driven code in any language without managing servers, with support for composable action sequences and rich trigger integrations. ## Install Save as a script file and run: # Apache OpenWhisk — Open Source Serverless Cloud Platform ## Quick Use ```bash # Install the wsk CLI # Create and invoke a function wsk action create hello hello.js wsk action invoke hello --result --param name World # Output: {"greeting": "Hello, World!"} ``` ## Introduction Apache OpenWhisk is an open-source serverless platform that executes functions in response to events at any scale. Unlike proprietary FaaS offerings, OpenWhisk runs on your own infrastructure and supports any language runtime via Docker containers. ## What OpenWhisk Does - Executes stateless functions (actions) in response to HTTP requests, message queues, or custom triggers - Supports Node.js, Python, Java, Go, Swift, PHP, Ruby, and custom Docker runtimes - Chains multiple actions into sequences and compositions for complex workflows - Provides a rules engine that binds triggers to actions declaratively - Scales from zero to thousands of concurrent invocations automatically ## Architecture Overview OpenWhisk consists of an Nginx entry point, a Scala-based controller that handles API requests and scheduling, Apache Kafka for internal messaging, and an invoker pool that spins up Docker containers to execute actions. CouchDB stores action code, activation records, and authentication data. The controller distributes work across invokers via Kafka, and containers are reused (warm starts) when possible. ## Self-Hosting & Configuration - Deploy on Kubernetes via the official Helm charts or on bare metal with Ansible - Requires Kafka, CouchDB, and a container runtime (Docker or containerd) - Configure concurrency limits, memory per action, and timeout thresholds - Set up API keys and namespaces for multi-tenant isolation - Integrate external event sources via feed providers (Kafka, GitHub, Cron, and more) ## Key Features - Truly polyglot — any language or binary that runs in Docker can be an action - Composable action sequences and conductor-style workflows - Fine-grained per-action resource limits (memory, timeout, concurrency) - Rich activation logging and tracing for debugging - Apache-licensed with an active community and IBM Cloud Functions backing ## Comparison with Similar Tools - **AWS Lambda** — managed and tightly integrated with AWS; OpenWhisk is self-hosted and cloud-agnostic - **Knative** — Kubernetes-native serverless that scales pods; OpenWhisk uses its own container-per-invocation model - **OpenFaaS** — simpler function-as-a-service on Kubernetes; OpenWhisk has richer composition and trigger semantics - **Fission** — Kubernetes-native FaaS with fast cold starts; OpenWhisk supports more languages and complex workflows ## FAQ **Q: Can I run OpenWhisk without Kubernetes?** A: Yes. OpenWhisk supports standalone deployment with Docker Compose or Ansible on bare-metal or VMs. **Q: How does cold start latency compare to cloud FaaS?** A: Cold starts depend on container pull time and runtime init. Warm containers are reused to minimize latency for frequently called actions. **Q: Does OpenWhisk support long-running functions?** A: Actions have a configurable timeout (default 60 seconds, max 5 minutes). For longer workflows, chain actions into sequences. **Q: Is there a managed OpenWhisk offering?** A: IBM Cloud Functions is built on OpenWhisk and provides a managed experience. ## Sources - https://github.com/apache/openwhisk - https://openwhisk.apache.org/documentation.html --- Source: https://tokrepo.com/en/workflows/asset-1bec0a86 Author: Script Depot