Configuring functional platforms (OpenFaaS/Knative) for serverless

Peak load breaks the usual function loop: some calls wait for minutes, others fail as traffic rises. We configure OpenFaaS turnkey — from analyzing the load profile to handing operational runbooks over to your team. The loop absorbs peaks while response times stay predictable.

Our competencies:

Frequently Asked Questions

Latest works

  • Development of a web application for FEEDME
    Development of a web application for FEEDME
    1365
  • Development of an online store for the company FURNORO
    Development of an online store for the company FURNORO
    1330
  • B2B Advance company logo design
    B2B Advance company logo design
    776
  • Development of a web application for Enviok
    Development of a web application for Enviok
    1077
  • AIDER company logo development
    AIDER company logo development
    1022
  • CRM development for Chasseurs
    CRM development for Chasseurs
    1113

Configuring OpenFaaS: where the serverless environment breaks

Failure of a serverless environment rarely looks like an outage—more often it is quiet degradation. First, the depth of the invocation queue grows: event sources keep sending them, the handler cannot keep up, and retries on error multiply the load instead of smoothing it.

After a few minutes, the external integration starts responding with a timeout, and events are already lost irretrievably—the acknowledgment was sent before actual processing, and no one can replay them.

The second typical failure is uncontrolled replication of instances. The function platform scales with load, and if no upper bound is set, a spike in requests spins up hundreds of instances that simultaneously finish off the database and third-party APIs.

The external service cuts off access due to a rate limit, instances go into cold start, response time grows, and dealing with the aftermath takes hours of manual work.

Configuring OpenFaaS starts not with installation but with boundaries: a limit on concurrent instances, a queue threshold, a processing timeout, a retry count, and a discard rule.

We separately check idempotency—redelivery of the same event must not create a second record or a second payment. Without these limits, the function platform works exactly until the first load peak.

Below we break down how this is addressed: which metrics we use to catch degradation before users do, and what exactly is included in configuring the environment.

The effect of a configured environment: response, scale, fault isolation

In a configured environment on OpenFaaS, the first result is visible on the function response time graph.

A prepared instance pool and a warm-instance retention threshold remove cold start from the user scenario: the first request after a pause is served in fractions of a second instead of waiting for the environment to build and start.

The second indicator is scaling predictability. We set rules based on the number of concurrent invocations and queue length: as load grows, function instances are added; as it falls, excess ones are removed based on an idle threshold.

Capacity grows along with the flow, not after response has already degraded, so a peak does not turn into a series of manual interventions.

The third is fault isolation. Each function lives in its own environment with memory and execution time limits, so a leak or hang inside one does not affect neighboring ones.

The failed instance is removed from rotation, the request goes to a healthy one, and retries and queue processing do not pile up into an avalanche across the entire platform.

As a class, failures that previously required an on-call engineer during a peak disappear: memory overflow in a long-lived service, cascading failure of related services, response drop during a sharp spike.

What remains is verifiable behavior—function response time holds at peak, scaling is reproducible, and a failure is localized to one function and does not go beyond its boundaries.

Configuring OpenFaaS: comparing deployment modes

The deployment mode determines how much time the team spends on maintenance and how quickly a new function reaches production. Below are four schemes that teams actually choose between on a cluster, with their strengths and honest limitations.

We do not commit to a single option: the platform is selected to match the load profile and team maturity, and the transition between schemes is done gradually—one function at a time, without stopping the product.

Option When it fits Limitations
Ready-made function platform (OpenFaaS, Knative) Short mass tasks, load spikes, need scale to zero The platform dictates the build and run model, adds cold start, requires a mature team for debugging
Event-driven add-on over a cluster There is already a cluster and event bus, the function is triggered by a message or schedule Tracing the chain becomes more complex, and message order and retries have to be handled at the application level
Manual container scheme Non-standard dependencies, custom network policies, full control over the image Scaling, liveness checks, secret rotation, and updates are manual; the share of routine work grows
Virtual machines Heavy dependencies, isolation requirements, migration of existing systems No rapid growth for a spike, downtime during updates, low resource utilization

