/  ,

Opsgenie shutdown: the dates and your options

On March 3, 2025 Atlassian announced the end of Opsgenie. It stopped selling it on June 4, 2025, and on April 5, 2027 it turns it off and deletes any data that hasn't been moved. That's four months from now. If your team still gets paged through Opsgenie, this is what happens on each date and where you can go.

We make Tissue Mast, which is one of the places you can go, so we have a stake in this. Every figure about another company below comes from that company's own pages, read today, December 2, 2026.

datewhat changed or changes
June 4, 2025End of sale. No new Opsgenie sign-ups or purchases, no new sites, and no moving between editions. You can renew if the new term ends before April 5, 2027, and you can still buy extra seats until then.
April 5, 2027End of support. Atlassian shuts off access to Opsgenie and deletes any data that hasn't been migrated. Contracts run to the end of their term or to this date, whichever comes first.

Until April 5, 2027 Opsgenie keeps working as it does today. If you use Atlassian's migration tool, your Opsgenie switches itself off 120 days after the move, and you can turn it off sooner, which can't be undone. Whatever is still in Opsgenie on April 5, 2027 goes: schedules, escalations, integrations and the alert history. A monitor that still sends to Opsgenie after that has nowhere to send.

Atlassian's migration pages send Opsgenie customers to Jira Service Management. The tool is in Opsgenie under Settings, Migrate Opsgenie. An Opsgenie owner who is also a site admin schedules it, at least 7 days ahead and no later than April 5, 2027, and a billing admin approves it. You can reschedule once. Atlassian maps Opsgenie Free to JSM Free, Essentials to Standard and Standard to Premium.

JSM is a service desk with alerting inside it, priced per agent. Free covers 3 agents with alerts, on-call schedules and an escalation policy. For five agents, Standard is $26.90 per agent a month and adds SMS and voice. Premium is $61.60 per agent a month, and that's the plan with heartbeat monitoring. The pricing page also says usage-based billing starts December 3, 2026.

Atlassian also has Compass, a developer portal whose Standard plan, at $8 per user a month, includes on-call schedules and alerts. Heartbeats and voice notifications are on its $25 Premium plan. Atlassian's Opsgenie migration pages don't list Compass as a destination today, so ask Atlassian before you plan around it.

If what you used Opsgenie for was getting someone's phone to ring, you don't need a service desk. These are priced from each company's pricing page today:

toolprice
PagerDutyFree for 5 users with one schedule and one escalation policy. Professional is $25 per user a month, or $21 billed annually
incident.ioBasic is free with single-team on-call. Team is $19 per user a month, plus $12 per user for on-call, or $15 and $10 on annual billing
Grafana Cloud IRMFree for 3 active IRM users. Pro is a $19 a month platform fee that covers 3, then from $20 per active IRM user
Better StackA Responder license is $34 a month, or $29 billed annually, with unlimited phone calls and SMS
All QuietStandard is $4.99 per user a month with SMS and phone calls included. Pro is $9.99
Tissue MastFree for 5 people. Team is $29 a month for the whole account, with no limit on people

Opsgenie alternatives for small teams has each one in more detail, with what five people cost on each.

Mast answers Opsgenie's alert API, so Alertmanager, Grafana and Zabbix move by changing the API address to https://mast.tissue.dev/opsgenie and the key to a Mast key. An importer reads your Opsgenie account and builds the same rotations, escalation policies, alert sources and heartbeats. It starts with a dry run that changes nothing and works on the free plan, in the web app or from the command line:

$ export OPSGENIE_API_KEY=…
$ ribo mast import opsgenie           # dry run
$ ribo mast import opsgenie --apply   # import, then print the re-key list

Mast doesn't send SMS, has no email ingest, and only calls numbers in the US, Canada, the UK, the EU, Australia and New Zealand. It has no post-incident reviews, no SAML, no per-person notification rules and no rotations that are only on during working hours. If your team relies on any of those, pick something else from the list.

Moving from Opsgenie to Tissue Mast goes through the move step by step, and Mast vs Opsgenie sets the two side by side.

Wherever you go, the work is about the same. List every integration and the key it uses, since each sender needs a new address and key. Export the alert history you want to keep through Opsgenie's API, because nothing reads it after the shutdown. Send to the old and new tool together for a few days and compare. Then revoke the Opsgenie keys.

Atlassian's migration tool won't take a date later than April 5, 2027, and it has to be scheduled at least 7 days ahead.

/  , ,

c3 searches by meaning.

c3 runs on libSQL, which has vector columns and a nearest-neighbour index built in. Here's how a Cell uses them, what they cost at different sizes, and a bug in the index we fixed while measuring it.

Every Cell can bind a c3 database, and c3 is built on libSQL, the fork of SQLite that Turso maintains. libSQL stores a vector in an ordinary column and compares vectors in plain SQL. So a Cell can search its own data by meaning with no second database, no extension to load and nothing extra to deploy. Our js-vec-search example has done this since June. What we hadn't done was write it up properly, so this week we wrote the reference page, measured how far each approach goes, and found one bug on the way.

This is the whole thing, from table to search:

await env.DB.exec(`
  CREATE TABLE docs (id INTEGER PRIMARY KEY, title TEXT, embedding F32_BLOB(1536))
`);

await env.DB.prepare("INSERT INTO docs (title, embedding) VALUES (?, vector32(?))")
  .bind(title, embedding)          // a plain array of 1536 numbers
  .run();

const { results } = await env.DB.prepare(`
  SELECT id, title, vector_distance_cos(embedding, vector32(?)) AS distance
  FROM docs ORDER BY distance LIMIT 10
`).bind(queryEmbedding).all();

F32_BLOB(1536) is a column of 1536 float32 values. vector32() turns text like [0.1, 0.2, ...] into one, and vector_distance_cos gives the cosine distance between two, where smaller means closer in meaning. The binding sends parameters to c3 as JSON, and a JSON array is exactly the text vector32() reads, so the array an embeddings API hands back binds as it is.

js-vec-search wraps that in a Cell you can deploy. It embeds each document with OpenAI's text-embedding-3-small using your own API key, stores the result in an F32_BLOB(1536) column, and ranks documents against a query with the SELECT above. It has a small search page at /. This week the key moved from a c3 table into a vault binding, which is where a secret belongs.

That query compares the question against every row, and the example does that on purpose. It sounds like it should be slow, so we measured it on a release build of c3 on a laptop. Searching 10,000 rows of 1536 dimensions took 34 ms. 20,000 rows of 384 dimensions took 19 ms, and 2,000 rows of 1536 took 7 ms. The answers are exact, since every row gets looked at.

So a Cell with a few thousand documents, say a support knowledge base or a product catalogue, can search by meaning with one query and no setup beyond the column.

For bigger tables libSQL has an approximate index. You create it with libsql_vector_idx and query it with vector_top_k, and it reads a small part of the table instead of all of it. We loaded 2,000 rows of 1536 dimensions into a table that had the index on it from the start.

With the default settings, the load took 87.8 seconds. The slowest batch of 100 inserts took 5.4 seconds on its own. The database grew to 658 MB, against 16 MB for the same rows with no index. The index keeps a full-precision copy of each row's neighbouring vectors next to the row, so it ends up far bigger than the data it indexes. A search through it took 26 ms and found all ten of the true nearest rows.

libSQL has two options that shrink it. compress_neighbors=float8 stores the neighbour copies at 8 bits instead of 32, and max_neighbors=16 keeps fewer of them. With both, the same load took 10.8 seconds and 82 MB, and a search took about 4 ms. It found 7 of the true 10. Our test vectors were random numbers, which is about the hardest case for this kind of index, because there are no clusters for it to use. We haven't measured it on real embeddings yet.

no index float8, 16 neighbours default index 16 MB 82 MB 658 MB
The same 2,000 rows of 1536 dimensions with no index, with the two options, and with the defaults.

So the docs say to start with the full scan, add the index when the query's meta.duration_ms says to, and pass both options unless you've measured a reason not to.

Adding the index to a table that already had the 2,000 rows in it didn't go well. c3 cancels any statement that runs longer than 30 seconds, and building the index over 2,000 rows takes longer than that, so the CREATE INDEX failed with c3's timeout error. That part we expected.

What came next we didn't. vector_top_k on that index failed with index not found. Running the same CREATE INDEX again came back in a millisecond and reported success, and searches still found nothing.

libSQL keeps a vector index in three places: the index row in sqlite_master, a table of its own named <index>_shadow for the data, and a settings row in libsql_vector_meta_shadow. When c3 cancels the build, SQLite rolls the statement back, but the shadow table and the settings row can survive it. The next CREATE INDEX under that name finds the shadow table already there, takes the index as built, and fills nothing.

build finishes cancelled at 30 s sqlite_master d_idx_shadow libsql_vector_ meta_shadow index d_idx 2,000 rows d_idx settings rolled back still there, empty still there
Where libSQL keeps a vector index, and what a cancelled build leaves. The next CREATE INDEX finds the empty shadow table and builds nothing.

c3 2026.11.009 fixes it. When a vector CREATE INDEX fails, c3 drops whatever it left behind, and the timeout error says the index wasn't created and links to the docs. Before running one, c3 also clears shadow state that has no index row next to it, which repairs any database that hit this earlier. An index that existed before the statement is never touched.

To index a table that's already full, the docs walk through it: make a new table with the index already on it, copy the rows across in chunks small enough to finish well inside 30 seconds, and swap the names at the end.

Our export command hands back each database as a SQLite file that any SQLite tool opens. Stock SQLite doesn't know about vectors, though. It reads each one as a plain blob, has none of the vector_* functions, and refuses any insert into a table with a vector index. The export docs now say so: use a libSQL driver to keep searching, or drop the vector index before writing to the file with stock SQLite.

js-vec-search deploys with three commands: create the database, set your OpenAI key in the vault, and ribo deploy. The reference, with the index options, the chunked copy and the full list of functions, is at tissue.systems/docs/c3/vector-search.

/  , ,

Why our Stripe webhooks ignore the event body

We bill for Tissue Cloud and Tissue Mast through Stripe. The code that talks to Stripe is a small Rust service called atp, and it runs on a server of its own, away from the rest of our fleet, because it holds the Stripe key. When something changes in Stripe, a webhook tells atp, and atp tells our management API which plan the account is on.

This week we pulled the webhook handling out of atp into a crate called stripe-poke and put it on crates.io. This post is about why it's built the way it is, which mostly comes down to one early decision and three bugs we wrote in the first month anyway.

When we started on atp in July we read Stripe's webhook docs pretty closely, and a few lines in there ended up deciding most of the design. Stripe doesn't guarantee that events arrive in the order they were created. The same event can be delivered more than once. And if your endpoint doesn't answer with a 2xx, Stripe keeps retrying, with backoff, for up to three days in live mode.

The usual way to write a handler is to take the subscription out of the event body and save it. With those rules, that can go backwards. Say a customer upgrades and then cancels a minute later. The upgrade delivery fails because we happen to be in the middle of a deploy, the cancellation goes through fine, and a while later Stripe retries the upgrade. If we apply that body, a customer who cancelled is back on Pro, and nothing ever logged an error.

So atp doesn't apply the subscription in the body. It takes the customer id out of the event, asks Stripe for that customer's subscriptions, works out the plan from whatever comes back, and sends the whole result to the management API. We started calling the events pokes, as in someone rang the doorbell and you go and see who's there. The retried upgrade still arrives and still runs the handler, but by then Stripe says the subscription is cancelled, so that's what we send.

We got more out of this than we expected. Duplicates stop mattering, because running the handler twice sends the same answer twice. The hourly job that catches webhooks we never received is the same function, run for every customer, so there's only one copy of the billing logic to get right. A forged event can't put anyone on a plan either, because the plan only ever comes from what Stripe answers. It costs an extra Stripe API call per event, which at our volume is nothing.

There is one thing atp still reads from a body. The first checkout event is where it learns which Stripe customer belongs to which account, and that pairing comes from the event. It can only fill in a pairing that isn't there yet. If the account or the customer is already paired with something else, atp refuses and logs it.

Taking the event body out of the picture turned out to be the easy part. We got the order of the steps around it wrong three times.

The first version of atp wrote down each event id as soon as it arrived, so a repeat delivery could be answered with a quick 200. A security review of the billing server in August pointed out what that does when something fails. If the Stripe fetch errors, atp answers 500 and Stripe redelivers, which is what you want. But the id is already written down, so the redelivery looks like a duplicate, gets a 200, and the event is gone. The hourly job would have fixed the account eventually, but until then it would have been wrong, with nothing in the logs to say so. We changed it on August 9, a week before we turned on live checkout. atp checks the id when the event arrives and records it only after the handler succeeds. That means two copies of one event arriving together can both run, which with a poke handler costs one extra Stripe call.

