Vyankatesh Sabu

Six months building Fleetcore

What I built at Fleetway, what broke, and what it taught me about owning software people depend on.

Written by
Vyankatesh Sabu
Period
May to October 2026
Published
4 November 2026
Reading time
12 minutes

May 2026

I expected CRUD

On 18 May 2026 I joined Fleetway as a backend intern. I assumed I'd spend the summer writing list endpoints and fixing small bugs while someone senior handled the parts that mattered.

On my second day I pushed code that changed how a trip moves to its next stage when a driver uploads proof of delivery. Real trucks, real drivers, real money.

Fleetway builds fleetcore, a platform that runs long-haul trucking fleets across Southern and Central Africa. A single trip can cross several borders over a week or more. Fleetcore tracks the truck (in fleet language, the "horse"), the trailer, the driver, the load, the fuel, the permits needed at each crossing, and the money spent on the way. Every client gets its own deployment: its own database, its own domain, its own copy of the backend. It's written in Kotlin and Spring Boot, on PostgreSQL, behind Traefik on a VPS.

Six months later, this is the story of what I built and what it taught me.

May 2026

Learning the business through purchase orders

My first real feature was subsistence purchase orders: the daily allowance a driver gets for food and lodging on a long trip. It sounds simple until you learn that the amount depends on the route, the client's rates, how many days the trip runs and when the previous trip ended. I built the CRUD, then automated generation for regular trips, then an endpoint that shows exactly how each amount was calculated, because the finance team kept asking.

Contractor POs came next, then organisation rates, supplier dashboards, fuel rate history across 60 months and PDF and Excel exports for everything. None of it was glamorous. All of it taught me the business. By the end of May I could explain why a border PO needs to know which side of the border it's on.

June to August 2026

Owning a finance module

In June I was handed something bigger: a cashbook. Field agents carry cash on the road and spend it on tolls, permits and repairs. The company needed every one of those transactions recorded, approved and reconciled.

I built the core over two days in mid-June: cashbooks, locations, debit and credit entries, invite-by-link and a hierarchy of admins, agents and sub-agents. Then I spent most of the next two months making it trustworthy.

Finance software has one job: the numbers must not lie. So:

  • Once an entry is posted, it can't be edited or deleted.
  • No entry can be dated before the last posted one, so nobody can quietly rewrite last month.
  • Each user sees only the cashbooks they've been granted, enforced row by row, not just by role.
  • Money moving between two cashbooks, or between a bank and a cashbook, is a single contra transfer, so both sides always agree.

The module grew into a full bank ledger with opening and closing balances, document attachments and date-filtered summaries. It was the first time I owned a system rather than a ticket.

July 2026

The week I learned to distrust zero

July was my busiest month, and its most important week was spent reading code, not writing it.

I'd built a feature for trucks that drive empty to their loading point: the segments before loading should be costed at zero tonnage, since an empty truck burns less fuel. It worked in the fuel totals. Then I noticed the refuel optimiser, the part that decides where to buy fuel and how much, still assumed a full load on every segment. Two parts of the same system disagreed about reality.

That sent me through the whole fuel subsystem. There turned out to be three separate calculators plus the optimiser, and three of those four parts had the same quiet flaw. If a route segment had no fuel-consumption data for that truck, the calculator logged a warning and costed it at zero. The result was a total that looked perfectly plausible and was simply wrong.

The fix was obvious: throw an error naming every missing segment. The consequence was not. When I tested it, no truck model in the database had complete data for one of the busiest routes. Throwing at trip creation would have blocked every new trip on that route until someone backfilled the data.

So I traced who actually used these numbers. Only one action did: generating fuel purchase orders. I moved the calculations there, split "make sure it's calculated" from "make sure it's purchased", and let trips be created freely. The error now fires exactly when the number matters, and never silently.

The same week I froze fuel rates and route expenses onto each trip at creation, so editing a route or a supplier later can never change what a past trip cost.

Make wrong data loud.A crash gets fixed the same day. A number that's quietly wrong gets trusted for months.

August 2026

Teaching a model to read a passport

