Learn how vFunction enabled a leading global consumer goods manufacturer to transform a 20-year-old monolith through a spec-driven, agentic modernization workflow.
Overview
A leading global consumer goods manufacturer faced a challenge familiar to many enterprises: the application that powered its entire production lifecycle had become both indispensable and increasingly difficult to evolve.
Built more than twenty years ago, the system orchestrated everything from manufacturing to logistics. But over time, its architecture had become deeply entangled, poorly documented, and increasingly resistant to change.
Modernization was no longer optional. It was foundational to future growth.
The app equivalent of a ‘Model T’
Originally built by long-gone contractors using Java 6 and Java Data Objects (JDO), the system contained:
- 615,000 lines of code
- 5,000+ tightly coupled classes
- Circular dependencies across business domains
- Deeply embedded data logic
Like a Model T still running after a century: dependable, but never designed for modern highways. Internal refactoring efforts stalled. Replacement options were too risky. Rewrites were prohibitively expensive, including one proposal estimated at $18 million. They needed a way to modernize iteratively and with precision without disrupting the system that runs the business.
The architectural bottleneck
The team was committed to modernization. What they lacked was clarity.
Static documentation, service catalogs, and APMs showed fragments of the system, but not how it actually behaved in production. Without runtime architectural insight, it was impossible to know where to start modernization or what to prioritize for effective refactoring.
The turning point came when AWS introduced the company to vFunction.
A prioritized data-driven roadmap
By combining static and runtime analysis with data science, vFunction mapped the system as it truly operated, exposing circular dependencies, undefined clusters, outdated libraries, dead code, and hidden database coupling.
For the first time, the team had a prioritized, data-driven modernization roadmap.
They targeted a high-value backend domain focused on shipping and bills of lading. With vFunction the team:
- Untangled dependencies
- Removed dead code
- Established clear service boundaries
- Upgraded from Java 6 to Java 21
- Replaced JDO with Spring Boot
That first extraction from EC2 to Lambda became a blueprint for iterative modernization.
From monolith to spec-driven modernization
Early on, the team paired vFunction’s runtime-driven architectural analysis with Amazon Q Developer to accelerate targeted remediation and upgrades. Q proved effective when guided by structured, architecture-aware prompts.
But as modernization expanded beyond isolated fixes into coordinated service extraction, the team needed more than task-level acceleration. They needed a disciplined, agent-driven workflow capable of scaling across domains.
They evolved toward a spec-driven, agent-assisted model.
Instead of issuing free-form prompts against a 20-year-old monolith. Modernization began with structured specifications derived from an existing codebase and vFunction’s runtime analysis and modernization plan.
Work was:
- Validated by the engineering team before deployment
- Iteratively spec’d by service into a comprehensive knowledge base
- Broken into gated tasks
- Executed iteratively
Kiro as the agentic execution layer
To support this structured workflow, the team introduced Amazon’s Kiro as the execution layer.
Once vFunction defined a modernization specification, Kiro orchestrated architect, developer, reviewer, and execution agents to implement it. Execution was grounded in vFunction’s runtime-driven architectural analysis and modernization plan, delivered through the MCP, ensuring changes aligned with active code paths, real production dependencies, and validated service boundaries.
Standardized AWS constructs reinforced domain logic, data integrity, and deployment guardrails. If additional runtime context was needed, Kiro could query vFunction directly.
Spec → Ship
The result was a spec-driven, Kiro-enabled modernization workflow grounded in architectural truth and governed by agents and human gates.
“Large-scale modernization requires understanding how a system actually behaves. When architectural context guides AI-driven refactoring, modernization becomes predictable instead of probabilistic.”
– Moti Rafalin, Co-Founder and CEO, vFunction
By combining vFunction’s runtime-driven architectural analysis with a spec-driven, agentic workflow in Kiro, the team transformed modernization from a risky rewrite into a continuous, controlled evolution of the system.
It is the kind of foundational work that sets the stage for long-term agility and resilience leading to transformation at scale, not just to fix but to future-proof.