Practice shows: when speed of launching new tasks is needed, a ready-made platform wins.

We configure it so that the development team describes only the function logic and does not touch the infrastructure, while the event layer and container services coexist peacefully in the same cluster.

Workflow: from load audit to environment handover

Implementing a function platform starts not with installation but with an audit: average load says nothing about how the environment behaves at peak.

The mistake is to choose a configuration for average consumption: during quiet hours everything holds, but during a spike the queue grows and invocations drop off by timeout. Below is the workflow, where each step relies on the figures from the previous one.

  1. Load audit. We collect the invocation profile: frequency, duration, peaks, and the share of background and rare tasks. We note what we are moving to functions and what is cheaper to leave as containers with constant consumption.
  2. Routing scheme. We fix entry points, rules by paths and headers, timeouts, and request size limits. We determine which invocations are synchronous and which go to the queue.
  3. Environment configuration. We plan node pools, resource limits, and autoscaling boundaries at peak and at idle. We deploy the platform on OpenFaaS, connect the image registry, builds from the repository, secrets, and access separation.
  4. Fault tolerance testing. We run a profile several times higher than the calculated one: queue growth, waiting time, behavior during node failure, and the environment's ability to recover on its own. We close bottlenecks before putting it into production.
  5. Observability. Metrics, logs, and alerts based on signs of degradation. On-call regulations: what we consider normal and what requires intervention.
  6. Handover and training. Documentation on configuration and schemes, access, walkthrough of typical operations: rolling out a new function, rollback, changing limits. We train the team so that changes can be made without us.

Configurations, routing schemes, and operating regulations

After implementation, the customer's team is left not with a set of disparate scripts but with a working kit: function configurations, schemes of connections between services, access rules, and operating regulations.

Using these materials, the platform can be updated, expanded, and handed over to new engineers without contacting us.

  • Function configurations — descriptions of each function with memory and CPU limits, instance lifetime, autoscaling parameters, and cold start thresholds, recorded in the version control system.
  • Integration schemes — a map of synchronous invocations, event triggers, queues, and external sources, including data flow direction and failure points.
  • Access policies — roles and scopes for teams, environment separation, rules for issuing and rotating credentials, and procedures for working with sensitive values.
  • Operating regulations — platform update frequency, maintenance windows, rollback procedure to the previous version, and criteria that trigger a rollback.
  • Function release procedure — change review, test environment, gradual rollout of the new version to a portion of requests, and conditions for full switchover.
  • Observability — a set of metrics, logs, and alerts with trigger thresholds tied to specific functions rather than the platform as a whole.
  • On-call shift instructions — typical failures, diagnostic procedures, and actions for each, including checking queues and stuck instances.
  • Check log — results of load and recovery runs with dates, scenarios, and recorded discrepancies.

Each document is tied to the actual configuration in the repository, so a discrepancy between the description and the running platform is immediately visible. The handover comes with a walkthrough: we show what is where, how to make changes, and how to verify the result.

Case study: function environment for an online store's peak load

Peak load came in waves: the start of a seasonal campaign and night sales tripled the flow of requests within minutes.

The monolith handled them through a shared worker pool, which hit its ceiling, and some customers got an error at the last step of checkout—the cart was lost after payment.

We scaled manually, but the cycle took tens of minutes: the peak had time to end before new servers were brought up. We break down the environment that removed this dependency.

What we changed

Background and short scenarios—promo code validation, delivery calculation, notification sending, preview generation—were moved to functions on OpenFaaS.

Autoscaling was configured based on the number of concurrent invocations rather than node load: the environment adds instances in seconds and just as quickly returns them.

State was removed from functions into shared storage so that instances remained interchangeable, and each function was given a time and memory limit—one slow operation no longer holds up the queue. Containers are warmed up in advance, so cold start does not land in the first seconds of a peak.

