VIP 👤
🏠 Home
Benchmark
📊 Tutti i benchmark 🦖 Dinosauro v1 🦖 Dinosauro v2 ✅ App To-Do List 🎨 Pagine libere creative 🎯 FSACB - Ultimate Showcase 🌍 Benchmark traduzione
Modelli
🏆 Top 10 modelli 🆓 Modelli gratuiti 📋 Tutti i modelli ⚙️ Kilo Code
Risorse
💬 Libreria di prompt 📖 Glossario IA 🔗 Link utili 🔌 API e router IA
advanced

Legacy Code Refactoring Strategy

#refactoring #design-patterns #legacy-code #software-maintenance

Analyze a hypothetical legacy codebase scenario and propose a refactoring strategy using design patterns.

Act as a Lead Software Engineer. You are presented with a hypothetical legacy Java class named 'OrderManager' that is 2000 lines long, contains static mutable state, mixes database access with business logic, and has no unit tests. Propose a step-by-step refactoring strategy to break this class down. Identify which Design Patterns (e.g., Factory, Repository, Strategy, Decorator) are appropriate to apply. Explain how you would introduce test coverage without breaking existing functionality, using the 'Strangler Fig' pattern concept where applicable.