A review of all the money paths a few days later found the other two. The first was in the push to the management API. atp puts each push in a local SQLite queue before trying to send it, so a crash in between doesn't lose it. If that queue write itself failed, we logged it and carried on, and the webhook still answered 200. Stripe thought we had it and we didn't. That case answers 500 so Stripe tries again.

The second was a timestamp. Every push carries an as_of time, and the management API ignores a push older than the one it already has, since retries mean an old push can always turn up late. We were stamping it after the Stripe fetch came back. Picture two fetches for the same customer. One starts first and is slow. The other starts a second later, sees newer data and comes back quickly. Stamped at the end, the slow one carries the later time, and the stale answer wins. atp stamps it when the fetch starts.

None of that code knew anything about our plans or prices, and we'd rather other people didn't have to find the same bugs, so we moved it into its own crate. stripe-poke has the signature check, a receiver that checks the event id first and records it last, the queue for whatever you derive, and SQLite versions of the event log and the queue. atp keeps the Stripe calls and the plan rules, and it's moving onto the crate with its own test suite unchanged.

A webhook route using it looks roughly like this:

let rx = Receiver { secret: &webhook_secret, tolerance_secs: 300, ledger: &ledger };
let outcome = rx
    .receive(signature_header, &body, stripe_poke::unix_now(), |event| async move {
        let Some(customer) = event.customer_id() else {
            return Ok(Handled::Ignored);
        };
        let as_of = stripe_poke::unix_now();
        let plan = plan_for(fetch_subscriptions(customer).await?);
        let payload = serde_json::json!({ "plan": plan, "as_of": as_of }).to_string();
        outbox::enqueue_and_deliver(&queue, &sink, customer, &payload, as_of).await?;
        Ok(Handled::Processed)
    })
    .await;

outcome.status() is what you answer Stripe with: 400 for a bad signature, 200 for a success or a duplicate, and 500 when your handler failed or the event log couldn't be read. Stripe retries anything that isn't a 2xx, so the 500 is what gets you another delivery.

The queue holds one payload per account, and a newer one replaces the older, because each one is the full state and not a change. The fiddly part is the ack. If a newer payload is queued while an older one is being delivered, the older one succeeding can't be allowed to delete the newer row, so a row is only removed if it still holds the payload that was sent. Failed deliveries back off from 30 seconds, doubling up to 15 minutes.

There's no HTTP in it. You call it from your own route, write the Sink that talks to your service, and run the retry pass and the hourly sweep from a timer you already have. It doesn't talk to Stripe either, so the fetch is your code with whatever Stripe client you like. The SQLite stores block, which is fine for a local file but worth knowing on a busy async runtime, and you can implement Ledger and Outbox yourself for a different database. If all you need is the signature check and typed events, async-stripe-webhook is a better fit.

The code is at github.com/tissue-systems/stripe-poke, under MIT or Apache 2.0, and cargo add stripe-poke gets you version 0.1.

/  , , , ,

Connect to the address you checked.

Tissue Mast fetches URLs our customers type in, from servers we run. We pulled the code that keeps those fetches off our own network into a Rust crate called ssrf-guard, and it's open source under MIT or Apache 2.0.

An uptime check is a customer telling one of our servers to open a connection somewhere. You save https://shop.example.com/health, and as often as every 30 seconds we fetch it from a few places and compare notes. If that fetch could reach 127.0.0.1:8080, or a private address on the same network, or the cloud metadata service on 169.254.169.254, then anyone with a free account could poke at things that were never meant to face the internet and read the answers off their dashboard. That's server-side request forgery, SSRF.

It's an old bug and it still pays out. The Capital One breach in 2019 was an SSRF through a misconfigured firewall to the metadata service, which handed over the instance's role credentials, which opened the S3 buckets. About a hundred million people. This year LMDeploy, an LLM inference server, shipped a bug of the same shape: a crafted image URL made it fetch whatever address it named. Someone was using it against the metadata service within a day of the advisory.

The fix sounds like one line: don't fetch private addresses. Getting that line to hold took most of a crate.

use ssrf_guard::{Fetcher, Policy};

let fetcher = Fetcher::new(Policy::default());
let resp = fetcher.get("https://example.com/").await?;
println!("{} from {:?}", resp.status(), resp.remote_addr());

// Refused before any connection is made.
let err = fetcher.get("http://169.254.169.254/latest/meta-data/").await;
assert!(matches!(err, Err(ssrf_guard::Error::Denied { .. })));

The first thing anyone writes is a check on the form. Parse the URL, resolve the host, refuse it if the address is private, save it otherwise. That stops someone typing http://192.168.7.9/ and nothing else. A name that resolves to a public address when it's saved can resolve to 10.1.2.3 an hour later, because whoever owns the DNS for it can change the record whenever they like. The check has to happen on every fetch, and it has to look at the address the socket connects to, not the text of the URL.

So the second version resolves the name right before the fetch, checks what came back, and hands the URL to the HTTP client. We tried that against reqwest with a resolver that counts its lookups. One check and one fetch made two lookups. The client resolves the name again on its own, and nothing ties its answer to the one you checked. A DNS server with a zero TTL can answer with a public address the first time and a private one the second. That's DNS rebinding, and it's not a beginner's mistake. Memos shipped exactly this as CVE-2026-71272 this year: the webhook sender checked the resolved addresses and then dialled the hostname. PraisonAI fixed the same bug in its webhooks, and the fix was bypassed with a rebinding server. The client's API pushes you into it. Every client wants a URL and does its own lookup.

ssrf-guard resolves the name once per hop, checks every address it got back, and builds the client with those addresses pinned to the name. The client has no resolver of its own. If it asks for a name that wasn't pinned, the lookup fails instead of quietly going to the system resolver. The rebinding test in the repo hands out 127.0.0.1 first and 10.1.2.3 after that. The first request lands on the checked address, and when the server redirects back to the same name, the second lookup gets 10.1.2.3 and the fetch stops there.

If a name comes back with one private address among public ones, the whole name is refused. Dropping the bad one and connecting to the rest would also be safe. But a public name that answers with 10.1.2.3 is either broken or someone testing us, and we'd rather the check fail and say why.

A careful check before the first request doesn't help if the client follows redirects on its own. We pointed a stock reqwest client at a local server that answers 302 Location: http://127.0.0.1:<port>/admin. It followed, got a 200 and handed us the body. An attacker doesn't need their URL to resolve anywhere interesting. A public server they control and a Location header are enough. GitLab had this reported against its GitHub integration in 2018, with the metadata service as the destination.

So redirects are followed by hand, three at most by default, and each one goes through the whole check again: resolve, refuse if any address is denied, pin, connect. A redirect to anything but http or https can't be followed, and a switch between the two counts as another origin. A redirect with a user name and password in it is refused too, since the client would turn those into an Authorization header for whatever host the redirect names.

Mast checks can carry headers and a body, because a health endpoint often wants an API key. That raised a second question: what travels with a redirect. With a 307 to another port, stock reqwest dropped Authorization but sent our X-Api-Key header and the JSON body on to the new origin. curl does much the same without --location-trusted. This is a hard thing to get right in a general-purpose client. urllib3, which most of Python's HTTP goes through, shipped CVE-2023-43804 in 2023 for keeping the Cookie header across a cross-origin redirect, and another the next year for Proxy-Authorization. For a monitor, an API key in a custom header is the normal case, and no stripping list is going to know its name.

ssrf-guard follows a cross-origin redirect with none of the request headers or body the caller set. Only the User-Agent travels. And once a chain has left the first origin it doesn't get them back, even if a later redirect points home again. The other origin chose where the request went next, so the chain isn't the caller's any more.

reqwest reads HTTP_PROXY and ALL_PROXY from the environment. We set HTTP_PROXY, asked a stock client for http://203.0.113.9/, and the proxy got GET http://203.0.113.9/ HTTP/1.1. A proxy resolves and connects for you, after your check, so nothing above applies to it. ssrf-guard turns proxies off.

The other is time. Once you follow redirects yourself it's natural to give each hop its own request with its own timeout. With a 10 second timeout and three redirects, a slow server can hold one check for 40 seconds. ssrf-guard has one budget for the whole chain, and it includes reading the body. In the test for it each hop takes 300 ms and the budget is 800 ms, so the third hop runs out of time.

Loopback and RFC 1918 are the obvious ones. Link-local is where the metadata services live. 100.64.0.0/10 is carrier-grade NAT, and it's also where some overlay networks put their machines. 0.0.0.0 connects to the local host on Linux. Then multicast, broadcast, the documentation ranges, the benchmarking range and everything from 240.0.0.0 up.

IPv6 doubles it, and it's where the address checkers get caught. ::ffff:10.1.2.3 is 10.1.2.3 as far as the kernel is concerned, and so is 64:ff9b::a01:203 behind a NAT64 gateway. Node's ip package, which a lot of things call to ask "is this public", said yes to ::ffff:127.0.0.1 and to 127.1, and got CVE-2024-29415 for it after an earlier fix hadn't covered them. ssrf-guard judges an IPv6 address with an IPv4 one inside it by the IPv4 address. 6to4, Teredo and the local-use NAT64 block are refused outright, because where those packets come out depends on a relay you don't run. Link-local, unique local and the documentation ranges are refused the same way they are in IPv4.

If your own servers have public addresses you don't want fetched, deny adds blocks on top of the list and always wins. allow goes the other way, for a test server on loopback or a private network you mean to reach.

let policy = Policy::builder()
    .deny("198.51.100.0/24".parse()?)   // your own servers
    .build();
let fetcher = Fetcher::new(policy);

// The same checks for something that isn't HTTP.
let stream = fetcher.connect("db.example.net", 5432).await?;

It only checks the addresses this process connects to. A NAT64 gateway, a VPN or a corporate proxy that routes public addresses somewhere private is invisible to it, and so is whatever a public server does with the request after it arrives. It doesn't restrict ports or match host names, it speaks HTTP/1.1 only, it needs a tokio runtime, and it builds a fresh client for every hop, which suits a prober and costs you on a hot path. A library shouldn't be your only layer either. A firewall rule for the process that fetches catches what a bug in the code lets through. What the library adds is a refused check that says why, instead of one that times out.

If you want to keep your own reqwest::Client, reqwest-ssrf-guard plugs into one through a DNS resolver and a redirect policy, and it can refuse ports and match host names. You wire up more of it yourself: a URL with a literal IP skips the resolver, so it needs that crate's URL check as well, and proxies are yours to turn off. http-acl-reqwest is the same idea with a fuller access list. url_jail does the address check without a client, from Python too. If the fetching happens in several languages, an egress proxy such as Stripe's Smokescreen puts the rule in one place.

Most of the bugs linked above were in Go, Python and Node services, because that's where the webhook senders and link previewers have been. Rust services are starting to do the same jobs. The code is at github.com/tissue-systems/ssrf-guard, and cargo add ssrf-guard gets you version 0.1.

/  , , , ,

Where the packets stopped.

On paid plans, when a Tissue Mast check fails, the probe that saw it fail traces the path to the target. It does that in its own process, over an ICMP socket that doesn't need root. We've pulled the code out into a Rust crate called hoptrace and open-sourced it under MIT or Apache 2.0.

"Your site is down" starts a conversation, and the next question is always where. Your server, your host's network, or something in between. mtr answers that well. It sends packets with a rising TTL, each router that drops one sends back a Time Exceeded, and after a few passes you have every hop with its loss and latency. When one of our probes sees a check fail, we want that table for the address it couldn't reach, taken at the moment it couldn't reach it.

We could have shelled out to mtr. On Linux, mtr 0.93 and later can trace without privilege, using the same kind of socket this crate does. But that's a binary to install on every vantage, a child process for every failing check, and a text report to parse back into numbers. On macOS mtr needs root. We wanted a function call that returns a list of hops.

let trace = hoptrace::Tracer::new().trace("1.1.1.1".parse()?)?;
for hop in &trace.hops {
    match (hop.addr, hop.avg) {
        (Some(addr), Some(avg)) => println!("{:>2}  {addr}  {:.1}% loss  {avg:?}", hop.ttl, hop.loss()),
        _ => println!("{:>2}  ???", hop.ttl),
    }
}

It's SOCK_DGRAM with IPPROTO_ICMP, usually called a ping socket. macOS lets any process open one. Linux does once the process's group is in net.ipv4.ping_group_range, which most distributions set. It sends only echo requests, from the host's own address, so there's nothing to spoof with it. You can still set the TTL, and a trace needs nothing else.

