Download Latest Version v3.2.0 source code.tar.gz (20.2 MB)
Email in envelope

Get an email when there's a new version of ergo

Home / v1.999.320
Name Modified Size InfoDownloads / Week
Parent folder
README.md 2026-02-04 6.7 kB
v3.2.0 source code.tar.gz 2026-02-04 20.2 MB
v3.2.0 source code.zip 2026-02-04 20.4 MB
Totals: 3 Items   40.6 MB 0

What's New

### Security & Infrastructure

  • mTLS support - new gen.CertAuthManager interface for mutual TLS with CA pool management (ClientCAs, RootCAs, ClientAuth, ServerName). See Mutual TLS documentation
  • NAT support - new RouteHost and RoutePort options in gen.AcceptorOptions for nodes behind NAT or load balancers. See Behind the NAT documentation
  • Zip-bomb protection - decompression size limits to prevent memory exhaustion attacks

### Process Management

  • Spawn time control - InitTimeout option in gen.ProcessOptions limits ProcessInit duration for both local and remote spawn. Remote spawn and application processes limited to max 15 seconds
  • Shutdown timeout - ShutdownTimeout option in gen.NodeOptions (default 3 minutes). During graceful shutdown, pending processes are logged every 5 seconds with state and queue info
  • pprof labels - with --tags pprof, each actor goroutine is labeled with its PID and each meta process with its Alias for easy identification in pprof output

### New gen.Ref Methods

  • Deadline - returns deadline timestamp stored in reference
  • IsAlive - checks if reference is still valid (deadline not exceeded)

### New gen.Node Methods

  • ProcessPID / ProcessName - resolve process PID by name and vice versa
  • Call, CallWithTimeout, CallWithPriority, CallImportant, CallPID, CallProcessID, CallAlias - synchronous requests from Node interface
  • Inspect / InspectMeta - inspect processes and meta processes
  • MakeRefWithDeadline - create reference with embedded deadline

### New gen.RemoteNode Method

  • ApplicationInfo - query application information from remote nodes

### New gen.Process Methods

  • SendWithPriorityAfter - delayed send with priority
  • SendExitAfter / SendExitMetaAfter - delayed exit signals
  • SendResponseImportant / SendResponseErrorImportant - important delivery for responses

### New gen.Meta Methods

  • SendResponse / SendResponseError - respond to requests from meta process
  • SendPriority / SetSendPriority - message priority control
  • Compression / SetCompression - compression settings
  • EnvDefault - get environment variable with default value

### Application Enhancements

  • Tags field in gen.ApplicationSpec / gen.ApplicationInfo - labels for instance selection (blue/green, canary, maintenance)
  • Map field - logical role to process name mapping
  • HandleInspect implementations for all supervisor types (OFO, ARFO, SOFO)

### Improved ProcessInit State More gen.Process methods now available during initialization:

  • Link*, Unlink*, Monitor*, Demonitor*
  • Call*, Inspect, InspectMeta
  • RegisterName, UnregisterName, RegisterEvent, UnregisterEvent
  • SendResponse*, SendResponseError*
  • CreateAlias, DeleteAlias

## Bug Fixes

  • Fixed LinkChild in RemoteNode.Spawn / RemoteNode.SpawnRegister
  • Fixed args persistence for Simple One For One supervisor - child processes now restart with their original spawn arguments
  • Fixed critical bug: terminate signals (Link/Monitor exits) were incorrectly rejected due to wrong incarnation validation in network layer. Thanks to @qjpcpu for reporting #248

## Internal Improvements

  • Completely reworked Target Manager (node/tm/) - improved architecture for process, event, and node target management with comprehensive test coverage
  • Completely reworked Pub/Sub mechanism - improved reliability and performance
  • Improved API documentation - comprehensive godoc comments for all public interfaces

## Extra Library

### Actors (ergo-services/actor)

  • Leader - distributed leader election with Raft-inspired consensus algorithm. Features: term-based disambiguation, automatic failover, split-brain prevention through majority quorum, dynamic peer discovery. Documentation
  • Metrics - Prometheus metrics exporter that collects node/network telemetry via HTTP endpoint. Features: automatic collection of node metrics (uptime, processes, memory), network metrics per remote node, extensible for custom metrics. Documentation

### Meta Processes (ergo-services/meta)

  • SSE (Server-Sent Events) - unidirectional server-to-client streaming over HTTP. Features: server handler for accepting connections, client connection for external SSE endpoints, full SSE spec support (event types, IDs, retry hints, multi-line data), process pool with round-robin load balancing, Last-Event-ID for reconnection. Documentation

## Benchmarks (ergo-services/benchmarks)

  • Distributed Pub/Sub benchmark - demonstrates event delivery to 1,000,000 subscribers across 10 nodes. Achieves 2.9M msg/sec delivery rate with only 10 network messages (one per consumer node) instead of 1M

## Documentation

Documentation has been completely rewritten and is now included in the repository (docs/) and available at docs.ergo.services.

New articles:

  • Project Structure - organizing projects with message isolation levels, deployment patterns, and evolution strategies
  • Building a Cluster - step-by-step guide to distributed systems with service discovery, load balancing, and failover
  • Message Versioning - evolving message contracts in distributed clusters with explicit versioning strategies
  • Handle Sync - synchronous message handling patterns
  • Important Delivery - guaranteed delivery mechanism
  • Pub/Sub Internals - event system architecture
  • Debugging - build tags, pprof integration, troubleshooting stuck processes
Source: README.md, updated 2026-02-04