HomeCase studiesA Connected Fuel Management and Tank Telemetry...

Case study · Hamburg, Germany

A Connected Fuel Management and Tank Telemetry Platform for Fleet Operators

Downstream fuel and fleet operations — on-site fuel dispensing, bulk storage tank management and fuel cost allocation

Commercial fleets running private fuel depots face recurring blind spots between bulk fuel deliveries, automated tank gauge readings, and what drivers actually dispense into vehicles. We engineered an end-to-end fuel management and tank telemetry platform combining a Java telemetry and pump-control backend, a MySQL transaction ledger, Redis live-state caching, a Vue fleet management portal, and a React Native driver mobile app built with TypeScript and Firebase. The system tracks real-time tank levels, authorizes on-site pump unlocks, captures odometer data offline, and reconciles every liter dispensed against cost centers and delivery invoices.

Industry
Downstream fuel and fleet operations — on-site fuel dispensing, bulk storage tank management and fuel cost allocation
Solution
An industrial IoT telemetry, pump authorization, and financial reconciliation platform spanning cloud ingestion services, a web operations console, and a cross-platform mobile driver app.
Platforms
Cross-platform · Web & API
Stack
Vue · React Native · React · TypeScript · MySQL · Redis
Location
Hamburg, Germany · delivered remotely
Role
Engineering, with the team behind for mobile and QA

Delivered remotely for a business based in Hamburg, Germany. Names withheld by agreement.

Project Overview

Organizations operating private bulk fuel depots—logistics carriers, municipal depots, construction yards, and port fleets—often lose visibility the moment fuel leaves a supplier's tanker and enters their own storage tanks. Paper clipboards at the pump, disconnected automatic tank gauges (ATGs), and manual spreadsheet reconciliations leave fleet managers unable to tie physical tank drops to specific vehicles, detect slow leaks or unauthorized draws, or close monthly cost-center accounting without days of detective work.

We built a connected fuel management and tank telemetry platform that links on-site dispensing hardware and bulk tank sensors directly to fleet accounting. Driven by a Java telemetry and control backend, MySQL immutable ledgers, Redis live-state coordination, a Vue web management console, and a React Native TypeScript mobile app, the platform gives operators real-time visibility from bulk delivery down to the individual vehicle fill-up.

Business Bottleneck

Unmonitored private fueling introduces two distinct operational leaks: physical inventory variance and administrative friction. Without electronic authorization at the nozzle, drivers skip odometer entries, select incorrect vehicle codes, or top off unlogged equipment. Meanwhile, tank gauge alarms sit trapped on local yard panels where nobody notices a sudden overnight drop or water-intrusion alert until a truck runs dry or a compliance audit flags missing volume.

Reconciling bulk tanker deliveries against pump totalizers across dozens of depots is equally painful when meter readings and gauge logs sit in separate silos. Engineering a reliable solution meant bridging industrial field gateways with modern web and mobile interfaces while keeping financial ledger consistency intact even when remote yard networks stutter.

Architectural Strategy

The platform separates real-time hardware coordination, immutable financial ledgering, and role-tailored user interfaces:

  1. Deterministic Java control & ingestion core: A dedicated Java backend processes continuous tank gauge polls, enforces pump state transitions, and executes variance calculations inside strongly typed, concurrency-safe services.
  2. Hot-state vs. ledger split: Redis holds ephemeral operational state—current tank fill levels, active pump leases, and alert cooldowns—while MySQL acts as the authoritative double-entry-style ledger for deliveries, dispense events, and cost allocations.
  3. Purpose-built client surfaces: Depot managers use a high-density Vue web console for multi-site analytics and accounting exports, while drivers use a streamlined React Native (React + TypeScript) mobile app at the dispenser.

