kalix gradient

Developer

Kalix—Self Provisioning Fully
Managed Reactive System

Developer Responsibility

Developer Experience

1
Pick your language SDK: Java, JavaScript, TypeScript, Scala

Pick your language SDK: Java, JavaScript, TypeScript, Scala

2
Define your Domain Data

Define your Domain Data

3
Write the Service and Configure it

Write the Service and Configure it

4
Package it up, and Test it (locally and/or CI/CD)

Package it up, and Test it (locally and/or CI/CD)

See Developer Sandboxes below
5
Deploy to kalix.io

Deploy to kalix.io

6
Done. Let Kalix deal with the rest

Done. Let Kalix deal with the rest

Developer Sandboxes (Coming Soon)

Developer Sandboxes is a pre-configured production-like local runtime that allows developers to test their changes as they code, which dramatically reduces the risk of things not working in production.

Integrate your Local Tools

Integrate your Local Tools

Run Locally in a Prod-Like Env

Run Locally in a Prod-Like Env

Test Locally in a Prod-Like Env

Test Locally in a Prod-Like Env

Developer Responsibility

Code

Let’s look at a Service consisting of Entity and View

Entity (Stateful)

API endpoint with:

  • Domain Data
  • Business Logic
  • HTTP definition
@EntityType("customer")
public class CustomerEntity extends ValueEntity<CustomerEntity.Customer> {

  record Customer(String name, String email) {}
  record CreateCustomer(String name, String email) {}
  
  @EntityKey("customer_id")
  @PostMapping("/customers/{customer_id}")
  public Effect<String> createCustomer(@RequestBody CreateCustomer create) {
    return effects()
      .updateState(new Customer(create.name, create.email))
      .thenReply("done");
  }
}

View (Materialized)

API endpoint:

  • Querying the domain data
  • Returning streamed data set
  • HTTP definition
@Table("customers")
@Subscribe.ValueEntity(CustomerEntity.class)
public class CustomerByNameView extends View<CustomerEntity.Customer> {
  
  @GetMapping("/customers/by-name/{name}")
  @Query("SELECT * FROM customers WHERE name = :name")
  public Flux<CustomerEntity.Customer> findCustomers(String name) {
      return null;
  }
}

NO CODE required for data persistence and query. The data is automatically injected into your services on an as-needed basis, and queries are consumed through live materialized views.

Operator Responsibility

Operator Experience

Kalix Tools: CLI and Web Console

Kalix Tools: CLI and Web Console

Manage Cloud and Edge Regions

Manage Cloud and Edge Regions

View Metrics, Logs, Service Health

View Metrics, Logs, Service Health

Integrate Events, Metrics, Logs with External Systems

Integrate Events, Metrics, Logs with External Systems

Manage Secrets, JWT, and Client Certificates

Manage Secrets, JWT, and Client Certificates

Manage Roles, Users, Organizations

Manage Roles, Users, Organizations

Manage Public APIs: Routes etc

Manage Public APIs: Routes etc

Manage Paid Plans

Manage Paid Plans

Developer Responsibility

Operator Responsibility

Managed by Kalix

Managed by Kalix

Gradient Background

Inferred from Code

Managed By Kalix

Auto-Generated Reactive Architecture

Auto Generated Reactive Architecture

Managed By Kalix

Unparalleled Performance

6 ms Read & 8 ms Write Latency

6 ms Read & 8 ms Write Latency

99.9% Uptime SLA

99.9% Uptime SLA

3x Faster Software Development

3x Faster Software Development

80% Reduced Operations Costs

80% Reduced Operations Costs

Low Latency with High Throughput

1000 TPS
99 percentile
8000 TPS
99 percentile
15000 TPS
99 percentile
Read: 6 msRead: 7 msRead: 12 ms
Write: 8 msWrite: 16 msWrite: 20 ms
Kalix Customer“We are confident that Kalix will increase developer productivity and deliver 3X acceleration in the real world.”
Michallis Pashidis,
Founder and CEO, Trust1Team

Managed By Kalix

Runtime Execution of Service

Runtime Execution of Service

