Infrastructure as Data

Lynq turns each row into a complete set of Kubernetes resources, keeps it in sync as the row changes, and cleans it up when the row goes away — without writing a controller.

mysql customers ⇄ kubectl
cluster · 2 LynqNodes↻LynqHub sync
  • acme-webDeploymentService
  • gamma-webDeploymentService

Rows without a LynqNode: 1

Simulated table and cluster; every object is rendered by Lynq's engine. A real hub syncs every 30s.Run it for real →

Run it on your clusterNeeds Kubernetes 1.28+ and cert-manager.

Then follow the Quick Start →
helm repo add lynq https://k8s-lynq.github.io/lynqhelm install lynq lynq/lynq -n lynq-system --create-namespace --set namespace.create=false

How it works

Change a row. The cluster follows.

One loop, from insert to cleanup. Each step links to the page that explains it.

Illustration: each active row gets its own set of resources; the cluster keeps matching the tableA table with rows acme, beta and gamma; beta is inactive. Lynq gives each active row its own stack of resources: acme and gamma each get one, beta gets none. The resources start updating and turn Ready. A new row, delta, is inserted and its stack appears. Someone changes one of acme's resources by hand; it turns red, and Lynq applies the template again and puts it back. Then gamma is deactivated and its stack is removed. At every step the resources in the cluster match the active rows in the table.
  1. 01Insert a rowINSERT INTO customers … active = TRUEThe LynqHub reads it on its next sync (default every 30s).Read more: Insert a row →
  2. 02Lynq applies the resourcesLynqNode acme-web → Deployment, ServiceServer-Side Apply in dependency order (dependIds).Read more: Lynq applies the resources →
  3. 03They become ReadyReady=True on the LynqNodeEach resource is checked with its kind’s readiness rule, with a timeout.Read more: They become Ready →
  4. 04Someone edits one by handkubectl edit deployment acme-webWatches and a periodic re-apply put the template’s values back.Read more: Someone edits one by hand →
  5. 05Deactivate the rowUPDATE customers SET active = FALSEThe LynqNode is deleted and its resources are cleaned up — or kept, with deletionPolicy: Retain.Read more: Deactivate the row →

Why Lynq

Why not a script, Helm, or your own operator?

A script or CI job per change

Runs once and forgets. Lynq keeps reconciling: drift is reverted and deleted rows are cleaned up.

Helm releases per customer

One release per row to install, upgrade and delete. With Lynq the row is the release; a template change rolls out gradually with maxSkew.

Your own operator

A controller, CRDs, RBAC and upgrades to own forever. Lynq is that operator, with lifecycle policies, metrics and runbooks included.

Lynq is not the right tool for everything. See when it fits and what it does not do.

Safe at scale

A template change does not hit every row at once.

maxSkew lets only a few LynqNodes update at a time. One that is not Ready holds its slot, so the rollout waits for it.

Illustration: maxSkew caps the LynqNodes updating at once; a slot frees only when its node is ReadyNine LynqNodes run version 1. The template changes to version 2. Without a limit, all nine would update at the same time. With maxSkew: 3, only three enter the "updating" gate. When one becomes Ready on version 2 it leaves and the next node enters. One node is slow: it stays not Ready and keeps its slot, so only two others can move through meanwhile. When it is Ready, the rest follow. All nine end on version 2, and the gate never held more than three.

Operate it

Know when it breaks, and what to do.

Every failure state has a metric, an alert and a runbook that says what to do. The Lynq Dashboard shows every Hub, Form and Node and highlights the ones that need you.

Lynq Dashboard topology view of 1 LynqHub, 2 LynqForms and 10 LynqNodes, all green. One node is expanded to show the resources it owns — KafkaTopics, a Deployment, a Service, an Ingress and a Job — and an orphaned Job is listed on its own.
Topology view: Hub → Form → Node.
Lynq Dashboard in Problem Mode reporting 2 problems: the core-api LynqForm (4 of 5 nodes ready) and its one failing LynqNode are outlined in red, and every healthy object is dimmed.
Problem Mode: only the nodes that need attention.

Examples

What people build with it.

Start with one table.

Install Lynq with Helm, point a LynqHub at a table, and apply a LynqForm. The Quick Start does it on a local cluster in about five minutes.

helm repo add lynq https://k8s-lynq.github.io/lynqhelm install lynq lynq/lynq -n lynq-system --create-namespace --set namespace.create=false