Core Capabilities

  • Mobile & Cardless Pump Authorization: Drivers scan a pump QR code or select a site nozzle in the React Native app, enter or verify the vehicle and odometer reading, and trigger remote pump authorization without physical fleet cards.
  • Continuous Tank Telemetry & Strapping Conversion: Ingests liquid level, temperature, and water-bottom readings from bulk tank gauges, applying per-tank calibration strapping tables to display accurate net volume, ullage, and days-to-empty forecasts.
  • Automated Variance & Leak Alerting: Compares idle tank level changes against recorded dispensing events to surface suspected leaks, water ingress, or unrecorded draws via Vue dashboard banners and Firebase push alerts.
  • Delivery Reconciliation & Reorder Thresholds: Logs incoming bulk fuel tanker bills of lading alongside pre- and post-delivery gauge snapshots, flagging short deliveries and notifying dispatchers when sites cross reorder points.
  • Cost-Center & Fleet Allocation Exports: Tags every liter dispensed with vehicle, driver, project, and unit cost metadata, generating clean accounting extracts for enterprise finance teams.

Technical Architecture

Flow: Tank gauges & pump controllers -> Site IoT gateway -> Java ingestion & control services -> Redis live cache / MySQL ledger -> Vue operations console & React Native TypeScript mobile app (Firebase).

Field gateways transmit tank telemetry packets and pump meter events over TLS to the Java backend. Upon arrival, Java normalizes raw sensor frames, converts millimeter depth to calibrated liters using cached strapping curves, updates current tank state in Redis, and appends telemetry snapshots to MySQL. When a driver taps to fuel in the React Native app, the Java authorization service checks driver/vehicle eligibility and site credit/limit rules, claims an exclusive Redis lock for that nozzle with a strict TTL, and dispatches the unlock command to the site controller.

Once the nozzle hangs up and the final pulse count arrives, Java releases the Redis lease, writes an immutable dispense transaction in MySQL linked to the active delivery cost layer, and pushes updated tank totals to active Vue dashboard sessions and mobile notification channels via Firebase.

Technology Stack

Category Technology detail
Core backend & telemetry Java services for ATG gauge ingestion, pump control, and reconciliation
Web operations portal Vue single-page application for depot oversight, alerts, and cost exports
Mobile driver application React Native (React + TypeScript) for pump unlock and offline fill logging
Transactional ledger MySQL storing bulk deliveries, dispense events, tanks, vehicles, and cost centers
Live state & locking Redis for active pump leases, tank snapshots, and alert deduplication
Mobile push & diagnostics Firebase Cloud Messaging and Crashlytics for real-time depot alerts
Hardware integration Gateway protocols bridging automatic tank gauges (ATG) and dispenser controllers
Reporting & exports Scheduled CSV/accounting feeds for ERP cost-center allocation

Engineering Trade-offs & Solutions

Architectural Dilemma Chosen Solution & Rationale
Storing high-frequency pump lock states in MySQL vs. Redis Managed active pump authorization leases in Redis with automatic TTL expiration so stuck client connections self-recover cleanly without row-lock contention on MySQL transaction tables.
Single web-responsive UI for all users vs. dedicated Vue + React Native clients Built Vue for desktop fleet managers analyzing multi-tank tables and exports, and React Native with TypeScript for drivers operating gloved or one-handed in outdoor fueling lanes.
Trusting driver-entered volumes vs. hardware meter totalizers Anchored final accounting strictly to hardware dispenser pulse counts when online, keeping manual mobile volume inputs clearly flagged as attendant-verified entries during offline fallback.
Alerting on every raw gauge jitter vs. hysteresis-based anomaly rules Buffered ATG readings through Redis time windows inside Java so thermal expansion or delivery sloshing does not trigger false leak notifications via Firebase.

Security & Reconciliation Integrity

Controlling physical fuel pumps over an API requires defense against replay attacks, unauthorized unlocks, and ledger tampering. Site gateways authenticate to the Java backend using mutually verified credentials and signed command envelopes, while mobile and web clients authenticate via short-lived scoped tokens tied to organization and site permissions.