Flow of a Service Request

  1. User sends a Request with EntityId as metadata
  2. Entity gets Request, run Business Logic, updates the State and emits an Event representing the State Change
  3. Reply is sent back to the User
  4. After persisting Event in the Event Log it is relayed to the View (read side of CQRS), which is building up a query representation based on the SQL

Flow of a Query

  1. User initiates a Query to the View
  2. The View, managing a live materialized view of the domain data, grabs the ResultSet from DB
  3. Kalix returns a Stream with ResultSets

Service to Service Communication

  1. Service A is communicating with Service B using Brokerless Pub/Sub or RPC over gRPC

External System Communication

  1. Action in Service B is sending Events to an external Message Broker, e.g. Kafka for external system integration

Managed By Kalix

How Kalix implements the Reactive Principles

Stay Responsive

Kalix serves Read Requests at 6 ms and Write Requests at 8 ms latency (at the 99 percentile and moderate load). Kalix ensures this level of responsiveness by leveraging Akka and proven reactive, concurrency, and distributed systems techniques and patterns (see more below).

Accept Uncertainty

Kalix assumes a world with no single “now”. It balances the consistency levels (eventual to strong) always opting for the weakest consistency guarantee that does the job. It offers state models based on logical time, such as CRDTs, and patterns leveraging eventual and causal consistency, such as CQRS and Vector Clocks.

Embrace Failure

Kalix is build on Akka which leverages the Actor Model. Actors are resilient by design and have self-healing capabilities. Failures are expected, planned for, and communicated as values and can as such be dealt with in a structured and safe way. Techniques here include back-pressure, circuit breakers, actor supervision, graceful degradation, bulkheads, failure detection, etc.

Assert Autonomy

Services in Kalix are location transparent and loosely coupled (in time and space) communicating through events transmitted over well-defined protocols. Kalix itself runs on Akka Actors leveraging patterns like state partitioning, consistency boundaries, event sourcing/CQRS, which ensures that the underlying system is build on decoupled, autonomous, location transparent, self-organizing, and self-adapting components.

Tailor Consistency

Every consistency guarantee comes with a cost, which means that always blindly choosing the strongest model can be very wasteful. Kalix’s different state models gives the user a wide range of options—from eventual, to causal, to strong consistency—in choosing the right and most efficient consistency model for its domain data. Techniques include bounded contexts, CRDTs, logical clocks, single writer principle, CQRS, materialized views, etc.

Decouple Time

Communication, I/O, and data processing in Kalix is non-blocking and asynchronous, ensuring efficient management of resources. This also allows for temporal decoupling which increases autonomy and resilience. Techniques employed include async message-passing, event-driven coordination, intermediate queues, brokerless pub/sub, append-only journaling, and streaming.

Decouple Space

We can only create a resilient system if we allow it to live in multiple locations so it can continue function during partial failure. Spatial decoupling allows isolation of failure (so-called bulkheads) avoiding it to cascade throughout the system. Kalix ensures this through data partitioning, bulkheads, async message-passing, actor supervisor hierarchies, location transparent protocols, and more.

Handle Dynamics

Being able to continuously adapt to varying demand and resources is key for any distributed system. Scalability/elasticity does not just mean scaling up, it is equally important to be able to scale down. Kalix embodies this at its core through adaptive auto-scaling at the routing level, service level, and data management and replication level (through Akka Cluster Sharding).

Visit reactiveprinciples.org to learn more.

Managed By Kalix

SRE / Operations

What Kalix takes care of, so you don't have to:

Infrastructure

  • IAM (Identity Access Management)
  • High-Availability Architecture
  • Infrastructure As Code
  • Automation
  • Patching
  • Networking
  • Firewalls
  • Security Groups
  • Load Balancing
  • DNS
  • Kubernetes
  • Service Mesh
  • Node Optimization
  • Ingress

SLAs

  • 99.9% to 99.5% availability SLA
    (depending on plan)

Database

  • Configuration
  • Patching
  • Performance Tuning
  • Disaster Recovery (Backup/Restore)