Sending works the same on both systems. Reading the answers doesn't, and most of the work was finding out how each kernel behaves.

macOS hands every ICMP message to the socket through recvfrom, Time Exceeded included, with the IPv4 header still on the front. The Time Exceeded quotes the start of the request that expired, and the request's sequence number says which TTL it went out with. But every ICMP socket on the machine gets every one of those messages, so two traces running at once each see the other's routers. Each trace picks a random identifier and sequence base and keeps only messages that quote both. RFC 792 asks a router to quote just the first 8 bytes of the request. Most quote more, and when the quote reaches the trace's random token, that has to match too.

Linux gives a ping socket only its own echo replies, and the kernel swaps your identifier for one of its own. Time Exceeded never shows up on the normal queue. You set IP_RECVERR, and the errors land on the socket's error queue, which you read with recvmsg(MSG_ERRQUEUE). What comes back is the router's quote of your request, with a sock_extended_err in the control data and the router's address packed in right after that struct as the "offender". socket2 doesn't wrap any of this, so it's about a hundred lines of libc.

There's a second Linux catch. With IP_RECVERR on, each ICMP error also leaves an error pending on the socket, and the next sendto returns that error instead of sending. Answers arriving while a pass is still sending hit it in a few traces out of every few hundred in the test that provokes it. A failed send clears the pending error, so hoptrace retries once, and counts a request that still won't go as lost.

The Linux side is tested against three network namespaces, a client, a router and a target, so the error queue sees real Time Exceeded and Unreachable messages over IPv4 and IPv6. The macOS side has been run over IPv4 on real paths. IPv6 there has only been run to loopback.

Routers and targets rate-limit the ICMP they send. Until the target answers, every TTL past it reaches the target, so thirty requests fired at once would lose answers to the target's limit rather than to the path. The requests in a pass go out 5 ms apart, and once a pass has found the target, later passes stop there.

With equal-cost multipath, one TTL can land on a router in one pass and on the target in the next. The target's own reply wins, so the hop it answered at is the end of the path.

If the target never answers, the trace drops the silent hops after the last one that did. They say nothing about where the path goes. If a router says Unreachable, the path ends there instead.

Each answer is timed as soon as it's read, from a poll(2) wakeup, in user space. A loaded host adds its scheduling delay to the numbers. Loopback comes out at about 0.1 ms on an idle Mac.

$ cargo run --example report -- -c 5 1.1.1.1      # addresses changed
HOST: 1.1.1.1 (1.1.1.1)
                                              Loss%  Snt     Avg    Best    Wrst
  1.|-- 192.168.1.1                            0.0%    5     3.0     2.6     3.4
  2.|-- 198.51.100.17                          0.0%    5    12.8    11.8    13.4
  3.|-- 198.51.100.130                         0.0%    5    14.0    12.1    18.8
  ...
  8.|-- 1.1.1.1                                0.0%    5    16.1    12.8    21.0

The kernel's default for net.ipv4.ping_group_range is 1 0, an empty range. systemd 243 and later sets it to every group, so most current distributions work out of the box, but slim container images and older systems often don't. When the kernel refuses, trace returns Error::NotPermitted, and its message names the sysctl. hoptrace::permitted() asks the same question without tracing anything. The first line below opens it until the next boot, the second keeps it open:

sudo sysctl -w net.ipv4.ping_group_range="0 2147483647"
echo 'net.ipv4.ping_group_range = 0 2147483647' | sudo tee /etc/sysctl.d/60-ping.conf

If you can install a binary, mtr does more. It can probe with TCP and UDP, which gets past firewalls that drop echo requests, and it looks up names and AS numbers. trippy does all of that too, and with a raw socket it handles ECMP paths properly. It also has a library engine and an unprivileged mode, on macOS only and without the ECMP strategies. It's a much bigger dependency. If you only want to know whether one host answers and how fast, surge-ping is a good async ping on the same kind of socket.

hoptrace sends only ICMP echo, does no lookups and has no live view. It doesn't build for FreeBSD or Windows, which don't have the socket. It's 0.1, it blocks (run it on a blocking thread from async code), it needs Rust 1.70, and its only dependencies are socket2 and libc. Bug reports and pull requests go to github.com/tissue-systems/hoptrace.

/  , ,

Your on-call schedule, in Terraform.

Tissue Mast has a Terraform provider. Channels, heartbeats, rotations, overrides and escalation policies can live in the same repo as the services they watch, and they change through the same pull requests.

It's tissue-systems/tissue, version 0.1.0, on both the Terraform registry and the OpenTofu registry. Version 0.1.0 manages Mast and nothing else. It can't deploy a Cell or create a database or a bucket on Tissue Cloud. The provider is called tissue and not mast because Tissue Cloud resources will go into the same provider, and they're coming soon.

If your team doesn't use Terraform, you don't need it for any of this. A mast.toml and ribo mast apply keep the same setup in git without a state file, and alert sources as code covers both and when to pick which. Just don't point both at the same account, because they'll keep undoing each other's changes.

Terraform lets you write down the infrastructure you want in text files and then makes reality match them. You describe a DNS record, a bucket or a database in HCL, its configuration language, run terraform plan, and it shows you exactly what it would create, change or delete. If that looks right, terraform apply does it.

It remembers what it made in a state file, so the next plan only shows the difference between what's in your files and what's out there. If you change one line, the plan shows one change. If you delete a block, the plan deletes the thing it described.

Terraform itself doesn't know about any particular service. That's the job of providers, which are plugins that translate resource blocks into API calls. There are providers for AWS, GitHub, DNS hosts and thousands of other things, and Mast has one too.

Most of why people like it has to do with working in a team. The config sits in git, so every change has an author, a review and a history. When you want to know why the backup alert stopped paging the database team in March, you run git log.

Terraform was open source under the MPL until August 2023, when HashiCorp moved it to the Business Source License. A group of companies that build on it forked the last MPL release and called the fork OpenTofu. It's run by the Linux Foundation. You type tofu instead of terraform, and your existing files work as they are.

For a provider, the two are close to interchangeable. Both talk to providers over the same plugin protocol, so it's one binary either way. The difference is where they download it from: Terraform looks in registry.terraform.io, OpenTofu in registry.opentofu.org. We're listed in both, so the source = "tissue-systems/tissue" line below works whichever one you run. Swap terraform for tofu in any command in this post and it does the same thing.

Five resources:

  • tissue_mast_channel, a URL that turns what's sent to it into notifications on your team's phones
  • tissue_mast_heartbeat, a channel that expects a beat on a schedule and pages when one is late
  • tissue_mast_rotation, who's on call and when it hands over
  • tissue_mast_override, someone covering someone else for a few days
  • tissue_mast_policy, who gets paged next when nobody answers

And four data sources for reading things: tissue_mast_person finds a person on the account by email, tissue_mast_people lists all of them, tissue_mast_rotation tells you who's on call right now, and tissue_mast_channel hands you the URL of a channel that was made somewhere else.

A few settings belong to the phone and not to the API, and the provider leaves them alone. Letting a channel send at page priority, the one that gets through Do Not Disturb, can only be switched on in the Mast app on the owner's phone. So the provider makes channels at loud at most and reads back whatever the app holds. Any argument you leave out of a block follows the app too. If people like to set their own quiet hours or pick a sound on their phone, leave those out of the config and Terraform won't undo them on the next apply.

In the dashboard, make an API token with the mast:read and mast:write scopes and put it in TISSUE_TOKEN. You can put it in the provider block instead, but then it ends up in your config and your plan output.

terraform {
  required_providers {
    tissue = {
      source  = "tissue-systems/tissue"
      version = "~> 0.1"
    }
  }
}

provider "tissue" {} # reads TISSUE_TOKEN
$ export TISSUE_TOKEN=tok_...
$ terraform init
$ terraform plan

Ana and Ben take turns, a week each, handing over Monday at 09:00 Berlin time. People are looked up by email, so nobody has to go and find a user id:

data "tissue_mast_person" "ana" {
  email = "ana@example.com"
}

data "tissue_mast_person" "ben" {
  email = "ben@example.com"
}

resource "tissue_mast_rotation" "primary" {
  name         = "primary"
  handoff      = "weekly"
  handoff_day  = 0 # Monday
  handoff_time = "09:00"
  tz           = "Europe/Berlin"
  order        = [data.tissue_mast_person.ana.user_id, data.tissue_mast_person.ben.user_id]
}

Whoever is first in order is on call from the day the rotation is made. handoff can also be daily, biweekly, or custom with a shift length in hours.

This policy pages whoever's on call. If they haven't acknowledged after five minutes it pages the other person, and after fifteen it pages everyone. An incident nobody touches starts over every half hour.

resource "tissue_mast_policy" "default" {
  name              = "default"
  repeat_every_secs = 1800

  steps = [
    { target = "oncall", rotation_id = tissue_mast_rotation.primary.id, priority = "page" },
    { target = "next", rotation_id = tissue_mast_rotation.primary.id, priority = "page", after_secs = 300 },
    { target = "everyone", priority = "page", after_secs = 900 },
  ]
}

after_secs counts from the step before, not from the start.

A channel for deploy failures, quiet overnight, using that policy:

resource "tissue_mast_channel" "deploys" {
  name             = "deploys"
  default_priority = "loud"
  sound            = "chirp"

  # Quiet from 22:00 to 07:00 Berlin time, in minutes past midnight.
  quiet_start = 1320
  quiet_end   = 420
  quiet_tz    = "Europe/Berlin"

  policy_id = tissue_mast_policy.default.id
}

The channel's URL comes back as an attribute. It carries the key, so anyone holding it can send to the channel, and the provider marks it sensitive. It's still a normal value inside Terraform, though, which means you can hand it straight to whatever does the sending instead of copying it out of the app. With the GitHub provider, for example, it becomes an Actions secret:

resource "github_actions_secret" "mast" {
  repository      = "api"
  secret_name     = "MAST_DEPLOYS_URL"
  plaintext_value = tissue_mast_channel.deploys.url
}

And a failing deploy job sends to it:

- name: Tell Mast
  if: failure()
  run: curl -fsS -d "deploy of ${{ github.sha }} failed" "$MAST_DEPLOYS_URL"
  env:
    MAST_DEPLOYS_URL: ${{ secrets.MAST_DEPLOYS_URL }}

Like every sensitive value, the URL is in your Terraform state in plain text. Keep state somewhere you'd keep a password.

A heartbeat is for jobs that are supposed to report in, like backups and cron jobs. It pages when the report doesn't arrive in time. This one expects the nightly backup to check in after it starts at 03:00, and pages if nothing has arrived by 03:30:

resource "tissue_mast_heartbeat" "backup" {
  name        = "nightly-backup"
  schedule    = "0 3 * * *"
  schedule_tz = "America/Los_Angeles"
  grace_secs  = 1800
  host        = "db1"
}

The backup script requests the heartbeat's URL as its last step. For a worker that should check in every five minutes, use period_secs instead of a schedule, and fail_threshold if one missed beat isn't worth waking anyone for:

resource "tissue_mast_heartbeat" "queue" {
  name           = "queue-worker"
  period_secs    = 300
  grace_secs     = 120
  fail_threshold = 2
}

Ben covers Ana over Christmas. That's a small PR someone can review, and you delete the block in January:

resource "tissue_mast_override" "holiday" {
  rotation_id    = tissue_mast_rotation.primary.id
  user_id        = data.tissue_mast_person.ben.user_id
  covers_user_id = data.tissue_mast_person.ana.user_id
  start          = "2026-12-24"
  end            = "2026-12-26"
}

If you'd rather everyone on the account was in one rotation without listing them, tissue_mast_people does that:

data "tissue_mast_people" "all" {}

resource "tissue_mast_rotation" "everyone" {
  name  = "everyone"
  order = data.tissue_mast_people.all.people[*].user_id
}

You don't have to start over. Every resource can be imported, and channels, heartbeats, rotations and policies can be imported by name:

$ terraform import tissue_mast_channel.deploys deploys
$ terraform import tissue_mast_rotation.primary primary
$ terraform import tissue_mast_override.holiday primary/ov_51c7a3e0d2b94f18

Overrides take the rotation and the override id with a slash between them. On Terraform 1.5 or later, or OpenTofu 1.6 or later, you can skip writing the blocks yourself. Put import blocks in a file and let plan write the config:

import {
  to = tissue_mast_channel.deploys
  id = "deploys"
}
$ terraform plan -generate-config-out=mast.tf

Check what it wrote and trim it. The generated blocks spell out every argument, including the ones you'd rather leave to the app.