Every dispense authorization checks vehicle-to-fuel-grade compatibility—preventing accidental diesel-into-gasoline or restricted-tank unlocks—and validates monotonic odometer sanity bounds against the vehicle's previous fill. In MySQL, finalized dispense records are append-only; corrections require explicit adjustment entries with operator attribution so financial audit trails remain intact.

Telemetry Throughput & Offline Resilience

Multi-depot fleets generate steady telemetry streams across dozens of tanks and pumps, interspersed with sudden bursts when shifts turn over and queues form at yard dispensers. Java worker pools process incoming gauge frames asynchronously from interactive pump-unlock endpoints so heavy background ingestion never delays a driver waiting at the nozzle.

On the React Native client, TypeScript interfaces enforce strict payload contracts with local persistence queues. If a yard loses mobile data mid-shift, drivers can log offline fills or attendant overrides seamlessly; the queue replays idempotently once signal returns, guaranteeing zero lost allocation records.

Operational Outcomes

Fleet operators gained a single operational picture uniting physical tank inventory, live pump activity, and vehicle-level fuel consumption across distributed yards. Automated variance checks surface gauge anomalies and unlogged draws early, while pre-validated cost-center tagging turns end-of-month fuel reconciliation from manual spreadsheet cross-checking into an auditable export workflow. Drivers move through fueling lanes faster with mobile authorization, and dispatchers schedule bulk tanker replenishments from live calibrated ullage data rather than guesswork.

01 — Questions

asked about this kind of project

How does the platform prevent two drivers from unlocking the same fuel pump simultaneously?

Pump authorization requests pass through the Java backend, which acquires a short-lived distributed lease in Redis keyed by depot and nozzle ID before instructing the site controller to energize the relay. Any concurrent unlock attempt on that nozzle receives an immediate busy-state response.

What happens if cellular connectivity drops at a remote depot while a driver needs fuel?

The React Native TypeScript app caches pre-authorized vehicle lists and driver credentials securely on the device. When a site operates in offline fallback mode via local hardware authorization or attendant override, the mobile app queues vehicle ID, odometer, and dispensed volume entries locally and reconciles them with MySQL as soon as connectivity returns.

How is tank shrinkage or unauthorized fuel draw detected?

The Java reconciliation engine continuously compares physical volume drops reported by automatic tank gauges against authorized pump meter transactions. Unexplained volume deltas during off-hours or between consecutive gauge polls trigger immediate variance events and Firebase push notifications to depot managers.

Why separate the web portal in Vue from the mobile app in React Native and React?

Fleet controllers spend hours reviewing multi-site telemetry tables, tank inventory curves, and cost-center accounting exports on wide desktop monitors, where a dedicated Vue web console excels. Drivers at the pump need a fast, single-handed mobile workflow in React Native with native camera QR scanning and offline storage.

How does the system handle tank geometry when converting level height to usable fuel volume?

Cylindrical horizontal and underground tanks have non-linear volume curves relative to liquid depth. MySQL stores per-tank strapping tables so the Java ingestion pipeline converts millimeter probe readings into temperature-aware net and gross liter volumes accurately.

How are fuel costs allocated accurately across departments and external subcontractors?

Every dispense authorization binds a driver, asset/vehicle, odometer reading, and assigned cost center before the pump starts. Completed meter totals settle against the active weighted-average or FIFO bulk delivery batch price in MySQL for clean ERP exports.

03 — Similar project?

describe what is different about yours

Build yours.

Tell me what exists, what you need and the deadline. Fixed price for a defined scope, or $55/day (8–9 hours work) with a written plan first.

Solitaire Corporate Park, Makarba, Ahmedabad, Gujarat 380015, India · IST (UTC+5:30) · --:-- IST · Mon–Fri 09:00–18:00 IST · US & EU overlap daily

No newsletter, no CRM. Just a reply.