The Simplest Way to Make Apache Thrift and Backstage Work Like They Should

Published
Length
3 min read

Luis Felipe Dias

All posts

Using apache thrift and backstage together helps teams track RPC schemas in one portal. Backstage catalogs the interface files while Apache Thrift handles fast calls between backend apps. This workflow gives developers one place to find service owners and data contracts. Platform teams can check dependencies and review interface changes before code hits production. How apache thrift and backstage share data and permissions Apache Thrift uses a simple text file to define data types and servic

Your coding agents run with your access.

Claude Code reaches prod with a developer's credentials, and approval prompts get clicked through. hoop.dev checks every query, masks sensitive data, and holds risky changes for a human.

Using apache thrift and backstage together helps teams track RPC schemas in one portal. Backstage catalogs the interface files while Apache Thrift handles fast calls between backend apps.

This workflow gives developers one place to find service owners and data contracts. Platform teams can check dependencies and review interface changes before code hits production.

How apache thrift and backstage share data and permissions

Apache Thrift uses a simple text file to define data types and service methods. Teams store these interface files in git repos right next to their app code. Backstage reads those repos and pulls the service details into its central software catalog.

Developers log in to Backstage using their main work identity provider. Backstage then checks group roles to decide who can view or register catalog items. When Backstage fetches interface files from git, it uses a read-only token.

Runtime traffic follows a separate path from the catalog data flow. Backend apps use generated Thrift code to send binary messages over raw TCP sockets. The portal shows how services relate, while the RPC framework moves the live data.

Teams often build custom portal views to display Thrift method signatures and field types. This setup lets engineers read contract details without digging through dozens of code repos. Good role rules ensure only approved teams can edit those registered service definitions.

Common failure modes and how to scope roles

Many teams make the mistake of using one shared account for all RPC calls. When ten apps share one key, audit logs cannot show which app sent a request. A leaked key also forces the team to update every single service at once.

Broad tokens in the developer portal cause another major security risk for platform teams. If Backstage holds a write token for git, a portal bug could alter code. Give the portal a narrow token that can only read specific catalog files.

End-to-End Encryption + Backstage Security Plugins: architecture patterns and best practices

Continue reading? Get the full guide.

Free. No spam. Unsubscribe anytime.

Unlogged RPC queries also create blind spots during security audits and outage reviews. Raw Thrift sockets do not track user identities or record field-level changes by default. Sensitive fields like emails, phone numbers, or card numbers might travel in plain text.

To fix network paths, place backend RPC services in private subnets with strict firewall rules. Only allow traffic from known app servers that need to call those specific methods. Use mutual TLS so every calling app proves its identity with a unique certificate.

Assign each service a distinct role that permits calls to only the methods it needs. Keep portal traffic and production RPC traffic on separate network paths at all times. When teams log RPC calls, masking rewrites matched fields like national IDs in results.

Keeping interface files and catalog entries in sync

Stale catalog data hurts developer trust faster than almost any other portal issue. If a team changes a Thrift file, the portal must show that update right away. Set up automated git hooks to refresh Backstage whenever a main branch changes.

Teams should also check for breaking changes before merging new interface files. A simple build step can compare the new Thrift file against the last version. Dropping a required field or changing a number type will break older calling apps.

Link those build checks back to the service page inside your developer portal. Engineers can then see at a glance if a service contract is safe to use. Clear ownership tags in the catalog tell developers who to ask when calls fail.

Govern statements and responses across databases and APIs

Good config and scoped roles are needed setup. They do not check single queries in flight or mask sensitive fields in returned rows. Across Postgres, MySQL, SQL Server, MongoDB, ClickHouse, Kubernetes APIs, SSH, and internal HTTP endpoints, hoop.dev runs beside each supported service as an open-source proxy, a sidecar for your database or API.

First, hoop.dev guardrails block banned queries before they run. Then hoop.dev data masking rewrites matched sensitive values in responses in memory. The audit trail records every statement and verdict per resource. Furthermore, hoop.dev holds SOC 2 Type II and is open source on GitHub.

Frequently asked questions

How does Backstage display Apache Thrift service contracts?

Backstage reads catalog files stored in git alongside your Thrift interface files. Teams register the file path as an API entity so the portal displays the schema.

Should Backstage send live RPC calls to production Apache Thrift services?

No, the developer portal should only read static schema files from your code repos. Letting the portal call live RPC endpoints creates huge security risks and network exposure.

How do teams secure service-to-service calls in Apache Thrift?

Teams wrap Thrift sockets in mutual TLS and give each calling app a unique certificate. Firewall rules and role checks then restrict which apps can call specific methods.

The query runs. The emails stay hidden.