Opsgenie shuts down on 5 April 2027, and a lot of Opsgenie setups are managed through its Terraform provider. Moving to a pager without one means going back to clicking, which is a big part of why we built this one.

The Mast importer, in the web app or as ribo mast import opsgenie, reads your Opsgenie account and builds the same schedules, overrides and escalations in Mast. When the import in the web app finishes, it also gives you an import block for everything it made, with Copy and Download buttons, so you don't have to look up any ids. The same blocks from ribo are coming soon. The Opsgenie guide has the rest.

We wrote the provider by hand in Go instead of generating it from our API spec. Generated providers tend to show a diff on every plan for fields the server fills in or tidies up. After a few weeks of that, people stop reading their plans. The tests run real Terraform against a fake of the Mast API that fills in, trims and rewrites fields the same way the server does, so they never touch anyone's account.

Mast probes and status pages aren't in 0.1.0, and neither is anything for Tissue Cloud. Both are coming soon. Until then, probes and status pages are set up in the Mast app. The source is on GitHub at tissue-systems/terraform-provider-tissue, and the full reference for every argument is on the Terraform registry.

/  , , , ,

Shipping the WAL to the next machine.

Every SQL database on Tissue Cloud has a copy on another edge, a few frames behind the original. The code that does it is a Rust crate called walship, and we've open-sourced it.

Each c3 database lives on one edge. That's where its writes go, and until September it was also the only place its data was current. We kept warm copies on the other edge, refreshed every one to fifteen minutes depending on size, so losing that machine meant losing up to fifteen minutes of writes. For a sign-in database, or a sensor log that gets a row every ten seconds, that's a lot.

Since September each database also has a replica on the other edge that trails the original by about one batch of WAL frames. It's a normal SQLite file, and promoting it is one call. The code behind it started inside c3, our database service. We've pulled it out into a crate, walship, and put it on crates.io under MIT or Apache 2.0.

WAL stands for write-ahead log. In WAL mode, a commit doesn't touch the database file. SQLite appends the changed pages to a second file next to it, orders.db-wal beside orders.db, and readers look in that log before the main file. Every so often a checkpoint copies the logged pages back into the main file and the log starts over. Every change goes through the log first, so if you copy the log to another machine as it grows, you can keep a second copy of the database current there.

let shipper = Shipper::builder("/var/lib/app/db", "http://standby.internal:7350")
    .token(token)
    .start(tokio::runtime::Handle::current())?;
shipper.track("orders");
        // after a commit
shipper.wake("orders");

We have a lot of small databases, and one process creates, restores and drops them while it runs. We wanted a copy of each on another machine that we could open in seconds, with nothing between the two machines except HTTP.

Litestream came closest. It streams the WAL to object storage, and you get a database back by restoring it from there, which takes as long as the download. It's also configured per database and runs as its own process, watching files another process owns. When c3 swaps a file out from under it during a restore, it loses its place. c3 is the only thing that knows when a database is created, replaced or dropped, so that's where replication had to live.

LiteFS puts a FUSE filesystem under the database and needs a lease service to pick a primary. libSQL has replication too, but both of its forms put a server in the middle: embedded replicas pull from a sqld primary, and Turso's sync talks to Turso Cloud. We didn't want another moving part on the write path.

If you want backups or point-in-time restore, Litestream is the better tool, and it works with stock SQLite from any language. walship keeps only the latest state. It's for a Rust program on libSQL that wants a hot standby.

Each entry in the WAL is called a frame. A frame holds one changed page of the database, the full page and not a diff, behind a 24-byte header. A transaction is a run of frames, and its last frame is marked as a commit. A frame isn't SQL, just the bytes of a page and its page number, so the other side doesn't have to run any queries. It writes the pages into its own WAL in the same order.

Upstream SQLite has no API for reading frames out of a WAL or writing them into another one. libSQL, the fork of SQLite's C code that takes outside contributions, adds a few: libsql_wal_frame_count, libsql_wal_get_frame, and an insert session with libsql_wal_insert_begin, _frame and _end. walship is built on those.

The shipper reads committed frames past the last one the peer acknowledged and posts them in batches of up to 512, which is 2 MiB with 4 KiB pages. The receiver writes them into its own copy through an insert session and answers with its committed frame count. After any error, the next send starts from that count. Both sides keep their position on disk, so a restart on either end picks up where it stopped.

A batch can end halfway through a transaction. The receiver keeps its insert session open until the commit frame arrives, so a reader on the replica never sees half a transaction. If the receiver restarts with a session open, libSQL throws the uncommitted frames away and the shipper resends from the last commit.

Frames are page images, so they only mean something on top of the exact file they were written against. walship replicates in generations. A generation starts with a base. SQLite has a few checkpoint modes, and TRUNCATE is the thorough one: it waits for writers, copies every frame into the main file, and cuts the -wal file down to zero bytes. Once it finishes, the main file holds the whole database and the log is empty. The primary runs one and then sends its main file byte for byte. Frames written after that are numbered from 1.

That means checkpoints can't just happen whenever SQLite feels like it. If frames get folded into the main file before they're shipped, the replica can't get them anymore and needs a whole new base. So checkpoints are off on every connection to a shipped database, and the shipper decides when to fold. Once a database has gone quiet with more than 1,000 frames in its WAL, all of them acknowledged, it runs a PASSIVE checkpoint. That's the gentle mode: it copies whatever frames it can without waiting for anyone and leaves the WAL file where it is. It only counts the fold if the checkpoint took exactly the acknowledged frames. If a writer got in first, those frames get shipped and the fold waits for the next quiet moment.

After a full fold, SQLite restarts the log at frame 1 on the next write and puts a new salt in the WAL header. The salt is a random number that changes every time the log starts over, and it's how SQLite tells a current frame from a leftover one. The shipper treats that as the start of the next generation, and the replica checkpoints its own copy when the first frames of it arrive. The same salt check catches anything that changes the WAL behind the shipper's back, like a checkpoint from another process. A salt it didn't expect, or a frame count lower than the acknowledged one, and it sends a fresh base.

If the peer is down, the WAL keeps growing while the shipper retries. At 50,000 waiting frames, about 200 MiB, it checkpoints anyway and sends a full base when the peer comes back.

Most of the time on this went into finding out how the WAL functions behave, because the docs don't say. We wrote each finding down as a test, so a libSQL upgrade that changes one fails the build. A few of them would have cost us data.

libsql_wal_frame_count takes the WAL write lock without waiting, so it returns SQLITE_BUSY whenever any writer has a transaction open. It also returns the connection's cached copy of the WAL index, and SELECT 1 doesn't refresh it. In our tests a commit moved the WAL from 3 frames to 7, and the shipper's connection still said 3 after a SELECT 1. Reading sqlite_master fixes it, so walship does that first.

Inserting a frame with a gap in front of it doesn't fail. If the replica has 4,202 frames and you insert frame 4,206, libSQL quietly writes it as 4,203. We tested this by skipping three frames of a transaction and sending the rest. Every call returned OK, PRAGMA quick_check on the replica said ok, and the replica had 33,977 rows where the primary had 36,977. The receiver checks that every batch starts exactly one past its own count, because libSQL won't.

libSQL also accepts frames onto a file they weren't written against. We tried building a base with VACUUM INTO instead of a byte copy. VACUUM INTO renumbers pages, so every frame shipped after it lands on the wrong page. That replica passed PRAGMA integrity_check and was missing a fifth of its rows. This is why a base is the file itself, copied right after a TRUNCATE.

Some of it works in your favour. Inserted frames go through the normal append path, so the replica's WAL has its own salts and checksums and recovers from a crash like any other WAL. And an insert session that ends without a commit frame leaves nothing visible behind, which is what makes mid-transaction batches safe.

The first was bad. To send a base, the first version opened the main database file with an ordinary read-only open, read it, and closed it. On Linux, closing any descriptor to a file drops every POSIX lock the process holds on that file, including the shared lock SQLite keeps on every database in WAL mode. SQLite tracks its own locks in a table that still said we held it, so nothing inside c3 noticed. Three hours later the hourly backup ran. It opened each database read-write, found no lock in its way, and checkpointed and deleted the WAL of databases that were in the middle of writes. Five busy databases were damaged before we turned shipping off. We restored them from backup. Since then, walship reads the main file through the handle SQLite already has open (SQLITE_FCNTL_FILE_POINTER and the file's own xRead), so there's no extra descriptor to close. The test for it has to fork a child and probe the lock from outside, because a process can't see its own lost lock any better than SQLite could.

The second was quieter. Promoting a replica moves its file into the primary's data directory with rename. Under systemd, each ReadWritePaths entry is its own bind mount, so the two directories were on different mount points and every rename failed with EXDEV. Our failover script falls back to the older warm copy when a promotion fails, so a real failover would have worked and quietly lost up to fifteen minutes of writes. We found it on the first promotion drill. walship now copies, syncs and deletes when a rename says EXDEV. On the next drill we promoted a 256 MB sensor database with 1.96 million rows while it was being written to, and the replica had every row up to the moment the primary stopped.

One trap is waiting for anyone who adopts walship. Your program has to open its databases through the same libSQL build walship links, either with the libsql crate or with libsql-ffi on the same 0.9 line. A process with two copies of SQLite has two sets of POSIX locks that can't see each other, and that corrupts databases.

Cargo won't catch it for you. libsqlite3-sys, the crate under rusqlite and sqlx, declares links = "sqlite3", so Cargo refuses two versions of it. libsql-ffi declares no links key, so a second version of it, or libsqlite3-sys next to it, builds without a word. The README has a short shell check that fails when Cargo.lock holds more than one. Put it in CI.

walship doesn't notice that a machine died and doesn't decide when to promote. On Tissue Cloud that's a separate decider that checks with the nameservers before it acts. In walship it's one call, and when to make it is up to you:

match receiver.take("orders", Path::new("/var/lib/app/db/orders.db"))? {
    Take::Moved { generation, frames, bytes } => { /* open it */ }
    Take::Busy => { /* a reader held off the checkpoint, try again */ }
    Take::Absent => { /* no replica by that name */ }
}

Each database gets one replica. There's no history, so no point-in-time restore. Data goes over the wire uncompressed and unencrypted, so run it over TLS or a private network; ours goes over WireGuard. A base is a full copy of the file, and the receiver refuses bases over 8 GiB unless you raise the limit. Any number of nodes can each own some of the databases and replicate to a peer, in a ring or to one standby.

On a laptop, with a writer, the shipper and a reader on the replica all running over a simulated 56 ms link, the writer did 259 transactions a second and the replica trailed by 42 frames on average and 55 at most. The reader ran quick_check 929 times during the run and never got a failure, and at the end a checksum of every row matched on both sides. That run is examples/stress.rs in the repo.

[dependencies]
walship = "0.1"

It's 0.1, and the API will change before 1.0. The libSQL behaviours above are written up in more detail in the README and pinned by tests in src/wal.rs. Bug reports and pull requests go to github.com/tissue-systems/walship.

/  , ,

A tarball we never build.

A Cell export downloads as one .tar.zst. It tells you its exact size before the first byte, and you can resume it if the connection drops. The file itself doesn't exist anywhere. This is how that works.

An explant is a full copy of a Cell, for when you want to keep one yourself or take it somewhere else. It has the Cell's source and config, every c3 database it uses, and every object in its g7 buckets. The layout is a BagIt bag. BagIt is a plain directory format that libraries and archives use for long-term copies (it's RFC 8493): your files go under data/, and a manifest next to them lists a SHA-256 for each one, so you can check years later that nothing changed.

ribo explant export downloads the bag file by file. Plenty of people don't want a tool, though. They want one file they can fetch with curl or a browser and put on a backup disk. So there's also a single URL that returns the whole bag as one .tar.zst:

curl -C - -o orders-api.tar.zst -H "Authorization: Bearer $TISSUE_TOKEN" \
  https://api.tissue.systems/v1/cells/orders-api/explant/$ID/download
zstd -d < orders-api.tar.zst | tar -x

The response tells curl exactly how many bytes are coming, before it sends any of them. If the connection dies at 3.1 GB, running the same command again picks up at 3.1 GB. And the .tar.zst isn't stored anywhere. Not on the edge, not in object storage, not in a temp directory. The edge puts it together as it streams it out, from pieces that were saved when the export was built plus a few bytes it makes up per request.

Getting all three of those at once took some care, and most of it comes down to one number.

An HTTP response can say how long it is in a Content-Length header, or it can skip that and send the body in chunks, with the client finding out where it ends when it gets there. For a web page it hardly matters. For a 6 GB export it matters in a few ways.

