7 Performance and scaling

 

This chapter covers

  • Tuning Fluentd configuration to maximize resources using workers.
  • Distributing workloads with fan-in and fan-out deployment patterns.
  • Scaling with fan-out and fan-in deployment patterns
  • Implementing high availability and controlling workload distribution with roundrobin or node weighting.
  • Deploying Fluentd for microservice deployment patterns.

In the previous chapters we worked with just a single Fluentd instance, but we live in a world of distribution, virtualization, and containerization. A single server solution in the enterprise space is a rarity. The chances are that to provide a level of robustness and flexibility to demand the solution will be configured to scale. With either scaling up (adding more CPUs, memory to a server) and/or scale-out (deploy additional server instances and have workload distributed via load balancing). To provide good availability an organization will have an active server running a solution and a standby configured and being kept in sync. With the synchronization, it becomes possible to startup the standby server on short notice if the first instance fails (active-passive). We also see multiple active servers spread across multiple data centers and this is becoming very conventional as a deployment pattern.

7.1    Threading and processes, scaling with Workers

7.1.1   Seeing workers in action

7.1.2   Worker constraints

7.1.3   Controlling output plugin threads

7.1.4   Memory management optimization

7.2    Scaling and moving workloads

7.2.1   Fan-in / log aggregation & consolidation

7.2.2   Fan-out & workload distribution

7.2.3   High Availability

7.2.4   scenario High Availability comparison

7.3    Fluentd scaling in Containers vs Native and Virtual Environments

7.3.1   Kubernetes Worker Node configuration

7.3.2   Per Cluster Configuration

7.3.3   Container as virtualization

7.3.4   SideCar Pattern

7.3.5   Options Comparison

7.4    Securing traffic between Fluentd nodes

7.4.1   TLS configuration

7.4.2   TLS not just for encryption

7.4.3   Certificate & Private Key storage 

7.4.4   Security is more than certificates

7.5    Credentials management

7.5.1   Simple credentials use case

7.5.2   Scenario applying certification

7.6    Summary