In August I built the part of the platform I'm proudest of technically: document intelligence.

Every driver and truck needs a stack of paperwork: passports, driving licences, national ID cards, vehicle registration, road-tax and fitness certificates, COMESA and cross-border permits, police clearance, tax clearance. Ops staff were typing all of it in by hand. I built a pipeline that reads a scan and returns structured fields for ten document types.

A few decisions shaped it:

  • Provider-agnostic from day one. Anthropic, OpenAI and Gemini sit behind one interface. Each uses its vendor's native structured-output mode instead of asking politely for JSON, and refusals or truncated answers are caught even though all three vendors return them as HTTP 200.
  • One YAML template per document type decides which fields come back, so adding a new document is configuration, not code.
  • Files are stored by their SHA-256 hash, and the cache key includes the tenant, document type, template version, provider and model. A template edit or model switch can never serve a stale answer, and two clients sharing a cache can never see each other's passports.

Then I built a rate limiter, and it taught me the second lesson of the internship.

My first design was a leaky bucket in an atomic Redis Lua script: requests arriving too fast would wait their turn instead of being rejected, sized so a truck's full set of documents went through in one sitting. It was elegant, and every test of the script passed.

Then I load-tested it against the running app. Twelve queued requests each held a database connection while they waited, and the pool only had five. An unrelated endpoint that normally answered in 0.06 seconds took 11 seconds. The rate limiter was protecting one endpoint by stalling the entire application.

Response time of an unrelated endpoint during the load test. The limiter's queue held five pooled connections, so everything else waited behind it.

I rewrote it the same day to refuse instead of queue, with burst tolerance so a truck's documents still went through at once. Measured again, all seven of a truck's documents were admitted together, and a burst of 25 concurrent requests was handled in under a second.

  • 7 of 7 documents admitted together
  • 13 of 25 burst requests admitted, the rest refused instantly

Measure before you trust your design.Mine was wrong, and only a real test could show it.

August to October 2026

From the database to the driver's phone

The people fleetcore matters most to are the drivers, and they don't sit at desks. So I built FleetApp, the native Android app they use on the road: live trips and routes, booking proposals, transit documents, load, weight and delivery photos, and daily and monthly earnings. It went into production in October.

The defining constraint is the road itself. On these corridors a driver can be without signal for hours. An app that spins or fails offline is useless, so FleetApp is offline-first:

  • Room is the local source of truth. The app always shows what it last knew, with an offline banner and the last sync time.
  • A photo taken with no signal is queued locally and uploaded by WorkManager once the network returns, surviving the app being closed or killed in between.

Because I also owned the backend, I could shape both sides of every contract, and that turned out to matter most for security.

The first version of the app worked out its own driver ID and sent it with every request. That's convenient, but it means the server is trusting the phone. So in August I rebuilt the driver side of the API around a single rule: the server decides who you are. Identity is resolved from the login on every request. Asking for something you don't own returns "not found", so IDs can't be probed. Signed file links expire in five minutes. While doing this I found 21 endpoints with no authorisation check at all, and made the app refuse to start if any endpoint is ever left unguarded again.

In September I replaced the single 24-hour login token with short-lived access tokens and single-use refresh tokens, stored in the Android Keystore on the phone. Driver sessions last weeks, not hours, so nobody gets logged out halfway through a long haul. The rollout was backwards compatible: app builds already on drivers' phones kept working until they updated.

Owning the app, the API and the security model at the same time taught me more than any one of them would have alone. Every shortcut on one side became a problem on the other.

August to October 2026

Deploying without anyone noticing

Every client runs its own copy of the backend, and early on every deploy meant a short outage while the old container stopped and the new JVM booted. In August I designed the zero-downtime deployment the platform now uses, and a teammate rolled it out.

The server's memory was tight, so running two full copies of every client permanently wasn't an option. The design is a single-slot blue-green swap:

  1. Boot alongsideThe new version starts beside the old. Memory peaks at about 1.2 containers for the 10 to 40 seconds a JVM needs.
  2. Join automaticallyBoth share one Traefik service name, so the new container joins the load balancer with no ports to juggle.
  3. Prove it's healthyTraffic moves only when Docker's, Spring Boot's and Traefik's health checks all agree.
  4. Drain the old oneThe old version finishes its in-flight requests within 30 seconds, then exits.

