Skip to content

Releases: txn2/rtbeat

v1.2.1 — Modernization & durability

Choose a tag to compare

@github-actions github-actions released this 17 Jun 07:30
3ad8c99

The modernization release. rtbeat moves from the 2018 v1.1.1 line onto a current foundation: Go modules + Go 1.26, Elastic libbeat v7.17.29, an end-to-end durability guarantee, ~90% test coverage, a full CI/supply-chain pipeline, and multi-arch container images on the GitHub Container Registry.

Upgrading from v1.1.1? Read Breaking & behavior changes first — both the HTTP delivery contract and the container registry have changed.

⚠️ Breaking & behavior changes

1. POST /in now acknowledges after delivery (durability)

Previously rtbeat returned 200 as soon as it received a batch and published asynchronously, so an in-flight event could be lost on a restart even though the sender treated the 200 as durable. Now:

  • rtbeat publishes with libbeat GuaranteedSend and waits up to timeout seconds (default 5) for the output to acknowledge the batch.
  • On ack → 200 ("delivered"). On timeout → 504, so a durable sender such as rxtx keeps its copy and retries instead of dropping it on a premature 200.
  • Graceful shutdown now drains in-flight events (up to shutdown_timeout, default 30s) before closing the publisher.
  • The stray empty event that was published with every batch has been removed.

Operator action:

  • Tune timeout to your output's latency and batch size — a batch that can't be acked within timeout returns 504 and is retried; large batches may need a higher value.
  • Use a deterministic document _id downstream so a retried batch de-duplicates rather than creating duplicates.
  • Keep shutdown_timeout below your orchestrator's termination grace period so the drain completes before SIGKILL.

2. Container images moved to the GitHub Container Registry

Images are now published to ghcr.io/txn2/rtbeat (previously Docker Hub txn2/rtbeat). Update your image references.

3. libbeat upgraded across the 7.x line (v7.0.0-alpha → v7.17.29)

The event envelope libbeat emits evolved over the 7.x ECS migration. If you depend on exact Elasticsearch document field names, validate the document shape in a staging index before rolling to production.

Highlights

  • Go modules + Go 1.26, replacing glide/GOPATH vendoring.
  • Elastic libbeat v7.17.29 (from the v7.0.0-alpha line).
  • End-to-end durability — ack-after-delivery + graceful drain (above), proven by an e2e suite that runs the real binary against a live lumberjack output and asserts 200-only-after-ack, 504-on-stall, and in-flight drain on SIGTERM.
  • Dependency refresh, including a fix for a reachable vulnerability in prometheus/client_golang (GO-2022-0322).
  • ~90% test coverage (unit + lifecycle + e2e), run under the race detector.
  • Full CI / supply chain: golangci-lint, CodeQL, OpenSSF Scorecard, Dependabot; multi-arch images (linux/amd64, linux/arm64), Cosign keyless signing, and SBOMs.

Configuration

rtbeat:
  port: "8081"          # HTTP listen port for /in and /metrics
  timeout: 5            # seconds to wait for the output to ack before 504
  shutdown_timeout: 30  # seconds to drain in-flight events on shutdown
output.logstash:        # or output.elasticsearch, etc.
  hosts: ["logstash:5044"]

See rtbeat.reference.yml for the full libbeat output/queue options (including the disk queue/spool for at-least-once delivery across hard crashes).

Install

Container (multi-arch, GHCR):

docker run --rm -p 8081:8081 -v "$PWD/rtbeat.yml:/rtbeat.yml" \
  ghcr.io/txn2/rtbeat:v1.2.1 -c /rtbeat.yml -e

Homebrew:

brew install txn2/tap/rtbeat

From source (Go 1.26+):

git clone https://github.com/txn2/rtbeat && cd rtbeat
go build -o rtbeat .

Verify the image (Cosign)

The container images are signed with Cosign keyless signing:

cosign verify \
  --certificate-identity-regexp "https://github.com/txn2/rtbeat" \
  --certificate-oidc-issuer "https://token.actions.githubusercontent.com" \
  ghcr.io/txn2/rtbeat:v1.2.1

Upgrading from v1.1.1

  1. Switch image references from txn2/rtbeat to ghcr.io/txn2/rtbeat.
  2. Add/confirm timeout and shutdown_timeout; set shutdown_timeout below your pod's terminationGracePeriodSeconds.
  3. Expect 504s when the output stalls — ensure your sender retries on non-2xx and that downstream uses a deterministic _id.
  4. Validate the Elasticsearch document shape in staging if reports depend on exact field names.
  5. Roll out to one shipper first; watch the rtbeat 504 rate and the sender's queue depth, then proceed.

What's changed

  • Modernize: Go modules + libbeat v7.17.29 + SDLC/CI hygiene (#2)
  • Bulk dependency update; decline rxtx v2 and slsa 2.1.x (#10)
  • Add unit tests and coverage for the message path (#12, #13)
  • Bump txn2/rxtx 1.3.2 → 1.5.2 (#11)
  • Cover the beat lifecycle to reach the coverage gate (#14, #15)
  • Durability: ack-after-delivery + drain on shutdown, with an e2e suite (#16)
  • Publish container images to GHCR instead of Docker Hub (#17, #18)
  • Fix multi-arch Dockerfile COPY for GoReleaser (#19)

Full diff: v1.1.1...v1.2.1

v1.1.1

Choose a tag to compare

@cjimti cjimti released this 17 Nov 03:38

Changelog

c80bc1c removed arm from build

Docker images

  • docker pull txn2/rtbeat:latest
  • docker pull txn2/rtbeat:1.1.1

v1.0.4

Choose a tag to compare

@cjimti cjimti released this 03 Aug 16:33

Changelog

d3b2ec6 housekeeping
732cc97 logging cleanup

Docker images

  • docker pull txn2/rtbeat:latest
  • docker pull txn2/rtbeat:1.0.4

v1.0.2

Choose a tag to compare

@cjimti cjimti released this 26 Apr 04:29

Changelog

d6c0ab9 refactor for txn2

Docker images

  • docker pull txn2/rtbeat:latest
  • docker pull txn2/rtbeat:1.0.2

v1.0.1

Choose a tag to compare

@cjimti cjimti released this 21 Apr 19:23

Changelog

05b3085 added client ip
02616df documentation update
89cac1b documentation updates

Docker images

  • docker pull cjimti/rtbeat:latest
  • docker pull cjimti/rtbeat:1.0.1

v1.0.0

Choose a tag to compare

@cjimti cjimti released this 17 Apr 02:21

Changelog

3266bdf added go releaser

Docker images

  • docker pull cjimti/rtbeat:latest
  • docker pull cjimti/rtbeat:1.0.0