The obvious one is progress. With a length, a browser shows "2.1 of 6.0 GB, 4 minutes left". Without one it shows "2.1 GB of unknown" and you have no idea whether to wait or go get lunch. You also can't check up front whether the file fits on the disk you're saving it to.

The bigger one is resuming. When you run curl -C - on a half-finished file, curl looks at how many bytes are already on disk, say N, and sends Range: bytes=N-, which means "everything from byte N to the end". A server that supports this answers 206 Partial Content with a header like Content-Range: bytes 3100000000-5999999999/6000000000. That header carries the total size, so the server has to know it. And underneath that there's a stricter requirement: byte N of the second response has to be exactly the byte that would have been at position N in the first one. If the server assembled the file a little differently the second time, curl would glue the first half of one file onto the second half of another. Nothing would complain until you tried to decompress it, possibly hours later.

The last one is honesty. A client trusts Content-Length. If we promise more bytes than we send, the download hangs until it times out. If we promise fewer, the client stops early and you get a truncated archive that looks finished. The number has to be right, to the byte, every time.

tar is an old and very simple archive format. A tar file is a flat list: a 512-byte header with a file's name, size and date, then the file's bytes, then zeros to pad up to the next multiple of 512, then the next header, and so on. Two blocks of 512 zero bytes mark the end. tar doesn't compress anything. You pipe it through a compressor, which is where .tar.gz and .tar.zst come from. zstd is the compressor here: it's fast in both directions and the zstd tool is easy to get on any system.

The usual recipe is tar -c ... | zstd > out.tar.zst, and it breaks everything above. You only learn the compressed size when the compressor is done. And a compressor works by noticing repeats and writing "copy those bytes from earlier" instead of the bytes, so compressed byte N depends on everything before it. To start sending from the middle you'd have to compress the whole thing again from the start, and hope it comes out identical.

