Sovereign Code-First Infrastructure: Decoupling Business Logic from Persistent Plumbing
Abstract
Modern software engineering has fallen into a trap of excessive operational friction. Developers spend more time orchestrating Docker networks, configuring connection strings, managing YAML manifests, and tying application code to vendor-specific SDKs than building actual business logic. This whitepaper outlines a sober, architecture-first model where infrastructure is treated not as a separate deployment artifact, but as an explicit, declarative intent embedded directly within the code. By establishing a universal abstraction layer and ephemeral runtime plumbing, we eliminate vendor lock-in, guarantee local-to-production parity, and restore absolute sovereignty to the engineering lifecycle.
DOI 10.5281/zenodo.24356451 📄 PDF Source (Markdown)
Sovereign Code-First Infrastructure: Decoupling Business Logic from Persistent Plumbing
DOI: 10.5281/zenodo.24356451 · Zenodo (concept DOI 10.5281/zenodo.24356450) · cite this version
Author: Francisco Javier Jiménez Gómez
Organization: BRISECOM SL
Context: Architectural Principles for Sovereign, Vendor-Agnostic Systems
Abstract
Modern software engineering has fallen into a trap of excessive operational friction. Developers spend more time orchestrating Docker networks, configuring connection strings, managing YAML manifests, and tying application code to vendor-specific SDKs than building actual business logic. This whitepaper outlines a sober, architecture-first model where infrastructure is treated not as a separate deployment artifact, but as an explicit, declarative intent embedded directly within the code. By establishing a universal abstraction layer and ephemeral runtime plumbing, we eliminate vendor lock-in, guarantee local-to-production parity, and restore absolute sovereignty to the engineering lifecycle.
1. The Problem: The Accidental Complexity of Modern Stacks
For years, the industry standard for building distributed systems involved a fractured workflow:
- Provision infrastructure manually using Infrastructure as Code (IaC) tools like Terraform.
- Hardcode environment variables, ports, and proprietary SDK drivers (
pg,amqplib,@aws-sdk/client-s3) directly into the application layer. - Waste hours debugging local development environments where containers fail to mirror production setups.
This creates tight coupling. If an organization decides to switch from PostgreSQL to a different storage engine, or from RabbitMQ to NATS, or migrates from local MinIO storage to a sovereign S3-compatible cloud, the codebase suffers a cascade of invasive refactoring. The business logic becomes polluted by infrastructure concerns.
2. The Solution: Code-First Abstraction & Ephemeral Runtime
To achieve true technical sovereignty, we invert the paradigm. The application should never know how a database runs, where a queue is hosted, or what protocol delivers a file; it should only declare what capability it requires.
The architecture relies on three foundational pillars:
1. Declarative Intent in Code
Instead of configuring external files or binding to proprietary drivers, the developer expresses capability directly through clean, typed primitives within the business logic:
“This module requires a relational data store, an asynchronous message queue, and an object storage bucket.”
The application code remains entirely pure—defining abstract ports rather than concrete technological dependencies.
2. Transparent Ephemeral Plumbing & Engine Provisioning
The developer should never have to manually spin up containers, write complex docker-compose networks from
scratch, or seed migration scripts by hand.
- Upon initializing the development workspace, an intelligent local engine inspects the application’s declared intents.
- It automatically provisions lightweight, ephemeral local containers behind the scenes (e.g., spinning up an isolated PostgreSQL instance, a Redis or NATS broker, and a MinIO object store).
- It injects the initial creation scripts and database migrations transparently, establishing all virtual networking cables without manual intervention.
3. Pure Business Logic Isolation
With the plumbing handled entirely by the runtime engine, the program focuses exclusively on execution. The code simply invokes universal verbs:
database.save()queue.push()storage.store()
The underlying engine maps these calls dynamically to the correct physical driver. In local development, they hit ephemeral containers; in production, they map to hardened cluster nodes—all without changing a single line of business logic or binding to a vendor-locked SDK.
3. Architectural Implications for Sovereign Systems
Adopting this code-first, decoupled model yields profound operational advantages, particularly for high-assurance environments requiring rigorous compliance (such as ENS, ISO/IEC 27001, and the EU AI Act):
- Zero Vendor Lock-In: Because the application speaks a universal domain language rather than proprietary cloud APIs, infrastructure can be swapped, migrated, or repatriated to on-premise sovereign hardware instantly.
- Absolute Reproducibility: Every developer on the team runs the exact same self-provisioned stack derived purely from the application’s intent, eliminating the classic “it works on my machine” failure mode.
- Auditable Architecture: System boundaries remain crystal clear. Security audits can verify data flows and storage boundaries at the code level without wading through a maze of scattered configuration files.
4. Conclusion
True software sovereignty begins by stripping away accidental complexity. By treating infrastructure as a runtime abstraction derived directly from application intent—backed by automated, transparent local provisioning—we empower engineering teams to build resilient, portable, and maintainable systems that outlive any single cloud provider or technology stack.
Cite as: Francisco Javier Jiménez Gómez (2026). Sovereign Code-First Infrastructure: Decoupling Business Logic from Persistent Plumbing. LAIA / Brisecom SL. DOI: 10.5281/zenodo.24356451