Skip to content

The only tool you need to know what is happening and how to fix it.

feat: website blog created

ddux98f5d68d603a
diff --git a/website/app/blog/[slug]/page.tsx b/website/app/blog/[slug]/page.tsx
index 9fc9b5f7..279355f8 100644
--- a/website/app/blog/[slug]/page.tsx
+++ b/website/app/blog/[slug]/page.tsx
@@ -5,10 +5,13 @@ import { MDXRemote } from "next-mdx-remote/rsc";
import remarkGfm from "remark-gfm";
import { ArrowLeft } from "lucide-react";
import { Eyebrow } from "@/components/eyebrow";
+import { BlogSubscribe } from "@/components/blog-subscribe";
import { getAllPosts, getPostBySlug } from "@/lib/blog";
type Params = { slug: string };
+// Note: "engineering" is reserved by the static /blog/engineering route, so no
+// post may be named engineering.mdx — the static segment would shadow it here.
export function generateStaticParams(): Params[] {
return getAllPosts().map((p) => ({ slug: p.slug }));
}
@@ -21,9 +24,14 @@ export async function generateMetadata({
const { slug } = await params;
const post = getPostBySlug(slug);
if (!post) return { title: "Not found — Traceway" };
+ const description =
+ post.description ??
+ (post.category === "engineering"
+ ? `${post.title} — from the Traceway engineering blog.`
+ : `Release notes for Traceway ${post.title}.`);
return {
title: `${post.title} — Traceway`,
- description: `Release notes for Traceway ${post.title}.`,
+ description,
};
}
@@ -36,12 +44,14 @@ export default async function BlogPostPage({
const post = getPostBySlug(slug);
if (!post) notFound();
+ const isEngineering = post.category === "engineering";
+
return (
<main className="relative">
<section className="wrap py-20">
- <div className="prose">
+ <div className="blog-article">
<Link
- href="/blog"
+ href={isEngineering ? "/blog/engineering" : "/blog"}
className="inline-flex items-center gap-1 text-[13px] mb-6"
style={{
color: "var(--fg-2)",
@@ -53,19 +63,34 @@ export default async function BlogPostPage({
All posts
</Link>
- <Eyebrow>Release</Eyebrow>
- <h1 className="mt-4 mb-3">{post.title}</h1>
- <p
- style={{ color: "var(--fg-3)", fontFamily: "var(--font-mono)" }}
- className="mb-12 text-[13px]"
- >
- {formatDate(post.date)}
- </p>
+ <article className="blog-panel">
+ <div className="prose">
+ <Eyebrow>{isEngineering ? "Engineering" : "Release"}</Eyebrow>
+ <h1 className="mt-4 mb-3">{post.title}</h1>
+ <p
+ style={{ color: "var(--fg-3)", fontFamily: "var(--font-mono)" }}
+ className={`${post.description ? "mb-3" : "mb-12"} text-[13px]`}
+ >
+ {formatDate(post.date)}
+ </p>
+
+ {post.description && (
+ <p
+ className="mb-12 text-[17px] leading-relaxed"
+ style={{ color: "var(--fg-2)" }}
+ >
+ {post.description}
+ </p>
+ )}
+
+ <MDXRemote
+ source={post.content}
+ options={{ mdxOptions: { remarkPlugins: [remarkGfm] } }}
+ />
+ </div>
+ </article>
- <MDXRemote
- source={post.content}
- options={{ mdxOptions: { remarkPlugins: [remarkGfm] } }}
- />
+ {isEngineering && <BlogSubscribe />}
</div>
</section>
</main>
diff --git a/website/app/blog/engineering/page.tsx b/website/app/blog/engineering/page.tsx
new file mode 100644
index 00000000..b0a5443c
--- /dev/null
+++ b/website/app/blog/engineering/page.tsx
@@ -0,0 +1,35 @@
+import type { Metadata } from "next";
+import { Eyebrow } from "@/components/eyebrow";
+import { BlogTabs } from "@/components/blog-tabs";
+import { BlogPostList } from "@/components/blog-post-list";
+import { BlogSubscribe } from "@/components/blog-subscribe";
+import { getPostsByCategory } from "@/lib/blog";
+
+export const metadata: Metadata = {
+ title: "Engineering Blog — Traceway",
+ description: "Deep dives, benchmarks, and engineering notes from the Traceway team.",
+};
+
+export default function EngineeringBlogIndex() {
+ const posts = getPostsByCategory("engineering");
+
+ return (
+ <main className="relative">
+ <section className="wrap py-20">
+ <div className="prose">
+ <Eyebrow>Blog</Eyebrow>
+ <h1 className="mt-4 mb-3">Engineering</h1>
+ <p style={{ color: "var(--fg-3)" }} className="mb-12">
+ Deep dives, benchmarks, and how we build Traceway.
+ </p>
+
+ <BlogTabs active="engineering" />
+
+ <BlogPostList posts={posts} />
+
+ <BlogSubscribe />
+ </div>
+ </section>
+ </main>
+ );
+}
diff --git a/website/app/blog/page.tsx b/website/app/blog/page.tsx
index f76b1588..010146c6 100644
--- a/website/app/blog/page.tsx
+++ b/website/app/blog/page.tsx
@@ -1,7 +1,8 @@
-import Link from "next/link";
import type { Metadata } from "next";
import { Eyebrow } from "@/components/eyebrow";
-import { getAllPosts } from "@/lib/blog";
+import { BlogTabs } from "@/components/blog-tabs";
+import { BlogPostList } from "@/components/blog-post-list";
+import { getPostsByCategory } from "@/lib/blog";
export const metadata: Metadata = {
title: "Blog — Traceway",
@@ -9,7 +10,7 @@ export const metadata: Metadata = {
};
export default function BlogIndex() {
- const posts = getAllPosts();
+ const posts = getPostsByCategory("release");
return (
<main className="relative">
@@ -21,51 +22,11 @@ export default function BlogIndex() {
What we shipped, and when.
</p>
- {posts.length === 0 ? (
- <p style={{ color: "var(--fg-3)" }}>No posts yet.</p>
- ) : (
- <ul style={{ listStyle: "none", padding: 0, margin: 0 }}>
- {posts.map((post) => (
- <li
- key={post.slug}
- style={{ borderTop: "1px solid var(--hair)", padding: "20px 0" }}
- >
- <Link
- href={`/blog/${post.slug}`}
- style={{ color: "var(--fg-0)", textDecoration: "none" }}
- className="block hover:opacity-80 transition-opacity"
- >
- <div
- className="text-[12px] mb-1"
- style={{ color: "var(--fg-3)", fontFamily: "var(--font-mono)" }}
- >
- {formatDate(post.date)}
- </div>
- <div
- className="text-[18px] font-medium"
- style={{ fontFamily: "var(--font-display)" }}
- >
- {post.title}
- </div>
- </Link>
- </li>
- ))}
- </ul>
- )}
+ <BlogTabs active="release" />
+
+ <BlogPostList posts={posts} />
</div>
</section>
</main>
);
}
-
-function formatDate(isoDate: string): string {
- if (!isoDate) return "";
- const d = new Date(isoDate + "T00:00:00Z");
- if (Number.isNaN(d.getTime())) return isoDate;
- return d.toLocaleDateString("en-US", {
- year: "numeric",
- month: "long",
- day: "numeric",
- timeZone: "UTC",
- });
-}
diff --git a/website/app/globals.css b/website/app/globals.css
index 72584c4e..21bdcb38 100644
--- a/website/app/globals.css
+++ b/website/app/globals.css
@@ -354,6 +354,85 @@
font-size: 13px;
}
+ /* Blog post cards */
+ .blog-card {
+ display: block;
+ border: 1px solid var(--hair);
+ background: color-mix(in oklab, var(--ink-2) 70%, transparent);
+ border-radius: var(--radius-lg);
+ padding: 20px 22px;
+ text-decoration: none;
+ transition: background 0.15s ease, border-color 0.15s ease, transform 0.15s ease;
+ }
+ .blog-card:hover {
+ background: var(--ink-3);
+ border-color: color-mix(in oklab, var(--a1) 35%, var(--hair-2));
+ transform: translateY(-2px);
+ }
+
+ /* Segmented blog tabs */
+ .blog-tabs {
+ display: inline-flex;
+ align-items: center;
+ gap: 4px;
+ padding: 4px;
+ border-radius: var(--radius-lg);
+ background: color-mix(in oklab, var(--ink-2) 80%, transparent);
+ border: 1px solid var(--hair);
+ }
+ .blog-tab {
+ padding: 7px 16px;
+ border-radius: var(--radius);
+ font-family: var(--font-mono);
+ font-size: 13px;
+ color: var(--fg-3);
+ text-decoration: none;
+ border: 1px solid transparent;
+ transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
+ }
+ .blog-tab:hover {
+ color: var(--fg-1);
+ }
+ .blog-tab-active {
+ color: var(--fg-0);
+ background: var(--ink-4);
+ border-color: var(--hair-2);
+ box-shadow: 0 1px 2px rgba(0, 0, 0, 0.4);
+ }
+ .blog-tab-active:hover {
+ color: var(--fg-0);
+ }
+
+ /* These links live inside .prose, which underlines + recolors all anchors;
+ override so cards and tabs read as normal UI, not body links. */
+ .prose a.blog-card {
+ text-decoration: none;
+ }
+ .prose a.blog-tab {
+ text-decoration: none;
+ color: var(--fg-3);
+ }
+ .prose a.blog-tab:hover {
+ color: var(--fg-1);
+ }
+ .prose a.blog-tab.blog-tab-active,
+ .prose a.blog-tab.blog-tab-active:hover {
+ color: var(--fg-0);
+ }
+
+ /* Article reading panel */
+ .blog-article {
+ max-width: 860px;
+ margin: 0 auto;
+ }
+ .blog-panel {
+ border: 1px solid var(--hair-2);
+ background: color-mix(in oklab, var(--ink-2) 55%, transparent);
+ border-radius: var(--radius-xl);
+ padding: clamp(24px, 4vw, 44px);
+ box-shadow: 0 30px 60px -40px rgba(0, 0, 0, 0.6);
+ }
+
/* Chips */
.chip {
display: inline-flex;
@@ -1250,6 +1329,14 @@
font-family: var(--font-mono);
font-size: 0.9em;
}
+ .prose img {
+ max-width: 100%;
+ height: auto;
+ display: block;
+ margin: 28px auto;
+ border-radius: var(--radius-lg);
+ border: 1px solid var(--hair);
+ }
/* Logo color control */
.logo-img {
diff --git a/website/components/blog-post-list.tsx b/website/components/blog-post-list.tsx
new file mode 100644
index 00000000..f39a442c
--- /dev/null
+++ b/website/components/blog-post-list.tsx
@@ -0,0 +1,54 @@
+import Link from "next/link";
+import type { BlogPostMeta } from "@/lib/blog";
+
+export function BlogPostList({ posts }: { posts: BlogPostMeta[] }) {
+ if (posts.length === 0) {
+ return <p style={{ color: "var(--fg-3)" }}>No posts yet.</p>;
+ }
+
+ return (
+ <ul
+ style={{ listStyle: "none", padding: 0, margin: 0 }}
+ className="flex flex-col gap-3"
+ >
+ {posts.map((post) => (
+ <li key={post.slug}>
+ <Link href={`/blog/${post.slug}`} className="blog-card group">
+ <div
+ className="text-[12px] mb-1.5"
+ style={{ color: "var(--fg-3)", fontFamily: "var(--font-mono)" }}
+ >
+ {formatDate(post.date)}
+ </div>
+ <div
+ className="text-[18px] font-medium transition-colors group-hover:text-[color:var(--fg-0)]"
+ style={{ fontFamily: "var(--font-display)", color: "var(--fg-1)" }}
+ >
+ {post.title}
+ </div>
+ {post.description && (
+ <p
+ className="mt-2 text-[14px] leading-relaxed line-clamp-2"
+ style={{ color: "var(--fg-3)" }}
+ >
+ {post.description}
+ </p>
+ )}
+ </Link>
+ </li>
+ ))}
+ </ul>
+ );
+}
+
+function formatDate(isoDate: string): string {
+ if (!isoDate) return "";
+ const d = new Date(isoDate + "T00:00:00Z");
+ if (Number.isNaN(d.getTime())) return isoDate;
+ return d.toLocaleDateString("en-US", {
+ year: "numeric",
+ month: "long",
+ day: "numeric",
+ timeZone: "UTC",
+ });
+}
diff --git a/website/components/blog-subscribe.tsx b/website/components/blog-subscribe.tsx
new file mode 100644
index 00000000..ac3e5561
--- /dev/null
+++ b/website/components/blog-subscribe.tsx
@@ -0,0 +1,97 @@
+"use client";
+
+import { useState, FormEvent } from "react";
+import { Eyebrow } from "@/components/eyebrow";
+
+export function BlogSubscribe() {
+ const [email, setEmail] = useState("");
+ const [submitting, setSubmitting] = useState(false);
+ const [status, setStatus] = useState<"idle" | "success" | "error">("idle");
+
+ async function handleSubmit(e: FormEvent) {
+ e.preventDefault();
+ setSubmitting(true);
+ setStatus("idle");
+
+ try {
+ const res = await fetch("/api/subscribe", {
+ method: "POST",
+ headers: { "Content-Type": "application/json" },
+ body: JSON.stringify({ email: email.trim() }),
+ });
+ setStatus(res.ok ? "success" : "error");
+ } catch {
+ setStatus("error");
+ } finally {
+ setSubmitting(false);
+ }
+ }
+
+ const inputStyle: React.CSSProperties = {
+ background: "color-mix(in oklab, var(--ink-0) 60%, transparent)",
+ border: "1px solid var(--hair-2)",
+ color: "var(--fg-0)",
+ fontFamily: "var(--font-mono)",
+ };
+
+ return (
+ <div
+ className="mt-16 rounded-[14px] p-6 md:p-8"
+ style={{
+ background:
+ "linear-gradient(180deg, color-mix(in oklab, var(--ink-2) 80%, transparent), color-mix(in oklab, var(--ink-1) 60%, transparent))",
+ border: "1px solid var(--hair-2)",
+ boxShadow: "0 30px 60px -30px rgba(0, 0, 0, 0.5)",
+ }}
+ >
+ <Eyebrow>Subscribe</Eyebrow>
+ <h3
+ className="mt-3 mb-2 text-[20px] font-medium"
+ style={{ fontFamily: "var(--font-display)", color: "var(--fg-0)" }}
+ >
+ Get new engineering posts in your inbox
+ </h3>
+
+ {status === "success" ? (
+ <p
+ className="mt-3 text-[14px]"
+ style={{ color: "var(--fg-2)", fontFamily: "var(--font-mono)" }}
+ >
+ Thanks — we&apos;ll email you when we publish.
+ </p>
+ ) : (
+ <form
+ onSubmit={handleSubmit}
+ className="mt-4 flex flex-col sm:flex-row gap-3"
+ >
+ <input
+ type="email"
+ required
+ value={email}
+ onChange={(e) => setEmail(e.target.value)}
+ placeholder="[email protected]"
+ aria-label="Email address"
+ className="flex-1 px-4 py-3 rounded-md text-[15px] outline-none focus:border-[color:var(--a1)] transition-colors"
+ style={inputStyle}
+ />
+ <button
+ type="submit"
+ disabled={submitting}
+ className="btn btn-accent px-8 py-3 justify-center disabled:opacity-60 disabled:cursor-not-allowed"
+ >
+ {submitting ? "Subscribing…" : "Subscribe"}
+ </button>
+ </form>
+ )}
+
+ {status === "error" && (
+ <p
+ className="mt-3 text-[13px]"
+ style={{ color: "var(--crit)", fontFamily: "var(--font-mono)" }}
+ >
+ Something went wrong. Please try again.
+ </p>
+ )}
+ </div>
+ );
+}
diff --git a/website/components/blog-tabs.tsx b/website/components/blog-tabs.tsx
new file mode 100644
index 00000000..d67cf1e3
--- /dev/null
+++ b/website/components/blog-tabs.tsx
@@ -0,0 +1,27 @@
+import Link from "next/link";
+
+type Tab = { label: string; href: string; key: "release" | "engineering" };
+
+const TABS: Tab[] = [
+ { label: "Releases", href: "/blog", key: "release" },
+ { label: "Engineering", href: "/blog/engineering", key: "engineering" },
+];
+
+export function BlogTabs({ active }: { active: "release" | "engineering" }) {
+ return (
+ <div className="mb-12">
+ <nav className="blog-tabs">
+ {TABS.map((tab) => (
+ <Link
+ key={tab.key}
+ href={tab.href}
+ aria-current={tab.key === active ? "page" : undefined}
+ className={`blog-tab${tab.key === active ? " blog-tab-active" : ""}`}
+ >
+ {tab.label}
+ </Link>
+ ))}
+ </nav>
+ </div>
+ );
+}
diff --git a/website/components/site-footer.tsx b/website/components/site-footer.tsx
index c304cf74..3af2b946 100644
--- a/website/components/site-footer.tsx
+++ b/website/components/site-footer.tsx
@@ -29,6 +29,8 @@ const COLUMNS: Column[] = [
{
heading: "Resources",
links: [
+ { label: "Blog", href: "/blog/engineering" },
+ { label: "Release Notes", href: "/blog" },
{ label: "Docs", href: "https://docs.tracewayapp.com", external: true },
{ label: "GitHub", href: "https://github.com/tracewayapp/traceway", external: true },
{
diff --git a/website/components/site-header.tsx b/website/components/site-header.tsx
index f694e0e3..9efc4587 100644
--- a/website/components/site-header.tsx
+++ b/website/components/site-header.tsx
@@ -231,7 +231,7 @@ export function SiteHeader() {
Cloud
</Link>
<Link
- href="/blog"
+ href="/blog/engineering"
className="h-9 px-3 rounded-md inline-flex items-center text-[14px] font-medium transition-colors text-[color:var(--fg-1)] hover:text-[color:var(--fg-0)] hover:bg-[color:var(--ink-2)]"
style={{ fontFamily: "var(--font-display)" }}
>
diff --git a/website/content/blog/flutter-session-replay.mdx b/website/content/blog/flutter-session-replay.mdx
new file mode 100644
index 00000000..26d0162d
--- /dev/null
+++ b/website/content/blog/flutter-session-replay.mdx
@@ -0,0 +1,160 @@
+---
+title: "Flutter Session Replay: See What the User Did"
+date: "2026-04-16"
+category: "engineering"
+description: "The missing layer of mobile observability. Open source session replay for Flutter: architecture, benchmarks, and everything I ruled out first."
+---
+
+Before we get into it, a few things upfront. I’m the person building Traceway. This isn’t a sponsored post or a polished launch announcement. Everything you’ll see here is open source. If you enjoy this article, the code is available in [Traceway](https://github.com/tracewayapp/traceway) and [Traceway Flutter](https://github.com/tracewayapp/traceway-flutter) Github repos.
+
+![Flutter session replay screenshot](/blog/flutter-session-replay/img1.webp)
+
+Session replay started as a question I couldn’t let go of: can this be done in Flutter without impacting the performance of the app or your cloud bill in a major way? The answer turned out to be **yes**.
+
+I’ve been using session replays for web development and they have been incredibly helpful. Logs and stack traces are good but they don’t provide visual context, making it very hard to understand the interactions that led to the issue. Visual context is the missing layer of mobile observability.
+
+There are many tools that offer different types of session replays for native and Flutter apps. None of the options I have seen are affordable, performant, and open source. Almost all seem to be focused on user behavior rather than providing the additional context for stack traces. In this article I’ll explain how I’ve built Traceway Flutter, how it impacts the performance of the app and how it keeps the cloud bills low.
+
+## 1. What Session Replay Actually Needs to Do
+
+After working through the design constraints, I landed on seven hard requirements:
+
+- capture a meaningful amount of time before the exception has occurred
+- be attached to the actual trace with the stack trace of the issue that has occurred
+- be playable in the browser
+- not degrade app performance
+- be affordable at scale
+- not impact permissions the user has granted
+- work on mobile and desktop devices
+
+## 2. Ruled Out Approaches
+
+The obvious solution to this problem is to record the full screen and just trim the last 10 seconds and upload that. Unfortunately, this breaks almost every single requirement. Let’s look at different parts of this approach and why some technologies have to be avoided.
+
+## 2a. FFmpeg On-Device
+
+FFmpeg is an incredible project, it was the first thing I reached for. I’ve used it to record and stream multiple different devices in the past including for an application that allows remote control of a desktop computer. Unfortunately, the FFmpeg library did not work well at all. It was capturing the full screen (not just the app), which required elevated permissions; it also led to higher CPU and battery usage. The replacement for screen recording was to use the RepaintBoundary Flutter widget.
+
+## 2b. Raw RGBA Frames
+
+RepaintBoundary was great at exporting the picture of the widgets that it contained. Unfortunately, it did not export users’ interactions (clicks/touches). This made the videos very hard to view. To address this, I decided to just draw user interactions on the frames themselves. This worked, but exporting the RGBA image from the RepaintBoundary led to an in-memory buffer of over 500MB (more about this later) making it unusable. To limit the size of the images the frames had to be stored as PNGs, leading to the memory requirements of ~10MB.
+
+To better show how crippling this is, here is a visualization of the impact it would have on a device with 600MB of RAM:
+
+![Flutter session replay screenshot](/blog/flutter-session-replay/img2.webp)
+
+## 2c. Platform Channel Video Recording
+
+Using native iOS/Android screen recording APIs via platform channels was unfortunately not an option due to permissions friction and no access to Flutter widget tree for redaction.
+
+## 3. The Architecture That Works
+
+The system has four layers: capture, buffer, encode, and sync. During normal operation only the first two are active.
+
+The Traceway widget wraps your app in a RepaintBoundary and a Listener. Every 67 milliseconds, the ScreenRecorder calls toImage() on the RepaintBoundary, converts the result to PNG bytes, pairs it with the current touch position and any active privacy mask regions, and pushes the frame into a circular buffer of 150 slots. When the buffer is full the oldest frame is silently overwritten. That’s the entire cost of normal operation: a timer, a screenshot, and a buffer write.
+
+When an exception occurs, three hooks funnel the error into the TracewayClient: FlutterError.onError, PlatformDispatcher.onError, and runZonedGuarded. The client formats the stack trace, collects device metadata, writes the exception to disk, and triggers encoding. The ScreenRecorder drains the circular buffer, decodes each PNG back to raw pixels, applies privacy masks and touch indicators, and feeds the frames one at a time into a H.264 encoder. An encoding lock ensures only one encode runs at a time, so rapid exception bursts don’t stack up. The resulting MP4 gets attached to the exception payload and the exception payload gets sent to the server.
+
+Once encoding completes, the sync layer waits 1.5 seconds to batch any concurrent exceptions, compresses the payload, and POSTs it to the Traceway server. On success the local files are deleted. On failure it retries after 10 seconds. If there is no network, the files sit on disk, capped at 5 files and 12 hours (configurable with a parameter), and sync automatically when connectivity comes back.
+
+## 3a. RepaintBoundary: The Capture Layer
+
+RepaintBoundary is a Flutter Widget that is the backbone of the screen recording. It has a function `toImage()` that exports the snapshot of the widget tree without using the screenshot API, meaning no new permissions are needed. This approach is Flutter native and captures only what the engine has already rendered.
+
+The downside of the RepaintBoundary is that it does not record user interactions, so pointer events are not visible. To show the pointer events we added a listener that wraps the widget.child before passing it to the RepaintBoundary, allowing us to understand interactions with the app.
+
+```dart
+RepaintBoundary(
+ child: Listener(
+ onPointerDown: _onPointerDown,
+ onPointerMove: _onPointerMove,
+ onPointerUp: _onPointerUp,
+ child: widget.child,
+ ),
+);
+```
+
+After we call `toImage()` we “enhance” the image by adding user inputs to the image (if any touch events are active) and we also blur out parts of the image containing the data that should be masked (more about this in the _Privacy & Redaction_ section).
+
+## 3b. The Scale Factor and FPS Decision
+
+To meet the performance requirements, primarily to limit the memory footprint, we set the default scale factor of 0.75 and the default FPS at 15. This tradeoff is possible because complex animations don’t matter much when analyzing the users’ actions. We’re always keeping 10 seconds of snapshots at 15 FPS, which leads to a total of 150 frames in memory (even when no exceptions have taken place). Each frame is a PNG at 0.75 scale factor. UI screenshots compress heavily (mostly flat colors), typically 30–80KB per frame, so 150 frames ≈ 5–12MB. At encode time, only one raw frame (~5MB) is ever in memory. Scale factor and the FPS are adjustable through the Traceway widget setup API.
+
+## 3c. Storing The Recordings
+
+To further limit the memory usage of the application and to make exceptions durable, we don’t keep exceptions and recordings in memory. Instead, we write them to the device’s storage. If no network is available, recordings sync when connectivity is restored. We limit the number of recordings and how long they are stored. Both limits are parameters of the Traceway init that can be optimized.
+
+## 3d. CPU: Encoding on Exception Only
+
+The key to keeping the CPU usage low is to only encode when the exception happens. Because exceptions are not frequent, the overhead of encoding is nonexistent. The Benchmarks section covers MP4 encoding overhead in detail. During normal operation the CPU cost is negligible. The app is only capturing screenshots and storing PNGs.
+
+## 4. Storage Architecture & Cost
+
+To lower the costs Traceway stores videos in an S3-compatible storage. On my personal device (iPhone 17 pro max) the recording came out at 250KB for 10 seconds, meaning 1TB of S3 Standard storage, costing around $23/month, holds approximately 4 million recordings. MP4 is extremely efficient with this content because the frames in most apps are similar to one another.
+
+## 5. Privacy & Redaction
+
+Some applications need to have the ability to opt out of having some of their data captured. To mask a widget in the video we use the TracewayPrivacyMask widget, it blurs the content by default but can also fully hide it by passing in the mode parameter (e.g. TracewayMaskBlank).
+
+```dart
+TracewayPrivacyMask(
+ child: Text('Counter: $_counter'),
+)
+// or
+
+TracewayPrivacyMask(
+ mode: TracewayMaskBlank(),
+ child: Text('Counter: $_counter'),
+)
+```
+
+![Flutter session replay screenshot](/blog/flutter-session-replay/img3.webp)
+
+## 6. Developer Experience
+
+Integration is straightforward. Developers wrap their application in the Traceway widget with their desired configuration. The default configuration is recommended as it has a great balance between costs, performance and quality. This is enough to get all exceptions and session replays sent to the Traceway server.
+
+```dart
+Traceway.run(
+ connectionString: 'your-token@https://cloud.tracewayapp.com/api/report',
+ options: TracewayOptions(
+ screenCapture: true,
+ version: '1.0.0',
+ ),
+ child: MyApp(),
+);
+```
+
+This library can be used with MacOS, iOS and Android. For Flutter web projects the JS SDK should be used, see [Flutter Web](https://pub.dev/packages/traceway#flutter-web).
+
+## 7. Full Benchmark Summary
+
+The table below consolidates every measurement from the benchmarks discussed throughout this article. The full benchmark can be found [here](https://github.com/tracewayapp/traceway-flutter/actions/runs/24475576776/artifacts/6460405467). Metrics marked with a dagger (†) are engineering estimates derived from code constants rather than automated harness output, encoding time, upload latency, and cost-per-session instrumentation are planned additions to future harness iterations.
+
+I designed the benchmark workloads to mirror how people actually use mobile apps, not synthetic stress tests. The scenarios: idle rendering, list scrolling, page navigation, and video playback each have a dedicated burst variant that fires five exceptions in rapid succession. A standalone exception burst scenario covers the full-interaction flow and serves as the de facto full-interaction burst. Each scenario runs under four SDK configurations: no SDK at all (the baseline), SDK with error capture only, SDK with screen recording at 15 FPS, and the full stack with disk persistence enabled. This four-level matrix lets us isolate exactly where overhead comes from: the error hooks themselves add virtually nothing, the 15 FPS capture loop adds 14–29 MB of memory in steady-state idle conditions (other scenarios vary due to GC timing) and zero measurable frame-time regression, and disk persistence adds a small incremental cost on top. Importantly, the frame build p50 with Traceway enabled is consistently _at or below_ the baseline, the capture timer doesn’t compete with the render pipeline, so the _"below the baseline"_ can be attributed to regular testing noise.
+
+I ran all Android tests on Firebase Test Lab across three device tiers: Pixel 5 (API 30, representing low-end), Pixel 6 (API 33, mid-range), and Pixel 8 (API 34, flagship), providing coverage from budget hardware to current-generation silicon. iOS benchmarks on iPhone 8 (iOS 16.6), iPhone 13 Pro (iOS 17.5), and iPhone 15 Pro (iOS 18.0) are planned and will be added to the harness in a future iteration. The results presented in this report are Android-only. I measured frame timing using Flutter’s built-in `FrameTiming` callback (build + raster durations, p50/p90/p99/max), sampled memory via `ProcessInfo.currentRss` and peak RSS, and timed exception capture cost as wall-clock microseconds around each `captureException` call.
+
+Each scenario ran as a Flutter integration test inside the example app, driven by `testWidgets`, with a settle window after exception bursts (10 seconds for most scenarios, 3 seconds for the video playback burst) to let encoding and sync complete before I finalized the metrics.
+
+Based on these numbers this approach is safe to run in production with screen recording enabled. There is no frame-time regression at p50 on any device tier, jank counts are flat during normal operation (and often lower than baseline), and memory overhead is bounded and predictable. During exception burst scenarios jank does increase, up to 3x on lower-end devices, which is expected given the encoding work triggered at that moment. Even in the worst case (an exception burst on the Pixel 8, the highest-memory scenario at +69.5 MB), peak RSS stays under 70 MB above baseline. That said, the harness doesn’t yet automate encoding wall-clock time, upload latency, or cost-per-session metrics, and those are on the roadmap.
+
+I took ideas from the FlutterDev community, implemented them, and ran them through the benchmark harness. Some moved the needle, some didn’t. The original post and discussion are linked [here](https://www.reddit.com/r/FlutterDev/comments/1shs4ap/i_built_opensource_session_replay_for_flutter/).
+
+This is where you come in: if you think you can do better, open the PR. If you have ideas for reducing the memory footprint, speeding up PNG capture, or optimizing the H.264 encoding path, implement it and open the PR, I’ll trigger the CI and we will see exactly what changed, on real hardware, before anything gets merged. I built this infrastructure specifically so that performance claims are backed by data; every improvement (or regression) is measured and visible.
+
+## 8. Conclusion
+
+Session replay for Flutter is a solved problem, but only if you’re willing to pay for a closed-source SaaS tool that treats observability as a premium feature. Traceway was built on the premise that it doesn’t have to be that way.
+
+RepaintBoundary capture, deferred MP4 encoding, S3-compatible storage, and a circular frame buffer together prove that you can have meaningful visual context around your exceptions without sacrificing frame time, bloating memory, or surprising your users with new permission prompts. The benchmarks back this up: zero measurable frame-time regression across multiple real devices, predictable memory overhead, and storage costs that stay flat even at scale.
+
+The harness has gaps. It doesn’t yet measure encoding wall-clock time or upload latency end-to-end, and there are likely optimizations left on the table in the PNG capture and H.264 encoding paths. This is exactly why it’s open source.
+
+If you see something that can be done better, open a PR. Every change gets measured on real hardware before it merges, no “it felt faster.” Either the numbers improve or they don’t.
+
+The next goal is equivalent implementations for iOS, Android, and React Native. If you work in any of those ecosystems and want to take a swing at it, reach out or open an issue. I’d rather build this together than alone.
+
+Special thanks to: u/chimbori, u/__o_ — _o__, u/Deep_Ad1959, u/g0rdan and everyone else from the FlutterDev community on Reddit, whose feedback directly shaped several of the optimizations described here.
+
+The code is available in the [Traceway](https://github.com/tracewayapp/traceway) and [Traceway Flutter](https://github.com/tracewayapp/traceway-flutter) repositories. You can also reach out directly by sending me an email at [email protected] or adding me on [LinkedIn](https://www.linkedin.com/in/dusanstanojeviccs).
diff --git a/website/content/blog/sqlite-observability-stack.mdx b/website/content/blog/sqlite-observability-stack.mdx
new file mode 100644
index 00000000..6937695e
--- /dev/null
+++ b/website/content/blog/sqlite-observability-stack.mdx
@@ -0,0 +1,99 @@
+---
+title: "I Ran My Entire Observability Stack on SQLite. You Probably Could Too."
+date: "2026-05-29"
+category: "engineering"
+description: "Most observability stacks optimize for throughput your startup will never use. We optimized for accessibility instead — easy and cheap to run — and hit 58K metric points/sec anyway. Here is the full benchmark."
+---
+
+## TL;DR
+
+Traceway runs on ClickHouse or SQLite depending on your scale. This post benchmarks the SQLite mode. On a $16.49/month Hetzner box (2 dedicated vCPU, 8 GB RAM, 80 GB NVMe SSD), a single binary running the full observability stack (metrics, logs, traces, RUM, alerting, exceptions) on SQLite hit:
+
+- **31k metric points/sec** on large payloads (8k points/request)
+- **58k metric points/sec** at the largest sustainable payload
+- **36k metric points/sec** at 100 points per request
+
+Methodology and full results below. Short version: SQLite is doing a lot more than people give it credit for, and you almost certainly do not need a dozen-plus-component LGTM deployment to run a side project.
+
+## Why are you doing this?
+
+Observability is a set of trade-offs.
+
+A good observability stack will provide: metrics, logs, traces, RUM, alerting and exceptions (symbolicated). To get that stack, the two most popular options are:
+
+1. Pay Datadog, New Relic, Sentry.
+2. Self-host the LGTM stack: Alloy, Prometheus or Mimir or VictoriaMetrics, Loki or VictoriaLogs, Tempo, Pyroscope, Alertmanager, Grafana, Grafana OnCall, Faro, Sentry…
+
+Option one is the most expensive. You pay for convenience, the free tiers are tight, and I've managed to blow through them on side projects that barely had users.
+
+Option two covers everything but introduces two problems. It's not easy to host. That's a lot of moving parts and a lot of potential points of failure. And it's resource-intensive; giving each component enough headroom to actually do its job adds up fast. The upside is that it scales incredibly well, if you need it to.
+
+But we're talking about ingesting a protobuf and writing it to a database when the backend gets a request. Let's find out how hard that is to do.
+
+The real question I wanted to answer: what is the smallest server I could run a full observability stack on, and what does throughput look like when I stop caring about scaling to a million pods?
+
+## Methodology
+
+I've been building a ClickHouse-first observability platform. The goal of the platform was accessibility and providing the experience of Datadog/New Relic/Sentry on top of OpenTelemetry data. Obviously hosting ClickHouse is not going to happen on the $5 tier server from Railway, so I've implemented the database layer with SQLite as well. This is the setup we will be measuring: a single binary packed with all parts of the observability stack running with SQLite persisted on disk.
+
+All of the tests have been performed on a dedicated-vCPU instance, specifically the cheapest dedicated-vCPU Hetzner instance, the CCX13 (2 dedicated vCPU, 8 GB RAM, 80 GB NVMe SSD), starting at $16.49 per month. Load generation is happening on a separate server.
+
+We will be measuring throughput of metrics in three phases:
+
+1. **Large payload** — 16k max metric points per payload, 5 req/sec max
+2. **Largest sustainable payload, max request rate** — taking the largest sustainable payload we max out req/sec to find the breaking point
+3. **100 metric points per req** — how many requests per second can we ingest
+
+### What "accepted" means here
+
+Traceway's ingestion endpoint only returns 200 once the payload has been written to SQLite. There's no in-memory buffer in front of the database, so a successful response is a durable write. P99 latency stayed under 400ms even on the largest payloads, which means the throughput numbers below reflect sustained ingest, not a queue filling up faster than it drains.
+
+### Pass/fail thresholds
+
+A test is considered failed if:
+
+- Combined error rate `> 5%`
+- Soft cliff: achieved rate `< 70%` of target
+
+A given request rate is considered successful after it survives for 2min under that load. The benchmark then ramps to the next level and repeats. The headline number is the maximum sustained items/sec across all passing steps.
+
+These three phases measure write throughput only; read performance is out of scope for this post, but will be covered in the future.
+
+## Analysis and SQLite optimizations
+
+When I first ran the tests, the max throughput I was able to achieve peaked at 15k metrics/sec on the CCX13 instance. The biggest optimization win came from wrapping the batches of inserts into a transaction. Combined with a slightly bigger cache it almost quadrupled the throughput. No other real optimizations were done at this stage. Possible ideas I'll be exploring over the next few weeks to push this further:
+
+- **Centralized writer that batches events in memory before inserting.** Note that this is a deliberate durability/throughput trade-off: buffering in memory before the write means a successful response would no longer guarantee a durable write, so it gives up the "200 = persisted" property described above in exchange for higher throughput.
+- Building multi-row insert statements instead of single-row ones
+
+## Systems usually fail after 2 weeks, not instantly
+
+The obvious pushback: systems like this usually fail two weeks in, not at hour one. Agreed, you should NOT use SQLite as your production system pushing 50k metrics/sec anyway.
+
+I am proposing that you optimize your costs to your scale. If your scale is small you should use tools that give you the best cost/performance at that scale. If your scale allows, there is nothing that can beat running a single binary with SQLite, your surface area for failure is minimal, a single tool that is easy to set up and monitor in production. This all makes sense only if you're self-hosting due to regulatory reasons or personal preference.
+
+Here is when this configuration makes sense:
+
+- Exception tracking + RUM for Mobile (Flutter/Android/iOS)
+- Exception tracking + RUM for Frontend
+- Monolith backends for internal tooling
+- Side projects
+- Early startups
+
+Here is the breakdown of potential loads that this setup can handle easily:
+
+- **Metrics:** 5 servers × 20 metrics/sec = 100 inserts/sec
+- **Traces:** 5 servers × 10 req/sec = 50 inserts/sec
+- **Logs and Spans:** 5 servers × 10 req/sec × (10 spans + 50 logs) = 3000 inserts/sec
+
+This adds up to 3.15k inserts per second, which SQLite will handle easily. As we're assuming costs are the main concern, you could limit your retention to seven days. With that you are almost guaranteed to stay within your server's limits, even when both memory and CPU are constrained.
+
+A much larger deployment can be supported if you're only doing exception tracking with RUM, as exceptions are rare in general and it's pretty hard to hit even 10k exceptions/sec.
+
+## Conclusion
+
+I've had a bunch of fun setting up the benchmarks and seeing the results. Honestly, SQLite has performed better than expected. It also helps with specifying the minimum requirements for running Traceway and the performance that can be expected. Now that the benchmarks are set up, I am looking forward to all the future data I'll be able to pull from the system.
+
+You can find the results of all runs in the Traceway repo: [https://github.com/tracewayapp/traceway](https://github.com/tracewayapp/traceway). If you have any questions, feel free to reach out at [email protected].
+
+**Next post:** same setup, a full week of real data flowing through it. Logs, traces, what actually breaks, and whether the SQLite story holds up past hour one, querying common endpoints while writing. After that we move to ClickHouse and find out what the bigger machine actually buys you.
diff --git a/website/functions/worker.ts b/website/functions/worker.ts
index 649aadbc..71660d0c 100644
--- a/website/functions/worker.ts
+++ b/website/functions/worker.ts
@@ -12,6 +12,10 @@ export default {
return handleContact(request, env);
}
+ if (url.pathname === "/api/subscribe" && request.method === "POST") {
+ return handleSubscribe(request, env);
+ }
+
return new Response("Not Found", { status: 404 });
},
};
@@ -86,3 +90,63 @@ Company size: ${companySize}
);
}
}
+
+async function handleSubscribe(request: Request, env: Env): Promise<Response> {
+ try {
+ const data = await request.json<any>();
+ const email = typeof data.email === "string" ? data.email.trim() : "";
+
+ if (!email || !/^[^@\s]+@[^@\s]+\.[^@\s]+$/.test(email)) {
+ return new Response(JSON.stringify({ error: "Invalid email" }), {
+ status: 400,
+ headers: { "Content-Type": "application/json" },
+ });
+ }
+
+ const msg = {
+ personalizations: [
+ {
+ to: [{ email: env.SENDGRID_TO_EMAIL }],
+ },
+ ],
+ from: { email: env.SENDGRID_FROM_EMAIL },
+ reply_to: { email },
+ subject: `New blog subscriber: ${email}`,
+ content: [
+ {
+ type: "text/plain",
+ value: `New blog subscriber from the Traceway Engineering blog:\n\nEmail: ${email}`,
+ },
+ ],
+ };
+
+ const response = await fetch("https://api.sendgrid.com/v3/mail/send", {
+ method: "POST",
+ headers: {
+ Authorization: `Bearer ${env.SENDGRID_API_KEY}`,
+ "Content-Type": "application/json",
+ },
+ body: JSON.stringify(msg),
+ });
+
+ if (!response.ok) {
+ const errorText = await response.text();
+ console.error("SendGrid Error:", errorText);
+ throw new Error(`SendGrid API error: ${response.status}`);
+ }
+
+ return new Response(JSON.stringify({ success: true }), {
+ status: 200,
+ headers: { "Content-Type": "application/json" },
+ });
+ } catch (error) {
+ console.error("Error processing subscribe request:", error);
+ return new Response(
+ JSON.stringify({ error: "Internal Server Error" }),
+ {
+ status: 500,
+ headers: { "Content-Type": "application/json" },
+ }
+ );
+ }
+}
diff --git a/website/lib/blog.ts b/website/lib/blog.ts
index 21cbb092..10e6c6d4 100644
--- a/website/lib/blog.ts
+++ b/website/lib/blog.ts
@@ -4,11 +4,15 @@ import matter from "gray-matter";
const BLOG_DIR = path.join(process.cwd(), "content", "blog");
+export type BlogCategory = "release" | "engineering";
+
export type BlogPostMeta = {
slug: string;
title: string;
date: string;
version?: string;
+ category: BlogCategory;
+ description?: string;
};
export type BlogPost = BlogPostMeta & {
@@ -23,7 +27,11 @@ function readPostFile(filename: string): BlogPost | null {
const title = typeof data.title === "string" ? data.title : slug;
const date = typeof data.date === "string" ? data.date : "";
const version = typeof data.version === "string" ? data.version : undefined;
- return { slug, title, date, version, content };
+ const category: BlogCategory =
+ data.category === "engineering" ? "engineering" : "release";
+ const description =
+ typeof data.description === "string" ? data.description : undefined;
+ return { slug, title, date, version, category, description, content };
}
export function getAllPosts(): BlogPostMeta[] {
@@ -36,6 +44,10 @@ export function getAllPosts(): BlogPostMeta[] {
.map(({ content: _content, ...meta }) => meta);
}
+export function getPostsByCategory(category: BlogCategory): BlogPostMeta[] {
+ return getAllPosts().filter((p) => p.category === category);
+}
+
export function getPostBySlug(slug: string): BlogPost | null {
const filename = `${slug}.mdx`;
const filepath = path.join(BLOG_DIR, filename);
diff --git a/website/public/blog/flutter-session-replay/img1.webp b/website/public/blog/flutter-session-replay/img1.webp
new file mode 100644
index 00000000..dbbf40cf
Binary files /dev/null and b/website/public/blog/flutter-session-replay/img1.webp differ
diff --git a/website/public/blog/flutter-session-replay/img2.webp b/website/public/blog/flutter-session-replay/img2.webp
new file mode 100644
index 00000000..5e343ffd
Binary files /dev/null and b/website/public/blog/flutter-session-replay/img2.webp differ
diff --git a/website/public/blog/flutter-session-replay/img3.webp b/website/public/blog/flutter-session-replay/img3.webp
new file mode 100644
index 00000000..341b7a01
Binary files /dev/null and b/website/public/blog/flutter-session-replay/img3.webp differ