Hi, I'm Tim.

I am a software developer based in Famagusta, Cyprus. My main languages are Rust, TypeScript and Python.

Latest articles all

Using actors for more robust Stripe integrations

Applying the actor model to billing for a scalable and fault-tolerant Stripe integration

Configuring HDMI output on a Raspberry Pi 4

How to configure Raspberry Pi 4 servers such that an HDMI monitor can be hot-plugged

Forays into using Raspberry Pi 4 as a home server

Discusses disk issues encountered while upgrading a Pi 3 to a Pi 4

Latest updates all

Published typex, a Rust library for runtime reflection. It can inspect, traverse and mutate objects without knowing their concrete types. The crate supports no_std and has no runtime dependencies or unsafe code.

For example, you can batch mutations and roll them back:

use typex::{MutationBatch, PatchOperation, PathSegment};

let mut values = vec![1_u8];
let batch = MutationBatch::from([
  PatchOperation::set([PathSegment::Item(0)], 2_u8),
  PatchOperation::push_item([], 3_u8),
]);

let rollback = batch.commit(&mut values).unwrap(); // [2, 3]
rollback.undo(&mut values).unwrap();               // [1]

Early benchmarks show faster builds and reflection operations than facet and bevy_reflect.

Published qstr, a Rust library for cache-efficient, stack-allocated string types.

Example:

use qstr::BStr15;
use qstr::StrVec;

let str: BStr15 = "aws:us:east:1".into();
let vec: StrVec<u16, 15> = str.split(":");

assert_eq!(
  vec.iter().collect::<Vec<_>>(),
  vec!["aws", "us", "east", "1"]
);

Built a lightweight blog server in Rust over the past few weekends. The page templates are specified in a custom DSL inspired by styled-components which is parsed with nom:

component Favicon {
  style {
    all: unset;
  }

  {if page == "main"}
    <FaviconImage />
  {else}
    <a style="cursor: pointer" href="/">
      <FaviconImage />
    </a>
  {end}
}

All code changes are published with Woodpecker CI to a local Docker Registry instance. The templates, articles and posts are stored on Hetzner S3 as tar.gz archives, and loaded into memory on startup. Internal endpoints reload the archives and make new content or style changes available without downtime.