The Architecture of Catena
The Architecture of Catena
Catena is a suite of tools that is designed to help game developers build online games quickly and efficiently. Sure, that sounds good, but when we say “tools” what do we mean? How does Catena differ from central technology platforms or Platform as a Service (PaaS)/Backend as a Service (BaaS) providers that are on the market today?
At Wolfjaw, far too many times we’ve seen how complicated it can be to integrate with central tech or third party platforms. These platforms promise reduced development times, but end up only delivering value once a game is nearing production. Game teams struggle leading up to this due to poor observability, difficulty debugging, less than ideal documentation, and varying levels of support. What was originally sold to them as an opportunity to get to market faster ends up swapping one set of problems for another, which at best leaves them in the same position they would be in if they had built custom backend services from scratch.
With our design principles in mind, we aim to address this problem by decreasing iteration time and reducing the barrier to entry for making online games. There are quite a few fundamental differences that you’ll find when utilizing Catena. The root of these differences stem from our source-available model. This extends to core design choices that make Catena interoperable, extensible, modular, easy to integrate with your game, and simple to run anywhere, even with limited backend service experience.
Source Available
The first major differentiator between Catena and SaaS/BaaS platforms is that it is source-available. We strongly believe that in order to provide the level of flexibility games need to succeed, game teams need the option to peel the curtain back and modify backend systems to match the needs required by their game. Rather than hosting Catena as a PaaS, we provide its source code to customers to do with what they please, much like Unreal Engine does for teams working on game clients and game servers.
Catena’s main repository, Catena Core, is a .NET project. We chose .NET for a variety of reasons:
- Smaller context switches for indie developers that are already familiar with C# through their work with Unity.
- It provides excellent reflection tooling, which we use to make it easy to drop in new modules or services with minimal configuration.
- It provides uncomplicated cross-platform support.
- It is performant, powering some of the largest backends in games.
Catena Core is meant to handle the hard parts of implementing a game backend. It is designed in a similar manner to “engine code” that you might find in Unreal. This is code that you can modify if you wish, but most developers will never need to touch it. Out of the box, it provides support for:
- Configuration management. Configuring services at runtime is paramount to operating successful live service games.
- Structured logging. Whether logging to stdout, OpenTelemetry, Datadog, or your favorite observability platform; Catena sets you up for an observable system on day one.
- Module registration. This includes both off the shelf modules that Catena provides such as parties or matchmaking, but also allows for developers to write their own modules with their own custom game logic as easily as they might create a serverless function on a major cloud provider.
- Service discovery. Catena can be run as a distributed system.
- Authentication and session management. Use Catena’s account system or bring your own. Either way, Catena Core has session management built into it.
- Network transport between clients and servers. These interfaces are defined with Protobufs and support gRPC or REST. We utilize gRPC streams to facilitate pushing information to clients as needed.
- Network transport between Catena services. We’ll touch more on interoperability later, but this is an interoperable event system that supports a lightweight development environment or Kafka for when Catena is being run as a distributed system.
- Database interfaces. Whether you need an in-memory data store, something on-disk, or a combination of many database types; Catena Core makes wiring these up straightforward.
If you or your team would like assistance standing Catena up on your infrastructure. Contact our development team or join our Discord. We’d be happy to help!
Interoperable, Extensible, Modular
Since Catena is source available, the possibilities for what game teams can create with it are much more plentiful than when they are only provided a rigid API. When we talk about interoperability, we’re actually talking about a few things. All services that come off the shelf with Catena can work as-is, but there is nothing preventing a customer from using our implementation as a reference and implementing their own business logic. Where Catena Core can be thought of as “engine code,” the services we provide in a distribution for Catena can be thought of as “game code.” These services are built to support a wide variety of use cases. However, for services that would become ineffective by attempting to support every possible developer goal (such as inventory management), we offer multiple versions that align with specific game types. In any event, these services are designed to take you 80-90% of the way toward a "finished product." In some cases, they can even get you 100% of the way to a minimum viable product in a matter of days rather than weeks or months.
For example, you can utilize one of our matchmaking strategies, or if you have custom matchmaking needs you can provide your own implementation with a few lines of C# code that is tailored to your game. Alternatively, if your matchmaking needs are simple but your inventory and progression needs are complex you can easily slot in your own inventory system. There is no obligation to use any service that we provide.
To us interoperability means more than providing well defined interfaces that allow our customers to write their own Catena components, it also means playing nicely with components that live outside Catena. Many platforms today are all or nothing, or at the very least require you to use their account systems. This can make them unapproachable, especially if your studio has legacy backend services. With Catena you are able to use the entirety of our offering if that fits your needs, but you are also able to use small pieces if you have existing services in place.
For example, let’s say you’re using some combination of custom backend services and PaaS platforms to support your core game loop of matchmaking, orchestrating servers, and granting inventory but you’d like to implement leaderboards, which the PaaS you are using does not provide. With Catena, you can use our auth middleware and session management system to accept requests from clients authenticated with other third-party platforms or by trusted services such as dedicated game servers. In this example, rather than having to write your own custom service from scratch you can utilize Catena’s leaderboard service to cut large amounts of development effort out of the equation.
Examples of interoperability extend beyond backend services. As Catena is a suite of tools rather than a backend platform, we also provide tooling that decreases integration time to game server hosting providers. Rather than integrating third party SDKs to your game server, we provide a single point of integration with our server sidecar which provides a happy path to deploying your game server on GameLift, Multiplay, Gameye, VMs, bare metal, etc. After one integration you are able to switch between server providers at-will with virtually zero additional work.
Easy to Integrate With Your Game
Catena provides SDKs for Unity, Unreal, or Proprietary Game Engines. Our C++ SDK could feasibly be used in other open source engines such as Godot also. These SDKs are meant to drop in with minimal configuration in order to provide a delightful developer experience. We additionally provide RESTful endpoints if your team prefers direct integration with our backend services or if you need to integrate with custom services that you’ve introduced business logic for.
Our goal is to meet game teams where they’re at in their development cycle, making it as easy as possible for them to iterate in a manner that is conducive to their goals. With this thinking, we’ve taken an “integrate once” approach. A concrete example of what this means is a near zero amount of backend work other than updating some config files to go from iterating on a P2P architecture early in development to moving to a dedicated game server model when the time is right. In our minds, integration and iteration go hand in hand.
Simple to Run Anywhere
Building on our philosophy of easy integration and iteration, Catena is designed to run anywhere. Unlike PaaS/BaaS platforms, Catena can be run as a modular monolith on a developer’s workstation, on a single bare metal machine, on a single VM in the cloud, or as a production grade distributed system with its modules broken up into microservices. Need to end-to-end debug a feature? Run your game and Catena locally. Need to run a playtest on the server in your studio’s closet? Run Catena on that server. Need to run load tests to verify players won’t be complaining on Reddit a few hours after launch? Run Catena as a distributed system using Kubernetes on your favorite cloud provider.
We provide tooling and documentation to deploy + run Catena in each of these configurations, leaning on configuration as code technologies such as Terraform. Spinning environments up and down are as close to “one click” as possible.
If you or your team would like assistance standing Catena up on your infrastructure. Contact our development team or join our Discord. We’d be happy to help!
Operational Features
Another key difference between Catena and SaaS/BaaS platforms is the support we provide for game development operations. One key example of this is our Catena Launcher and Admin Panels. While launchers are typically thought of as ways to distribute your game(s) to the public, they can also be used to help coordinate studio-wide playtests. With the Catena Launcher and Admin Panels, a designated person or team of people can upload, configure command line args, and distribute game client binaries across the studio. This makes it possible for other members of the studio to open the launcher and automatically get the correct build for that day’s playtest.
We’re still early in the process of building out these tools, and there’s plenty more to come on this front. We see a lot of value in helping game teams iterate more easily as opposed to just supporting games once they’ve made it to production.
Conclusion
A lot of care has been taken to ensure that Catena actually delivers on its promises of decreased development times for studios. Having seen how these types of tools can go wrong, we’re incredibly excited to see how this fresh take improves the lives of developers ranging from indies to AAA.