The result

The share of successful invocations grew from 87% to 99.9% at peak, and response time decreased from 4–6 s to 0.3–0.6 s. A single node failure is now fixed by rescheduling: recovery takes 20–40 s instead of 25–30 minutes of manual work.

The peak passes without on-call intervention, and the function environment runs on fewer permanently occupied machines.

What to do if a similar function environment is already deployed

First, an inventory: which functions are actually invoked, how often, and what triggers them—a request, an event from a queue, or a schedule. In most environments, some deployed services receive no traffic for months; we migrate them last or decommission them. The output is a dependency map and a migration order.

The key element of the transition is a single entry point in front of the old and new environments. Routing is described by rules: specific paths or a share of requests go to the new site, and the previous scheme serves the rest.

Both configurations—the running OpenFaaS environment and the new one—live in parallel, and switching comes down to editing a rule rather than rewriting calls for clients and internal consumers.

Then we migrate one function at a time, starting with those that do not store state and do not hold long-lived connections—they are easier to compare with the baseline.

The function takes secrets and environment variables from the same storage, the build comes from the same repository, so divergence between environments remains manageable.

Rollback is built into the scheme itself: the routing rule returns to the previous address in seconds, without downtime or dropped connections.

We do not decommission the previous environment until the new version has run under production load and statistics on errors and latency for both schemes have accumulated.

We aggregate logs and metrics from both environments in one place to compare identical indicators—this is the readiness criterion for the next step. This way, the transition becomes a series of reversible changes rather than a one-time replacement.

Technical questions: cold start, limits, and rollbacks

When configuring OpenFaaS, the customer's technical team asks the same questions: how the environment will behave at peak, what functions are limited by, whether rollback is possible, and what will remain in the logs after a failure. Below are short answers for each.

Cold start: what happens to response time at peak?

The first request brings up a container—this is the cold start. We keep a minimum pool of warmed instances, and set the scaling threshold below the calculated peak so the platform can keep up in advance. Functions with rare invocations are moved to always-on if their latency is critical.

How are function resources limited?

For each function, we set a CPU and memory ceiling and a hard timeout: one heavy function does not take resources from its neighbors. Hitting the limit is visible in the metrics—it is a signal of a bottleneck, not degradation of the entire environment.

Can a version be rolled back without downtime?

Each release is a separate immutable version, and traffic is switched between them. Rollback is returning the tag to the previous version, meaning seconds. We store images until stability is confirmed, so you can go back even after a few days.

What happens during an incident and how is it analyzed?

Logs, metrics, and traces are tied to the function version—you can see which release caused the failure. The analysis follows the chronology: invocation spike, errors, response time, switchover moment. The result is a record with the cause and a fix so that the same class of failures does not recur.

Let's discuss the task: what to clarify before work starts

To come back with a realistic estimate rather than a "from and to" range, we need inputs on the environment and load.

It is pointless to evaluate a platform in isolation from what will run on it: the same environment is assembled differently for rare background tasks and for a stream of events from hundreds of devices.

  • where the services currently live: an own cluster, cloud, or hybrid scheme, and who is responsible for the base layer;
  • which tasks are moving to the platform: event processing, queues, request-driven invocations, scheduled runs;
  • load profile: peak request frequency, share of long-running operations, requirements for new instance startup time;
  • access and isolation rules: network policies, secrets handling, separation of permissions between teams;
  • how update releases are organized now and what must be preserved: image registry, environments, rollback to the previous version;
  • log and metric collection: where we write, what we consider a sign of degradation, who receives alerts;
  • acceptance criteria and the customer-side contact who confirms these criteria.

Then the work proceeds in steps: we analyze your scheme and current limitations, agree on the target OpenFaaS configuration, provide an estimate by scope of work, then a plan with stages and timelines. The intermediate result of each stage is a working environment, not a report on work done.

Describe the task in free form: what you are running now, what is getting in the way, and what result you consider done. We will come back with an estimate and a work plan.