The existing auto-updater would have fought the swap, so I replaced it with a small systemd timer that polls for new images on the same schedule and runs the swap safely. One set of templated unit files serves every client.

In late October that same script gave me my first real production incident. Several clients' deploy timers fired in the same second, and each started its blue and green JVMs at once: up to eight Spring Boot processes fighting over four CPU cores. The server's load climbed past 13, every health check timed out, and the timers kept retrying the same pile-up. I confirmed the cause by serialising the stuck deploys by hand, and each went healthy on its first try. The fix was one host-wide lock that makes deploys wait in line instead of racing.

Along the way I cut CI image pushes from about 230 MB to about 6 MB per change by splitting dependencies into their own Docker layer, and built product-usage dashboards in Grafana (daily and weekly active users, feature usage, per-user errors and latency) entirely from logs the app was already writing.

August to October 2026

An agent, a video platform and a product in six days

An agent that can't overstep

In September I designed an AI agent that lets users ask fleetcore anything in plain language. The core decision was that the agent gets no permissions of its own: it calls the platform's existing APIs with the user's own token, so every rule that applies to the user applies to the agent automatically.

As tools multiplied, sending every tool's schema on every turn got expensive and made the model worse at choosing. So the agent first sees a short glossary of what each group of tools is for, and loads only the schemas it needs. A teammate built the core harness from that design; I then redesigned its tool surface, covering four more areas of the platform while cutting the tool descriptions sent per turn by a quarter. Every step is traced in Langfuse.

Tutorial videos for every client

In October I built a way for one admin console to publish training videos to every client's separate deployment. Each client gets a webhook when content changes and pulls the changes itself, with a five-minute reconciliation job as a backstop and signed, DRM-protected playback.

I built the first version on Cloudflare R2 with my own ffmpeg transcoding worker. Then the company chose Bunny Stream instead, and I rebuilt the storage layer in a day. The sync protocol survived untouched because I'd kept it independent of where the videos lived.

A whole product in six days

In late August I built store-management, a separate inventory system for a fleet's depots: spare parts, consumables and tyres, each consumption linked to a specific truck. At its heart is an append-only stock ledger with exactly one service allowed to write to it, and a test after every scenario asserting that balances equal the sum of movements. Around it: procurement with three-way invoice matching, a full tyre lifecycle across 11 wheel positions, approvals, physical counts and reports, all covered by 150 tests against a real database.

Then I made it multi-tenant: one deployment serving many organisations, each with its own database and storage bucket, chosen by a signed claim in the login token rather than by subdomain. Building that, I caught three bugs before they shipped, each of which would have let one customer see another's data. Onboarding a new organisation now takes three commands and no infrastructure changes.

Now

What I'm taking away

Looking back, the features blur together. The habits don't.

  1. Make wrong data loud.A crash gets fixed today. A plausible wrong number gets trusted for months.
  2. Freeze the past.Rates, expenses and routes are snapshotted onto each trip, and posted entries are locked, so editing today's data never rewrites yesterday's money.
  3. Measure before you trust a design.My rate limiter and my deploy script were both reasonable on paper and both broke under real load. The test that broke them was the most useful hour of each project.
  4. Let the server decide.Identity, permissions and tenancy belong on the server, re-checked on every request, never taken from the client.
  5. Write down what you didn't verify.Many of my commit messages end with exactly what was tested and what wasn't. It makes reviews honest, and it makes the next person's job easier.

I joined expecting to write CRUD for a summer. Instead I learned what it means to own software that people depend on: drivers on a border road with no signal, finance teams closing their books, a server with four cores and too many JVMs.

Thank you to my mentor, Abhinav Raj, for trusting an intern with production from the first week, and to the whole Fleetway team for the reviews and the patience.

Vyankatesh Sabu, backend and Android engineer

See my other work