Observability

  • Basic monitoring
  • Alerting
  • Tracing
  • APM (Application Performance Monitoring)

DevOps/SRE

  • 24/7 Support
  • CI/CD IaC
  • Root Cause Analysis
  • Incident Triage

Security

  • Endpoint Protection
  • Threat Intelligence
  • User/service account lifecycle management
  • Incident Response

Integrations

  • Kafka
  • AWS SQS/SNS
  • Google Pub/Sub
  • Open Telemetry
  • Grafana
  • Datadog
  • Cloudwatch
  • VPC peering

Compliance

  • SOC2
  • GDPR

Managed By Kalix

Cloud & Edge Deployment

Deploy to AWS/GCP locations. Azure & Edge deployment coming soon.

Auto Generated Reactive Architecture

Get going with Kalix in 3 easy steps based onprogramming language of your choice

kalix tabs gradient

1Design your API and data model

Design your API

@EntityType("customer")
@EntityKey("customer_id")
@RequestMapping("/customer/{customer_id}")
public class CustomerEntity extends 
  ValueEntity<Customer> {

    @PostMapping("/changeAddress")
    public Effect<String> changeAddress(
      @RequestBody Address newAddress) {
      // ...
    }
}

Describe API endpoints and API data model. Expose your API as gRPC, REST or let it connect to a message broker.

Design your data

public record Customer(
  String email, String name, Address address) {

    public Customer withName(String newName) {
      return new Customer(email, newName, address);
    }

    public Customer withAddress(
      Address newAddress) {
        return new Customer(
          email, name, newAddress
        );
      }
}

Describe your domain data and choose your preferred durable storage model (key/value, event sourcing, or CRDTs).

2Implement your business logic

@PostMapping("/changeAddress")
public Effect<String> changeAddress(@RequestBody Address newAddress) {
  Customer updatedCustomer = currentState().withAddress(newAddress);
  return effects().updateState(updatedCustomer).thenReply("OK");
}

Kalix Maven plugin, based on the defined API, generates required resources for focusing only on implementing the business logic code.

NO CODE required for data persistence and query. The data is automatically injected into your service on an as-needed basis, and queries are consumed through live materialized views.

3Deploy

kalix service deploy customer-registry myrepo/customerregistry:latest

Kalix Maven plugin builds and publishes the image to an image repository of your choice and the Kalix CLI tool is used to deploy and manage your service on Kalix.

Kalix, as a fully managed runtime environment, removes a need for any operations and maintenance of the infrastructure and takes care of security, logging, monitoring, zero-downtime upgrades, and auto-scaling.

Getting Started Videos

SubscribeFollow
What is Kalix
1

What is Kalix

This is the first video of this nine-part video series with an overview of What is Kalix?

Setting Up a Kalix Development Environment
2

Setting Up a Kalix Development Environment

Learn how to create an account, use the Kalix CLI and console, and look at some quickstart projects.

How to Create Kalix Java Development Projects
3

How to Create Kalix Java Development Projects

Java developers get an introduction to creating and developing Kalix projects.

Intro to Design and Implementation of Kalix Services
4

Intro to Design and Implementation of Kalix Services

Here we dig into the design, development, testing, and managing of Kalix services.

Implementing Kalix Event Sourced Entities
5

Implementing Kalix Event Sourced Entities

See how easy it is to implement dynamic and effective event-sourced entity services in Java.

Implementing Kalix Key-Value Entities
6

Implementing Kalix Key-Value Entities

The more CRUD-like key-value entities are similar to event-sourced entities, and they are also more familiar to most developers.

Implementing Kalix Views
7

Implementing Kalix Views

Kalix views provide the flexibility of SQL queries of data created by event-sourced and key-value entities.

Implementing Kalix Actions
8

Implementing Kalix Actions

Actions are the glue that binds topics to entities, entities to entities, and much more.

Building Kalix Event-Driven Micro Stream Applications
9

Building Kalix Event-Driven Micro Stream Applications

Finally, we look at how entities, views, and actions, the core Kalix building blocks, are used to build Kalix micro stream/state stream applications.