That leaves two easy options. One is to build the .tar.zst once and store it, which doubles the storage for every export (the bag's files are stored too) and adds one more large thing to clean up when the export expires after seven days. The other is to compress on every request, which puts the CPU cost on the edge serving the download, the same machine that serves Cells, and pays it again for every download and every resume. The length still isn't known up front.

We wanted neither. What we wanted was one file that plain zstd and tar can read, an exact length before the first byte, no extra stored copy, and no compression work at download time.

A zstd file is made of frames. A frame is a self-contained unit: a short header, then blocks of data, and a decoder can turn it back into the original bytes without looking at anything outside it. The format (RFC 8878) allows any number of frames one after another, and a decoder just outputs each frame's content in order. So for any two inputs:

cat a.zst b.zst | zstd -d   # same bytes as: cat a b

That means the tarball doesn't have to be one compressed stream. We can cut the tar stream into pieces, make each piece its own frame, and line the frames up. The result is a valid .tar.zst, and a decoder can't tell it apart from one made the usual way. tar gives us the cut points for free: every header, every file's content, every bit of padding and the trailer at the end is its own piece.

header      521 B     made per request
cell.js     stored    compressed at build time
padding     ≤ 520 B   made per request
header      521 B     made per request
orders.db   part 0    32 MiB in, compressed at build time
orders.db   part 1    32 MiB in, compressed at build time
orders.db   part 2    the rest
padding     ≤ 520 B   made per request
trailer     1033 B    made per request

The download is those pieces in that order, with nothing in between. Once each piece is its own frame, the two kinds can be handled differently. File content is almost all of the bytes, so it gets compressed, once, when the export is built. Headers, padding and the trailer are tiny, so they get made fresh on each request in a way whose size we can work out with arithmetic.

When an export is built, each file is cut into parts of 32 MiB. Each part is compressed into one complete zstd frame and saved as its own object in g7. Why 32 MiB: g7 caps a single upload at 100 MiB, and compressed output can come out slightly bigger than its input when the data doesn't compress, so 32 MiB leaves plenty of room. Smaller parts also mean a resume can start in the right part instead of reading a huge object from the beginning.

We compress at level 3, which is zstd's default. Level 19 takes roughly ten times the CPU for a few percent smaller output on mixed data like this, and the build runs on an edge that's also serving traffic.

Some data isn't worth compressing at all. A JPEG or a zip file is already compressed, and running zstd over it saves nothing and makes whoever extracts it do the decompression work anyway. So a part is stored as-is (still wrapped in a zstd frame, more on that below) if its content type is an image, video, audio, an archive or a web font. SVG is the exception, since it's text and compresses like text. Content types lie, though: a .bin might really be a JPEG. So everything else gets a quick test first. We compress the first 128 KiB, and if that saves less than 5%, the part is stored as-is.

For every part, the build writes its original size, its stored size and its hash into a file called layout.json. That file is what the download works from.

The small pieces are generated on every request, and we don't compress them. They're too small for it to help, but the real reason is that compressed output has whatever size the compressor decides on. We'd have to run the compressor just to learn the length, and the whole point is to know the length without doing that.

zstd has a way to put bytes in a frame without compressing them: a raw block, which just says "the next n bytes are literal". We build these frames by hand. Here's the whole format:

28 B5 2F FD        magic number: "this is a zstd frame"
00                 frame header: no checksum, no content size given
38                 window size: 128 KiB (explained below)
3 bytes            block header: block size n, type Raw, last-block flag
...n bytes...      the content, unchanged

A raw block can hold at most 128 KiB, so longer content takes several blocks, each with its own 3-byte header. That makes the size of a raw frame a function of the content length and nothing else:

pub fn raw_frame_len(n: u64) -> u64 {
    if n == 0 { return 0; }
    FRAME_PREFIX_LEN + n.div_ceil(MAX_RAW_BLOCK) * 3 + n
}

Plugging in real numbers: a tar header frame is always 6 + 3 + 512 = 521 bytes. A file's padding is 512 - size % 512 zero bytes (none if the size is already a multiple of 512), so its frame length follows from the file size we saved in layout.json. The trailer is 1024 zeros in a 1033-byte frame. Files stored as-is at build time use the same raw frames, which is why "stored as-is" still produces valid zstd.

That 38 byte took us one wrong turn. When zstd compresses, it refers back to bytes it has already seen, and the window is how far back it's allowed to look. A decoder has to set aside that much memory before it starts, so every frame declares its window size up front, and decoders refuse frames that ask for more than they're willing to give.

zstd also lets a frame skip the window byte and set a flag instead, which means "the window is the size of this whole frame". It's one byte shorter, and for a 512-byte tar header it's harmless. For a raw frame around a 32 MiB part, it asks the decoder for 32 MiB of window, and with larger content it gets worse. Past the decoder's limit, the zstd tool stops and tells you to pass --long or --memory, which reads exactly like a corrupt archive.

Raw blocks don't refer back to anything, so the window only has to be big enough to hold one block. 128 KiB is the smallest window that allows a full-size block, so every raw frame declares exactly that. With it, every frame decodes on a default decoder however big the file is.

Every generated piece has a size from a formula and every stored piece has a size written down in layout.json. So Content-Length is a sum:

pub fn content_length(&self) -> u64 {
    let per_member: u64 = self.members.iter().map(|m| {
        zframe::raw_frame_len(tar::BLOCK) as u64
            + m.stored_bytes()
            + zframe::raw_frame_len(tar::padding_len(m.bytes)) as u64
    }).sum();
    per_member + zframe::raw_frame_len(tar::TRAILER_LEN) as u64
}

Answering it doesn't open a single object. The same layout also gives the download its list of pieces in order: each one is either a few bytes made on the spot (a header, padding, the trailer) or the key of a stored object along with its size.

This only works if the tar header we generate at download time is exactly the header the length calculation assumed, byte for byte, every time. A tar library would fill in things like the current user and file permissions from wherever it runs, so we write the headers ourselves in the POSIX ustar format, using only the file's path, size and modification time from layout.json. Permissions are always 0644 and the owner is always uid 0, tissue. Nothing in the header depends on which edge serves it or when.

ustar has one limit that bites in practice. A file name gets 100 bytes, plus a 155-byte prefix field for the leading directories, so about 255 bytes in total, split at a /. Paths in an export look like data/g7/<bucket>/<key>, and the key is whatever the customer chose, so some don't fit. Those objects are left out of the export, and the export says so. We don't shorten the name, because a shortened name would extract as a different file, maybe one that overwrites another. And we check at build time, not at download time. If we only found out when building the header for a download, the export would already be marked ready, and every download of it would fail partway through.

When curl comes back with Range: bytes=N-, every piece's length is known, so finding byte N is a walk down the list. Every piece that ends before N is skipped, and a skipped stored piece is never fetched from g7. The piece that contains N starts partway in: the edge slices the generated bytes, or asks g7 for the stored object starting at the right offset. Every piece after that goes out in full.

The answer is a 206 with a Content-Range header. If N is past the end, it's a 416 Range Not Satisfiable, which is how curl learns the file is already complete.

Resuming is safe because an export never changes once it's ready. The export ID in the URL names one fixed set of stored parts and one layout.json, so byte N on Tuesday is byte N on Thursday.

We only honour the open-ended bytes=N- form, because that's what download tools send to resume. Other forms exist: bytes=100-199 for a specific slice, bytes=-500 for the last 500 bytes, or several ranges at once. Those get the whole file with a 200. HTTP lets a server ignore any Range it doesn't want to serve, every client handles it, and it beats serving the wrong bytes under a 206.

Since nothing gets compressed at download time, all the edge does per request is copy bytes from g7 to the socket. It holds a few kilobytes at a time, however big the export is.

Everything above rests on one promise: the length we announce and the bytes we send agree. The test suite builds an export with a JavaScript file, a SQLite database, a PNG (which gets stored as-is), an empty file and a file big enough to span several parts. It serves the parts from a stand-in for g7 that handles Range the way the real one does. A stand-in that ignored Range would let the tests pass while production served garbage. Then it checks:

assert_eq!(whole.len() as u64, layout.content_length(),
           "Content-Length would have lied");

It also resumes at a list of awkward offsets: 0, 1, 7, inside a generated header, one byte before the boundary between two pieces, right on it, one byte after, the middle of a stored part, and the very last byte. Each time, what comes back has to be exactly the tail of the full download. Finally it decodes the whole thing with the zstd library and checks that the first tar header names {root}/data/source/cell.js.

The format isn't free. Every file in the export carries about a kilobyte of uncompressed overhead: the 521-byte header frame, plus a padding frame of up to 520 bytes. A bucket with a hundred thousand tiny objects pays that a hundred thousand times. Compression is per part, so small files can't benefit from each other, and two similar files compress no better together than apart. For most exports, a plain tar | zstd would give you a smaller file.

We took that trade because of where the costs land. Building an export compresses each byte once. Serving it costs only bandwidth, no matter how many times it's downloaded or resumed. And what you save is still an ordinary .tar.zst that zstd -d, tar --zstd -xf and bsdtar -xf all read. After you extract it, running sha256sum -c manifest-sha256.txt in the bag's root directory checks every file against the hash recorded when it was exported.

/  , ,

Tissue Mast is live, and the platform is called Tissue Cloud.

Two things. We've built a second product, Tissue Mast, and the platform you deploy Cells to has a name of its own now. It's called Tissue Cloud.

Mast started out as a pager app. We needed one to run this platform, so we built it and put it on the App Store in September. Then it grew. It checks your sites from seven places, it watches your scheduled jobs, and it has on-call rotations and status pages. At that point it was a monitor, and a monitor is a product of its own.

Mast keeps an eye on the things you run and rings your phone when one of them breaks. The page gets through Do Not Disturb, keeps ringing until someone acknowledges it, and goes to the next person on call if nobody picks up.

The name comes from biology, like the rest of ours. Mast cells are the body's alarm cells. They sit in tissue and go off when something gets in.

You feed it three ways. Probes check a URL, a port, a certificate, a DNS record, a ping or a mail server from seven places in the US and Europe. If a site is down from one place and fine from the other six, it won't wake you.

Response times for debian.org over the last half hour, one row per place it checks from, mostly 50 to 350 ms, with two darker cells at 2,590 ms and 1,090 ms
debian.org over the last half hour, one row for each place it checks from. Most answers take 50 to 350 ms. The two dark cells are a 2.6 second answer from us-w and a 1.1 second one from eu-c-2.

Heartbeats are for jobs that run on a schedule, like backups, cron jobs and nightly imports. The job calls a URL when it finishes, and if it goes quiet, Mast pages you. Channels take alerts from anything that can make an HTTP request. Grafana, Alertmanager, a CI run, a shell script and Home Assistant all work.

Probes only see the public internet, and a lot of what people run isn't on it: services inside a VPC on AWS, queue workers, internal APIs. Heartbeats and channels cover those, because your code calls out to Mast over HTTPS and nothing has to be opened up. Give a scheduled Lambda or a nightly backup a heartbeat and you'll hear about it the first time it doesn't run. It works the same on your own servers, or a box in a cupboard.

Pages arrive in Mast Pager, which is free for iPhone and Android. You can acknowledge, resolve or mute right from the notification, and everyone sets their own quiet hours. The overview shows how many pages land at night.

A 24-hour clock of the last week's pages, night hours shaded: 9 of 43 pages came at night, most from one channel, and quiet hours on it would have held 7
Last week's pages on a 24-hour clock. Nine of 43 came at night, most from one channel, and Mast works out how many of them quiet hours would have held.

Mast also keeps track of where each page went after it left, so a page that reached the phone late shows up as late.

An incident timeline next to the steps one page took: paged at 09:07:18, sent a second later, shown on the iPhone 2 hours 39 minutes after that, not acknowledged
One page, step by step. It went out a second after the probe failed, and the iPhone didn't show it for another 2 hours 39 minutes.

There's a free account, and paid plans are per account, not per seat: Solo is $19 a month, Team is $79 for up to 10 people and Company is $149 for up to 25, each with 14 days free. What's in each plan is on tissue.systems/mast/pricing.

Those were the plans on the day this was posted. The pricing page has the ones on sale.

With two products, calling the platform just "Tissue" got confusing. "Your Tissue plan" and "sign in to Tissue" could mean either one. So the names are: Tissue Systems is the company, Tissue Cloud is where your Cells run, and Tissue Mast is the monitor and the pager.

The name is the only change. Your Cells, databases and buckets stay where they are. Cell URLs on tissue.dev don't move, ribo commands are the same, and so are your account, your plan and your bill. The website is still tissue.systems.

Each one has its own mark now. The four circles stay with the company. Tissue Cloud gets a grid of nine dots with the bottom-right one left open, and Mast uses the same grid with a red dot in the middle for the thing that's paging.

tissue the company
tissue cloud the platform
tissue mast monitoring

Both products use the same sign-in page at auth.tissue.systems, and the same account and bill sit behind both. If you've only used Tissue Cloud, you don't have to do anything. Signing in takes you to your Cells, the same as it always has.

To try Mast, open tissue.systems/mast/app while you're signed in. The top left corner says tissue, cloud and mast. Click cloud to go back to your Cells and mast to come back to Mast. Your account name is next to them, and switch changes account if you're in more than one.

The top left of the app: tissue, cloud and mast, then the account name, its plan and a switch link
The top left corner, in both apps.

Once you've used Mast, signing in takes you back to whichever of the two you had open last.

/  ,

Mast is on the App Store.

We built a pager because running this platform needed one. It is called Mast, it is for iPhone, and it is on the App Store today.

Install it, allow notifications, make a channel. The app hands you a URL. From then on anything that can send an HTTP request can page you: a deploy script, a backup job, a cron entry, the error handler in your API.

$ curl -d "disk 92% on db1" https://mast.tissue.dev/mk_9f2a41c8b7

That is the whole setup. There is no account to create. The phone is the credential, and the channel's address is the only secret.

Every channel has a priority, and the priority is what the notification does to your phone. quiet goes in the feed and leaves the phone dark. normal is a banner and a sound. loud gets through Focus, once. page re-alerts every two minutes until you acknowledge it, and if you sleep through it, it can move on to another person's phone.

A channel can also be a heartbeat, which fires when the posts stop. Your backup script checks in on a schedule, and silence past that schedule is what pages you. The backup failed, cron died, the box went down: all the same missing check-in.

@daily backup && curl -fsS https://mast.tissue.dev/mk_0c47e2a91d

Mast Pager on the App Store or on Google Play, free. Pages reach a paired Apple Watch through notification forwarding. The server side runs on the tissue.systems fleet, in a different failure domain from whatever you point it at. A tissue account is optional; connect one and a token can do what the phone does.

Screenshots, the guide and the rest are at tissue.systems/mast.

/  ,

Get the URL first. Write the handler after.

Wiring up a webhook starts with a guess. The sender's documentation describes a payload from two versions ago, or describes nothing at all, so you deploy a handler that logs whatever turns up, trigger the event, read the log, and deploy again with the real code.

A vesicle endpoint takes the guess out. It is a URL that answers from the moment you create it and stores every delivery under your account, whether or not there is anything yet to run against it.

$ ribo vesicle endpoint create github

  https://api.tissue.systems/hook/hk_9f3c8a1b…   (capture only — no route bound)

Paste that into a repository's Settings → Webhooks and open an issue. The endpoint answers 202 and keeps what arrived:

$ ribo vesicle tail github

  POST · 8437 bytes · content-type: application/json
  { "action": "opened", "issue": { "number": 412, "title": "…" }, "repository": {…} }

There is no Cell yet and nothing was deployed. What you are reading is the request as the sender actually made it, which is frequently not the shape their documentation describes. It is also a test fixture, one shell redirect away:

$ ribo vesicle show cap_7b21 > test/fixtures/issue-opened.json
$ ribo vesicle endpoint bind github --cell deploy-bot --route /github

From here each new delivery is reissued at your Cell on that route, with the method, body and content-type intact. The sender's own headers come along, and the platform adds four of its own:

export default {
  async fetch(request, env) {
    if (request.headers.get("x-tissue-event") !== "vesicle") {
      return new Response("not found", { status: 404 });
    }

    const id = request.headers.get("x-tissue-vesicle-id");      // stable across retries
    const attempt = request.headers.get("x-tissue-vesicle-attempt");
    const event = request.headers.get("x-github-event");        // the sender's own header
    …
  },
};

Any x-tissue-* header a sender supplies is stripped before dispatch, so reading those four without verifying anything is correct rather than lazy. Deliveries are at-least-once and unordered: a retry, a replay, or a sender that posts the same event twice all reach the handler again, and x-tissue-vesicle-id is the key to write against when that matters.

Binding does not backfill. Everything captured while the endpoint was unbound stays put, because writing a handler is a code event rather than a business event, and three weeks of stored deliveries firing the instant a route appears is rarely what anyone wants. You replay them deliberately:

$ ribo vesicle replay cap_7b21                       # one, and it prints the response
$ ribo vesicle replay github --all --since 2026-08-15 --dry-run
$ ribo vesicle replay github --all --since 2026-08-15

Replay can also aim at a Cell running on your own machine. --to is performed by ribo, from your laptop, so a real delivery reaches localhost with no tunnel and no public address pointed at you. The platform never posts to a URL you name: doing that server-side would hand any account a request-forgery primitive, and no convenience is worth shipping one.

statewhat happened
capturedstored, no route bound, waiting for a replay
deliveredthe Cell answered 2xx or 3xx
retrying5xx, a timeout, or unreachable; another attempt is scheduled
rejectedthe Cell answered 4xx. Permanent, never retried
deadretries exhausted

Retries run on a fixed backoff (1m, 5m, 30m, 2h, 6h, 12h, 24h, 24h), which covers a redeploy or an outage that runs most of a day. Nothing has to be configured for that to happen. A 4xx is never retried, since a handler that rejects a payload will reject it identically in an hour; it lands as rejected and waits for you.

A missed webhook is quiet damage. The subscription that never activated, the order that never reached the database. Here it is a row you can read and replay, and the Webhooks page in the dashboard carries a running count of the ones that need a person.

$ ribo vault set deploy-bot GITHUB_WEBHOOK_SECRET
$ ribo vesicle endpoint bind github --cell deploy-bot --route /github \
    --verify github:GITHUB_WEBHOOK_SECRET

Presets cover GitHub's x-hub-signature-256, Stripe's timestamped scheme, and a generic HMAC header. The check runs before anything is stored, so a delivery that fails it is answered 401 and never becomes a capture. The signing secret stays in your vault and is never handed to your code, including code an agent wrote for you.

Anyone holding the address can post to it. Only your account can see what was posted. That split is what makes an endpoint safe to point a payment provider at on day one, and it is why you should treat the id as a password: rotate issues a new one and keeps the old capturing for seven days, so a rotation the sender has not applied yet drops nothing.

Captures are a third party's raw HTTP, which routinely means credentials: the bearer token you gave the vendor, an API key in the body. Every read surface masks those by default, and revealing one is explicit and written to your audit log. Take particular care with a reveal over MCP, where the value goes straight into a model's context.

curl -L https://tissue.systems/download/latest/ribo-macos-arm64 -o ribo
chmod +x ribo && sudo mv ribo /usr/local/bin/ribo

The same actions are in the dashboard under Webhooks, in the REST API under /v1/vesicle, and in the MCP server as vesicle_* tools, so an assistant writing your handler can read the delivery it is writing against. The full guide is at docs.tissue.systems/docs/vesicle/overview.

Deliveries are kept for 30 days, whether or not there was anything there to receive them.

/  , ,

The MCP tool you didn't ship gets built anyway

A customer told us that updating files on their site through our MCP server had gotten slow. We went looking for the slow part. There wasn't one. Storage was healthy, the edges were healthy, and every request in the log had returned ok in a few hundred milliseconds.

What was slow was the shape of the work. The agent on the other end was uploading a stylesheet in 3,072-byte pieces, one tool call each, then deploying a temporary Cell to glue them back together. It had been doing this for the better part of a day. Nothing was broken. We had simply never told it that the job was one HTTP request.

Two calls, back to back, each writing base64 into a bucket:

g7_object_put   key: "_tmp/part-16"   encoding: "base64"
g7_object_put   key: "_tmp/part-17"   encoding: "base64"

Every payload decoded to exactly 3,072 bytes, and the keys were sequential. Our limit on that tool is 256 KB, so each call carried one eighty-fifth of what it was allowed to carry and paid a full round trip to do it. A round trip here means the model writes out 4,096 characters of random base64 as output tokens, which is the most expensive way anything has ever moved three kilobytes.

The account's audit log explained the rest. One Cell had been created and deleted eleven times in twenty hours, alive for thirty to forty-five seconds each time. The agent was writing chunks into a bucket, deploying a Cell whose whole job was to read them back and concatenate them, invoking it once, and deleting it. Then doing the same thing again on the next edit.

Each of those deploys also took a fresh address, since a delete and a re-create can't reuse the one on file, so every cycle left orphaned code sitting on the edges. All of this reached the customer as "the platform is slow today."

Our cell_deploy tool takes JavaScript source as a string, plus bindings for databases, buckets, environment values and secrets. It does not take files. A site with a hundred built assets cannot be deployed with it, and nothing in the tool description said so. The agent did what a competent engineer does with an incomplete API: it composed the primitives it had into the one it was missing.

The worse part is that it never needed to. Static assets behind a FILES binding are read from the bucket at request time, so uploading an object is the publish step. Changing one stylesheet on a live site is one presigned URL and one curl -T. A redeploy would not have helped even if it had been possible.

That was true the entire time. It is in our storage documentation and it is in the router. It was absent from the one place the agent was actually reading, which was the list of tools and the sentences attached to them.

An agent builds its picture of what your platform can do almost entirely from the tools you expose and the words attached to them. That picture is the whole map. Where the territory is missing from it, the agent does not stop and file a bug against you. It gets to the goal with the primitives that are on the map, because getting to the goal is the job you gave it.

So a missing tool costs far more than it looks. The work still happens, just a worse way, silently, on every repetition, and it reaches you weeks later as a vague complaint about speed. We were told "it's slow." We were not told "your deploy tool has no path for files," which is what was being reported.

We had already written the correct advice. g7_object_put rejects anything over 256 KB with an error naming the tool you should have reached for instead. That error was the only place in the entire surface where the right answer appeared, and it was unreachable. The failure ran at 3 KB, far under the ceiling, so the guard never fired once across twenty hours of doing the wrong thing.

Limits catch the extreme case. Agents fail in the comfortable middle, well inside every bound you set, which is where nothing is watching.

There are three places to put guidance in an MCP server, and they are not equally useful.

Server instructions load once, at the start of a session, then compete with everything the user says afterwards. Tool descriptions load with the tool list, before the agent knows what it is going to be asked to do. Tool results arrive in the middle of the work, addressed to a decision being made at that moment.

Only the third one shows up on time, so we started using it. A put whose key looks like a piece of a split file now returns ok plus a note: presigning exists, it takes a list of keys, and files behind a FILES binding are live when they land. It interrupts the loop on the first iteration rather than the eleventh.

g7_presign_upload takes a keys array and returns one URL per key, so an entire build is a single call and the bytes never touch the model. cell_deploy takes files_bindings, so a first deploy can point at a bucket you have already filled. g7_object_put now describes itself as the small-object tool it is and names presigning as the default. The server instructions say in four sentences that files serve live from the bucket and that splitting a file across calls is never the answer.

The platform could do every bit of this on the day the customer started chunking. What was missing was any way to learn that from the tool list.

/  , ,

Your Cell is public. Now that's a choice.

Cells now support gates: an access policy in front of a Cell's public URL, enforced at the edge, before your code runs. You declare who may enter. The platform handles the sign-in page, the emailed codes, the sessions, the revocation. Your Cell doesn't change at all.

[gate]
audience = "emails"
allow    = ["sam@example.com"]

Deploy that, and the URL stops being public. Anyone else gets a sign-in page. Sam gets a six-digit code by email, types it once, and is in for thirty days. Your code never sees any of it.

Every Cell is born public. That's right for a homepage and wrong for most other things you actually make: the admin panel, the dashboard for one client, the prototype you want three people to look at, the internal tool that's internal because it can drop tables.

The usual fix is to build auth into the app. A login route, a session cookie, somewhere to keep a password, a reset flow once someone forgets it. For a forty-line Cell, the auth outweighs the Cell. So it doesn't get built, and the URL stays public, "temporarily", guarded by being hard to guess.

A gate moves that entire problem out of your code and into a config block that deploys with it.

audiencewho may enter
linkholders of a capability link you mint
privateyou, signed in with your Tissue account
accountany member of the Cell's account
emailsthe addresses you list, verified by one-time code
domainanyone with an email under your domains
publiceveryone; a gate standing open

Two knobs apply everywhere: allow admits extra addresses alongside the main audience, and links = false turns capability links off when the list should be the only way in. Session lifetime is [gate.session] ttl, one hour to ninety days.

The policy is validated before anything is written. A typo in the gate block fails the deploy; it does not deploy the Cell open. And the ribo.toml block is authoritative: deploy with it and the stored policy is replaced, deploy without it and a previously deployed gate comes off. Policies set through the API instead are marked as such, and deploys leave them alone.

Sometimes there is no list of emails, there's just "I want Priya to see this until Friday." That's a capability link:

$ ribo gate link paper-review --ttl 12h --read-only

  token:  tal_ab12cd34ef56.…
  url:    https://paper-review.strand-9c.tissue.dev/?k=tal_ab12cd34ef56.…

  This is the only time the token is shown.

Opening the URL exchanges the token for a session and the ?k= disappears from the address bar. Links can be time-boxed, restricted to a path prefix, or made GET-only. The token itself is stored hashed; if you lose it, you revoke it and mint another. API clients skip the browser entirely and send it as a Bearer token.

$ ribo gate sessions paper-review
$ ribo gate sessions paper-review --revoke 9f3a1b2c
$ ribo gate sessions paper-review --revoke-all

--revoke-all is immediate and enforced by the platform, not by asking browsers nicely: the edge rejects any session issued before the revocation. That holds even for a cookie copied off a laptop you no longer control.

Verification happens at the edge by checking a signature against a public key, so a gated request costs no database lookup. You will not find the gate in your response times.

export default {
  async fetch(request) {
    const email = request.headers.get("x-tissue-gate-email");
    // "sam@example.com", verified, or null on an ungated Cell
  },
};

One header. The guarantee that makes it usable: the platform strips inbound x-tissue-gate-* headers from every request to every Cell, gated or not, before the gate injects its own. Nobody outside can put that header on a request to you. So reading it without verifying anything is correct, not lazy. There is no token to parse in your code, no key set to fetch, no auth library to vendor and keep patched.

Enter an email the policy doesn't allow, and you get the same "check your email" page as anyone else, with one difference you can't observe: nothing is sent and nothing is stored. The form points at a decoy. An outsider can't type addresses into the sign-in page to learn who's on the list.

Codes are hashed at rest, expire in fifteen minutes, and burn on use. The burn is a conditional write in the store, not a read followed by a write, so redeeming the same code through two different edges at the same moment still succeeds exactly once.

And one we got wrong first: the initial release gated everyone, including us. Pulse fires your schedules by calling the Cell, and a gated Cell asked our own scheduler to sign in. The scheduler does not have an email address. Schedules on gated Cells silently stopped, we caught it writing this documentation, and the fix shipped the same day with a regression test bolted over the hole. Platform invocations now pass; the public URL is exactly as closed as before.

curl -L https://tissue.systems/download/latest/ribo-macos-arm64 -o ribo
chmod +x ribo && sudo mv ribo /usr/local/bin/ribo

The simplest possible gate is two lines, [gate] and audience = "link": deploy, mint a link, hand it to someone. Everything above is also in the REST API under /v1/cells/…/gate and in the MCP server as gate_* tools, so an agent that deploys a Cell can lock it in the same breath. The full guide, including how gates interact with custom domains, lives at docs.tissue.systems/docs/cells/gate.

/  , , ,

Two agents, one machine, the wrong account.

ribo now supports credential profiles: a named login bound to a directory. Anything you run in that directory, or below it, authenticates as that profile. Two projects, two accounts, two terminals, all at once. No coordination, nothing to remember.

If you only ever use one account, nothing changes. If you run coding agents that deploy on your behalf, this one is for you.

Until today, ribo had exactly one credential: ~/.config/ribo/token.json. The account you're acting as lives inside that token, and ribo account switch re-mints it in place.

Which makes account selection a global variable. Two terminals:

# terminal 1                        # terminal 2
ribo account switch "Acme"
                                   ribo account switch "Personal"
ribo deploy     # ← deploys as Personal

No error. No prompt. The deploy succeeds. Into the wrong account.

And it doesn't merely deploy to the wrong place. ribo deploy resolves a Cell by name within the token's account, so deploying to an account that has never seen this Cell doesn't update anything: it creates a new one. You end up with a duplicate Cell in the wrong account, live at a URL under the wrong subdomain, with bindings pointed at the wrong account's databases and buckets.

Two terminals is the tolerable version of this. The version that actually hurts is two coding agents on the same machine, working in different projects, one of them running ribo account switch while the other is mid-build. Nobody typed anything wrong. There was nothing to see.

ribo profile create acme --from-current
ribo profile create personal --from-current

ribo profile activate acme     ~/work/acme-site
ribo profile activate personal ~/personal/my-blog

That's the whole setup. From here on, anything run under ~/work/acme-site is Acme, anything under ~/personal/my-blog is you, simultaneously, in as many shells or agents as you like. They can't clobber each other, because they no longer share a credential. ribo account switch inside a bound tree writes into that tree's profile and nowhere else.

The precedence chain, first match wins:

#SourceScope
1RIBO_TOKENthe process
2--profile <name>one command
3nearest bound ancestor directorythat tree
4the default login (ribo login)everywhere else

Nearest wins: ~/work bound to one profile and ~/work/acme bound to another means ~/work/acme/site uses the inner one.

The ordering is deliberate. RIBO_TOKEN is set by whoever launched the process, usually CI, and nothing inside a checkout should be able to override it, so it sits on top. Below that: a flag you typed for this command beats a binding you made months ago, which beats the login you'd forgotten you had. Nothing in the chain is clever. You should be able to predict which credential you're about to use without running anything.

The real problem with a global credential is that when it's wrong, the wrongness is invisible. So there's a command whose entire job is to answer the question out loud:

$ ribo profile which
directory  /Users/you/work/acme-site
credential profile "acme" (bound at /Users/you/work/acme-site)
server     https://api.tissue.systems
account    Acme Corp (acct_3f8c1a2b4d6e8f00)

No side effects, no network mutation, safe to run anywhere. Put it at the top of a deploy script. Teach your agent to run it before it touches production. Every deploy echoes the same thing, unprompted:

account   Acme Corp (acct_3f8c1a2b4d6e8f00) [pinned]
via       profile "acme" (bound at /Users/you/work/acme-site)
server    https://api.tissue.systems
deployed  acme-site

Profiles make the right credential ambient. ribo.toml makes a wrong one fatal:

[cell]
name = "acme-site"
account_id = "acct_3f8c1a2b4d6e8f00"

The pin is an assertion, not a selector. It never picks an account for you. It stops a deploy that would land somewhere else, before anything is uploaded:

Error: Refusing to deploy: account mismatch.

  ribo.toml pins   Acme Corp (acct_3f8c1a2b4d6e8f00)
  active account   Personal  (acct_9zp5k1m3n5p7r9t1)

The tempting alternative is to let account_id select the account instead: read it from the config, act on it, done. We decided against that. Selecting quietly stretches a credential to cover an account nobody chose it for; asserting turns the same ambiguity into a stop. When the operator might be a language model at 3am, we would rather halt than proceed plausibly.

The check runs on both sides. The CLI refuses locally, and the deploy request carries the expected account id so the server refuses too. An out-of-date CLI can't route around it. And the account id isn't a secret, so commit the pin: everyone who clones the repo, agents included, gets the guardrail for free.

One design decision here is easy to get backwards.

If a directory is bound to a profile you've since deleted, ribo errors:

Error: /Users/you/work/acme-site is bound to profile "acme", which no longer exists.

  Re-create it:  ribo profile create acme
  Or unbind it:  ribo profile deactivate /Users/you/work/acme-site

It does not fall back to your default login. Falling back would be friendlier for about four seconds, and then it would silently deploy to whatever account happened to be sitting in token.json, which is the exact failure the whole feature exists to prevent. A tool that guards against silent retargeting should not have a silent retargeting path in it.

Same reasoning behind a fix that shipped alongside this. RIBO_TOKEN was honoured for authentication but not for identity: with RIBO_TOKEN set to one account and token.json holding another, ribo would authenticate as the first, report the second, and (worse) compare the account pin against the second. The guardrail was checking the wrong identity. Both paths now resolve through one function, so what ribo authenticates as and what it tells you are the same object by construction.

Nothing to do. RIBO_TOKEN still outranks everything, and an environment variable is already per-process, so parallel jobs on one runner were never at risk:

- name: Deploy Cell
  env:
    RIBO_TOKEN: ${{ secrets.RIBO_TOKEN }}
  run: ribo deploy

ribo profile which says so explicitly when RIBO_TOKEN is set, so an environment credential shadowing a profile is never a surprise.

curl -L https://tissue.systems/download/latest/ribo-macos-arm64 -o ribo
chmod +x ribo && sudo mv ribo /usr/local/bin/ribo

Then, in any project:

ribo profile which

The full guide lives at docs.tissue.systems/docs/ribo/profiles: every subcommand, the migration path from an existing login, and recipes for concurrent agents.

Credentials live in ~/.config/ribo/: token.json for your default login, profiles.json for named profiles and bindings. Both are written 0600 inside a 0700 directory, re-applied on every write.

/  , ,

Your Cell just got closer: GeoDNS on Tissue.

Tissue now runs multiple production edges, and every Cell is served from the one nearest to the visitor. The URL doesn't change, your code doesn't change, and there is nothing to configure: the routing happens at the DNS layer, before the first packet of the request is even sent.

A visitor on the US West Coast and a visitor in Europe now ask the same question (where is crane-a4f2.strand-9c.tissue.dev?) and get different answers. Each one lands on the edge with the fewest milliseconds between them and your Cell.

Every Cell lives at <cell>.<account>.tissue.dev, two labels deep. That detail turns out to decide the whole architecture, because of a rule written into DNS itself: a wildcard record matches exactly one label. *.tissue.dev matches foo.tissue.dev, but it does not match crane-a4f2.strand-9c.tissue.dev.

No hosted DNS product can wildcard names at arbitrary depth, let alone pick the answer by the visitor's location on top of that. So Tissue has always run its own authoritative nameserver for tissue.dev: instead of storing a zone file, it synthesizes an answer for any Cell name, at any depth, on the fly. Adding geography meant teaching that synthesis one more trick: choosing which edge IP to answer with.

When a query arrives, the nameserver looks up where it came from in an IP-geolocation database, computes the great-circle distance to each healthy edge, and answers with the closest one:

$ dig +short crane-a4f2.strand-9c.tissue.dev   # from San Francisco
→ the US-West edge

$ dig +short crane-a4f2.strand-9c.tissue.dev   # from Berlin
→ the US-Central edge (closest to Europe today)

Most queries don't come from you, though. They come from your resolver (Google's 8.8.8.8, Cloudflare's 1.1.1.1, your ISP), whose servers may sit nowhere near you. Geolocating the resolver would route you to its nearest edge, not yours. The fix is EDNS Client Subnet (RFC 7871): well-behaved resolvers attach a truncated form of your network to the query, and our nameserver prefers that over the packet's source address. You get routed by where you are.

Geo answers carry a short TTL, so when the picture changes (an edge drains for maintenance, a new one joins) clients re-resolve and follow within a minute, not a day.

Handing out a nearby IP is worthless if that edge can't actually serve you. The real work was making every edge complete, able to answer for any Cell on the platform:

LayerHow every edge serves it
Cell codeFetched on demand the first time an edge sees a request for a Cell, then cached locally. Deploy once; every edge picks it up.
Objects (g7)Replicated across edges. A file uploaded through one edge is served from any of them.
SQL (c3)Each database has a home. Your Cell runs on the edge nearest the visitor, and its queries are routed to the database's home over our private backbone, transparently, so your data stays in exactly one authoritative place.
TLSCertificates live in a store shared by all edges, so any edge can terminate HTTPS for any Cell, and for your custom domains.

The compute follows the visitor; the data keeps a single home. That's a deliberate trade: your Cell's static assets, code, and TLS all serve from the nearest edge, while a database write never has to reconcile two conflicting copies. Read replicas at every edge are the natural next step, and the architecture is built to grow into it.

A geo-router that keeps sending people to a dead server is worse than no geo-router. The nameserver continuously health-checks every edge; one that stops answering is dropped from the candidate set, and its region falls back to the nearest healthy edge. Combined with the short TTL, a failing edge drains out of the request path in about a minute. No pager, no DNS change to push.

Nothing. Existing Cells, existing URLs, and custom domains (which resolve through the same path via their CNAME) all geo-route now. Visitors far from US-West simply get faster first bytes, and the platform gained the shape it needs to keep adding edges: stand one up, let it fill its caches, add it to the map.

Deploy a function, get a live URL, and let DNS worry about the geography. Sign up and run ribo deploy.

/  , ,

Bring your own domain to Tissue.

You can now put your own domain on a Cell yourself. Point app.example.com (or a bare apex like example.com) at a Cell, and Tissue provisions HTTPS automatically on the first request. No ops, no waiting, no support ticket.

This used to need an email to us. Now it's three steps you run from the CLI, the dashboard, the API, or Claude. The certificate takes care of itself.

Adding a domain is register → verify ownership → point DNS. Each step is a single command:

# 1. register the domain
ribo domain add app.example.com

# 2. add the _tissue-challenge TXT record it prints, then:
ribo domain verify app.example.com

# 3. add a CNAME to your Cell's tissue.dev address, then verify again:
ribo domain verify app.example.com   # → active
StepWhat you do
1. registerribo domain add app.example.com reserves the domain on your account and returns the records you'll need.
2. prove ownershipAdd the _tissue-challenge.<domain> TXT record shown, then run ribo domain verify <domain>.
3. point DNSAdd a CNAME to <cell>.<account-subdomain>.tissue.dev (or an ALIAS/ANAME for an apex), and verify once more. The domain flips to active.

Once active, the first HTTPS hit triggers an automatic Let's Encrypt certificate, issued, installed, and renewed for you. Nothing to upload, nothing to rotate.

Step 2 exists for one reason: proving you control the domain is what stops someone else from claiming a name that already points at Tissue. The _tissue-challenge TXT record is the proof: only the real owner can add it.

If your DNS is on Cloudflare, set the CNAME to "DNS only" (grey cloud), not proxied (orange cloud). A proxied record terminates TLS at Cloudflare and breaks the certificate challenge, so the domain will verify but HTTPS won't come up. Grey cloud, and you're done.

The same flow is available from every surface:

SurfaceHow
CLIribo domain add, ribo domain verify, ribo domain list, ribo domain remove
DashboardOpen your Cell and use the Domains tab: paste a domain, copy the TXT and CNAME records, and click Verify. No CLI required.
APIPOST /v1/domains and friends, with a tok_… token.
MCPThe domain_* tools. Ask Claude to "add app.example.com to my Cell" and it walks the steps.

Pick a Cell, pick a domain, and run:

ribo domain add app.example.com

The full walkthrough lives at docs.tissue.systems/docs/cells/custom-domains: apex domains, every DNS provider's quirks, and the verification states.

/  , ,

Drive Tissue from Claude: the Tissue MCP server.

Tissue now has an MCP server. Point Claude (or Cursor, Windsurf, or any Model Context Protocol client) at one URL and manage your whole account in plain language: deploy Cells, query c3, read and write g7 objects, schedule pulses, and handle secrets, without leaving the chat.

The endpoint is https://tissue.systems/mcp. Everything an agent can see and do is bounded by the token you give it: least privilege, by construction.

For Claude Code, that's the whole setup:

claude mcp add --transport http tissue https://tissue.systems/mcp

On first use it opens your browser, you sign in to Tissue once, and the tools light up. No token to copy, no config file to hand-edit. Under the hood it's a standard OAuth flow with automatic client registration; the same browser-login works in Claude Desktop, Claude.ai, and Cursor. For CI and headless agents, create a scoped tok_… token instead and pass it as a bearer header. Full setup for every client is in the docs.

The server exposes one tool per operation, named <area>_<verb>, and filters them by your token's scopes: a read-only token simply never sees the write or delete tools.

AreaTools
Cellscell_list, cell_get, cell_deploy, cell_invoke, cell_logs, cell_errors, cell_delete
c3 (SQL)c3_query (read-only), c3_execute, c3_batch, c3_database_list/create/drop
g7 (storage)g7_bucket_*, g7_object_*, g7_presign_upload, g7_presign_download
pulse (cron)pulse_list, pulse_trigger
vault (secrets)vault_key_list, vault_set, vault_delete
accountwhoami, token_list/create/revoke, search_tissue_docs

Once connected, ask in plain language:

Deploy a Cell called "hello" that returns "Hello, world!" for any request.

Create a c3 database "todos" with a tasks table (id, title, done, created_at),
then show me everything in it.

Show me the last 20 errors from my "payment-processor" Cell.

List my buckets and tell me the total size of the "uploads" bucket.

Claude calls the right tools, chains them, and reports back: deploying, querying, and inspecting as it goes.

Object bytes don't belong in a model's context. For anything beyond small text, the server mints a short-lived presigned URL and the bytes move out-of-band, straight to storage, never through Claude:

You: upload ./logo.png to my "assets" bucket.
Claude → g7_presign_upload → returns a one-time PUT URL
       → curl -T logo.png "<url>"   (bytes go directly to g7)

Because Tissue is the storage layer, the presigned URL is signed and verified by g7 itself: time-boxed, scoped to a single object and method, and tied to your bucket's credentials. The agent gets a capability, not your keys.

Small choices add up to a server that's safe and legible for an LLM to drive:

FeatureWhat it does
Scoped tokensGrant an agent databases:read and nothing else. Enforced at the token, and read queries run on a read-only connection so writes are rejected by the engine.
Tool annotationsEvery tool is tagged read-only / destructive / idempotent, so your client can ask before it deletes.
Structured outputResults come back as machine-readable JSON, so the agent doesn't have to re-parse prose.
Docs searchsearch_tissue_docs lets the agent look up exact syntax instead of guessing.
Current protocolNegotiates up to MCP 2025-11-25 and works with today's clients out of the box.

Add the server, sign in, and ask Claude to deploy something:

claude mcp add --transport http tissue https://tissue.systems/mcp

The full guide lives at docs.tissue.systems/docs/mcp: browser login and token setup for Claude Code, Claude Desktop, Claude.ai, and Cursor, plus the complete tool and scope reference.

/  ,

Coming soon: sensors on Tissue.

This shipped on June 29, 2026. Devices connect to synapse over MQTT with TLS at ingest.tissue.dev:8883, each with its own token, and every reading arrives in your Cell's sensor() handler. A Cell can also send commands back down to a device. MQTT over WebSocket, CoAP, plain HTTPS ingest and ganglion are still coming. The synapse docs have the setup.

We're building tissue Sense: a way to point any sensor at Tissue and get a live dashboard, stored history, and a full alerting pipeline that routes and escalates wherever it needs to go, without standing up a single server.

Tissue already gives you compute (Cells), SQL (c3), object storage (g7), and scheduling (pulse). The piece missing for the physical world was a front door for devices and a way to run close to them. That's what we're adding, and it's two new pieces with names that fit the rest of the platform: synapse and ganglion.

synapse is the ingest layer. It speaks the protocols real hardware already uses (MQTT, MQTT-over-WebSocket, CoAP over DTLS for battery devices, and plain HTTPS) and turns every reading into an event your Cell handles in a new sensor(event, env) handler, right alongside fetch and pulse. Each device gets its own credential and can only write its own stream. The connections live outside your Cell, so your code stays as simple as the rest of Tissue.

The practical upshot: a $5 microcontroller with a temperature sensor, a Tasmota plug you already own, or a battery LoRa node in a field can all report to the same place, and a browser can watch the numbers tick in real time.

ganglion is software you install on a Raspberry Pi (or any small Linux box) that runs the same Cell as the cloud, right there in your building. It bridges sensors that can't reach the internet on their own (LoRa, Zigbee, BLE, Modbus), and it keeps working when the internet doesn't: ingest, dashboard, and alerts all run on-site, and buffered readings sync up when the uplink returns.

Because the gateway runs the same Cell, your sensor data can be ingested, stored, charted, and alerted on entirely inside your own walls. The cloud becomes optional, for remote access, not a requirement to function.

A reading crossing a line is just the trigger. Because the alert logic is your Cell, what happens next is a pipeline you control: a rules engine watches for thresholds, sudden swings, and a sensor that has gone silent, then routes the alert wherever it needs to go. Push it to a phone, text a teammate, email a list, fire a webhook into Slack or PagerDuty, or escalate up an on-call rotation until someone acknowledges. The notification on your phone is one delivery channel, not the whole system.

You areWhat you get
A tinkererFlash a board in your browser, scan a code, see your sensor on a shareable page in minutes. Free.
A small farmerGreenhouse and cooler alerts that reach your phone, your family, or your staff, including when a sensor goes silent.
An operatorPrivate dashboards, embeddable charts, and alerts that escalate. Public or private with one tap.
IndustrialA gateway you own, Modbus and LoRa on-site, and data that never leaves the building.

Most sensor platforms make you rent three black boxes: their ingest pipeline, their locked dashboard widgets, their rules UI. You can't move any of them. On Tissue, the Cell that ingests the reading is the same Cell that renders the dashboard and runs the alert: one unit you own, that you can fork, and that runs in our cloud or on a Pi in your greenhouse. Dashboards are real web pages, so sharing and embedding them is native, not a paywalled tier.

synapse and ganglion are in active development. We're opening early access soon. If you want to be first to point a sensor at Tissue, sign up and keep an eye on this blog. We'll post again the day it's live.

/  ,

Tissue runs on Tissue.

We recently moved tissue.systems itself (the landing page, auth, dashboard, docs, and support) to run as Cells on Tissue. The platform now hosts its own front door.

A milestone like this either feels trivial ("of course it should run on itself") or tells you something about where the platform actually is. For us it was the second.

DomainWhat it does
tissue.systemsLanding page (static files served by a Files Cell)
auth.tissue.systemsOAuth login, token issuance, /api/me (a JS Cell backed by c3 SQLite)
dashboard.tissue.systemsDeveloper dashboard (JS Cell, reads the management API)
docs.tissue.systemsDocumentation (static files Cell)
support.tissue.systemsSupport (JS Cell)

Each of these is deployed with a standard ribo deploy from a ribo.toml, the same as any user Cell. The custom domains point at the same routing layer as every other Cell, with TLS provisioned automatically.

The management API at api.tissue.systems is not a Cell. It is the process that deploys Cells, and it cannot coherently run inside itself. It runs as a bare system process and is the only part of the platform that cannot eat its own cooking. Everything above that layer can.

Moving to this setup raised an immediate question: auth.tissue.systems issues the JWT tokens that ribo login stores locally. Those tokens are required to deploy Cells. So the auth Cell must be running before you can deploy anything, including the auth Cell itself.

The sequence is: stand up the management API first (bare metal), deploy auth with a temporary credential, then use the issued token to deploy everything else. The substrate has to exist before the things that run on it. This is not a deep paradox, just the order of operations, but it clarifies what "the substrate" actually is. The management API is the bedrock. Everything else, including our own product's front door, is a Cell.

Running on your own platform is the most honest test of it. The things we noticed immediately: cold-start latency matters when it is your own login page. c3 SQLite needs to be reliable when it is storing your own user sessions. Custom domain TLS provisioning needs to be invisible when it is your own domain at stake.

None of those turned out to be problems.

If you want to deploy a function and get a live URL, with SQL and storage and scheduling included, on infrastructure you control: sign up and run ribo deploy.