Skip to main content
Version: 7.0

Overview

Introduction

Passwork supports a fault-tolerant architecture that provides high availability and keeps the service running even if individual infrastructure components fail.

Fault tolerance allows you to:

  • Ensure continuous service for users
  • Distribute load across multiple servers
  • Scale the system to handle more users and higher throughput
  • Reduce operational risks by keeping behavior predictable during failover and incidents
warning

Fault tolerance in Passwork is available only with the advanced license.

Principles of fault tolerance

A fault-tolerant Passwork deployment is built on two core principles:

  1. Redundant application servers — several application servers run in parallel, so the service stays available even if one or more nodes fail.
  2. Database replication — a MongoDB replica set keeps data synchronized across nodes and elects a new Primary automatically.

Minimum requirements:

  • At least 2 application servers behind a load balancer
  • At least 3 MongoDB nodes in a replica set
  • Independent infrastructure for database nodes (separate racks/data centers when possible)
  • Configured health checks and connection monitoring

General architecture of a fault-tolerant system:

Fault tolerance scheme

Scalability

Passwork supports two scaling models to increase performance and handle more users.

Horizontal scaling

Horizontal scaling (scale-out) means adding new servers to the pool to spread the load.

Advantages:

  • Higher throughput by distributing requests across servers
  • High availability — if one server fails, others keep working
  • Gradual, incremental expansion

Use cases:

  • Adding new Passwork application servers
  • Expanding the MongoDB replica set with additional secondary nodes

Vertical scaling

Vertical scaling (scale-up) means increasing resources (RAM, CPU, storage) on an existing server.

Advantages:

  • Quick performance boost without changing the architecture
  • Simple to implement — no balancing or synchronization required
  • Suitable for small and mid-size loads

Limitations:

  • Hardware limits (max RAM/CPU on a single host)
  • Single point of failure — if the server goes down, the system is unavailable
  • A powerful single server can cost more than several smaller ones

Recommendations

  • For fault-tolerant deployments, prefer horizontal scaling
  • Vertical scaling fits early-stage setups or environments without strict HA requirements
  • A combined approach also works: scale servers up when needed and scale out for availability

Components of the fault-tolerant architecture

A fault-tolerant Passwork deployment consists of two main components.

1. Multiple application servers

Using several Passwork application servers behind a load balancer provides:

  • Automatic traffic redistribution if a server fails
  • Even load distribution across healthy servers
  • Horizontal scalability

Learn more about architecture, load balancing, and health checks in application servers.

2. Database replication

Using a MongoDB replica set provides:

  • Automatic elections and Primary replacement when the current Primary fails
  • Data synchronization between nodes
  • High data availability

More details are in database.

Benefits of a fault-tolerant architecture

High availability

The system keeps running even when individual components fail:

  • If an application server goes down, the load balancer routes traffic to the remaining servers
  • If the Primary database node fails, the replica set elects a new Primary, and application servers start using it

Scalability

A fault-tolerant architecture makes it easy to scale:

  • Horizontal scaling — add application servers and MongoDB nodes
  • Vertical scaling — add resources to existing servers

Performance

Distributing load across multiple servers allows you to:

  • Serve more concurrent requests
  • Reduce pressure on each server
  • Improve response times