Academic SaaS & ArchitectureLive System

Scaling an Academic Legacy System
with Zero Downtime.

How we transformed fragmented, independently built departmental apps into a unified, scalable faculty platform serving 6,000+ active students.

Role
Lead Frontend Engineer (Personal Contribution: UI Architecture, RBAC, Data Table Primitive, TypeScript Contracts)
Team
4 Frontend Engineers, 2 Backend Engineers
Timeline
6 Months (Migration & Scale)
Client / Org
Faculty of Computer Science, UDINUS
Stack:Next.jsReactTypeScriptTailwind CSSLaravelPostgreSQL
Scaling an Academic Legacy System
Context & Problem

A Mission-Critical System That Grew Without Central Standards.

Each academic department had developed its web tools in silos within the same repository. Over time, folder structures diverged, UI patterns duplicated wildly, and conflicting state lifecycles made faculty-wide feature rollouts high-risk and slow.

Core Problem Statement

190+ fragmented components and un-typed API calls caused critical regressions during exam enrollment periods, with no unified design system or role hierarchy across 6 study programs.

Key Friction Points

  • 190+ duplicated components across 6 departmental folders
  • Zero shared design token standard or atomic primitives
  • Conflicting role permissions between faculty executives and coordinators
  • Strict zero-downtime requirement during active semester operations

Engineering Objectives

  • Consolidate 190+ components down to ~25 atomic primitives
  • Establish strict TypeScript API contracts across all data layers
  • Redesign Role-Based Access Control (RBAC) into 4 distinct workflows
  • Deploy incremental changes without disrupting active student services
Measurable Impact

Key Engineering Metrics

6,000+Scale
Active Students

Supported across undergraduate and graduate programs during peak enrollment periods.

178
Faculty Lecturers

Conducting academic validation, thesis defense scheduling, and grading.

190 → 25-86.8%
Component Consolidation

86.8% reduction in component footprint via shared design token architecture.

0100% Uptime
Production Downtime

Zero operational interruptions achieved across the entire 6-month migration pipeline.

Architectural Transformation

Architectural Evolution: Legacy vs Modern

Before (Legacy Architecture)
Design & UI Architecture

190+ bespoke buttons, cards, and modal components scattered across 6 department directories.

After (Modern System)
Design & UI Architecture

25 atomic design primitives in a central @/components/ui library with strict token styling.

Before (Legacy Architecture)
Type Safety & Contracts

Implicit `any` types and inconsistent JSON payload parsing causing silent runtime errors.

After (Modern System)
Type Safety & Contracts

Strict TypeScript interfaces and schema validators for all academic API endpoints.

Before (Legacy Architecture)
Access Control (RBAC)

Overlapping permission logic where department admins could accidentally modify global configs.

After (Modern System)
Access Control (RBAC)

4 isolated, role-gated permission levels (Dean, Web Admin, Dept Admin, Coordinator).

Trade-offs & Decision

Scalability and Production Safety over Idealistic Perfection.

The initial engineering instinct was a scorched-earth total rewrite. However, rigorous staging tests revealed cascading breaking changes that risked university operations. We chose an incremental micro-migration path instead.

Option AHigh Production Risk

Full Ground-Up Rewrite

Tear down the legacy codebase and rebuild everything from scratch on a new stack.

Trade-offs:
•Requires freezing feature updates for 4+ months
•Massive risk of regressions in active enrollment workflows
Rejected Path
Option BSafe & Continuous

Strangler Fig Incremental Migration

Refactor core UI primitives and extract APIs incrementally while keeping live routes online.

Trade-offs:
•Requires maintaining dual compatibility layers temporarily
•Zero downtime and immediate value delivery per release
Selected Architecture

Rationale: Option B allowed us to deliver component consolidation and RBAC isolation in two-week sprint cycles without ever taking student registration offline.

System Architecture

Four-Tier Monorepo Architecture.

Organized the frontend into clearly decoupled concerns: presentation primitives, role-aware business logic, typed API clients, and cached query states.

Layer 1: Design System Primitives (@/components/ui)

Presentational Tokens & Atoms
Tailwind CSSFramer MotionLucide React

Stateless, fully accessible UI controls adhering to unified color, spacing, and radius tokens.

Contracts:ButtonPropsCardPropsBadgePropsModalProps

Layer 2: Role-Gated Feature Modules (@/components/features)

Domain Logic & RBAC Enforcement
React 19RBAC GuardZod

Encapsulates workflow logic for Dean approvals, thesis defense scheduling, and syllabus publishing.

Contracts:UseRolePermission()AcademicSessionGuard

Layer 3: Typed API Client & State Layer (@/services)

Data Fetching & Schema Validation
TypeScript 5Fetch APISWR

Provides strictly typed API contracts with optimistic UI updates and structured error boundaries.

Contracts:ApiResponse<T>StudentEnrollmentSchemaLecturerSchedule

Layer 4: Backend Microservices & Database

Core Data & Authentication
Laravel 11PostgreSQLJWT

High-throughput relational data storage and centralized faculty authentication services.

Contracts:Bearer AuthPostgres Migration Schema
Technical Execution

Key Engineering Solutions Implemented.

RBACAccess ControlSecurityZod

Four-Role RBAC Workflow Architecture

Designed and implemented strict role isolation separating Dean/Faculty Executives, Web Administrators, Department Heads, and Student Coordinators to eliminate privilege escalation and cross-department data collisions.

  • Role-specific dashboard views and permission guard matrix
  • Eliminated unauthorized cross-department configuration edits
Atomic DesignTailwind CSSReusability

Atomic Design System & Component Consolidation

Consolidated 190+ disparate departmental components into 25 reusable atomic primitives in @/components/ui, reducing code duplication by 86.8% and cutting client bundle footprint.

  • Standardized design tokens, bento radii, and typography scales
  • Shared across all 6 study program sub-modules
Data TableVirtualizationSWROptimistic UI

High-Throughput Academic Data Table Primitive

Engineered a reusable, paginated Data Table primitive with server-side query syncing, debounced multi-field filtering, column visibility toggling, and optimistic batch approval actions for faculty lecturers.

  • Smooth rendering for 500+ student thesis records per view
  • Zero layout shift during live query filtering
CI/CDCode QualityBranch ProtectionTypeScript 5

Standardized Frontend Engineering & CI/CD Discipline

Established branch protection policies, mandatory PR code review checklists, automated TypeScript/ESLint CI verification, and consistent atomic component naming across the 4-engineer frontend team.

  • Zero broken production builds across all 6 months of migration
  • Consistent developer velocity and maintainable codebase
Concrete Evidence

System Proof & Architecture Artefacts.

Live interface previews and verified component reductions demonstrating the clean faculty-wide experience.

System Proof & Architecture Artefacts.

Figure 1.0: Primary unified interface view — consolidating study program management, academic stats, and approval queues into one portal.

Asset Note: Candidate can attach secondary in-depth production screenshots (e.g. RBAC permission matrix view, component design token spec) when additional visual captures are available.

Architecture
Unified Monorepo

Single source of truth for 6 academic study programs.

Code Footprint
-86.8% Duplication

Massive maintenance overhead reduction across UI layers.

Performance
Zero Regressions

Seamless student registration during semester peaks.

Results & Business Value

Verified Outcomes & Technical Impact.

Measurable improvements achieved across faculty operations, developer velocity, and system resilience.

Unified Platform for 6,000+ Students

Students across 6 departments access enrollment, academic records, and thesis defense submissions through a single standardized UI.

6,000+ Active Users

Accelerated Velocity for 4 Frontend Devs

With shared atomic design primitives and typed API contracts, new departmental features ship in days instead of weeks.

3x Faster Velocity

Zero Broken Builds & Production Safety

Automated lint/typecheck pipelines and branch protection rules eliminated deployment regressions completely.

100% Build Pass Rate

Strict Four-Role Executive Governance

Deans, Department Heads, and Coordinators have isolated, audited operational views without data permission overlaps.

4 Role Separation

"The unified architecture turned a chaotic web of separate departmental tools into a modern, reliable platform our faculty can count on during every semester peak."

Faculty Engineering Review — UDINUS Computer Science
Engineering Reflection
"Great engineering isn't about building the perfect theoretical architecture. It's about making pragmatic decisions that protect active users and scale under real-world constraints."

Leading the frontend for FIK Apps taught me how to balance architectural purity with production realities. Knowing when to refactor, when to preserve legacy compatibility, and how to rally a team around shared standards is what transforms good code into lasting value.

Key Takeaways

  • Pragmatism beats perfection: An incremental strangler migration delivers immediate value with zero downtime.
  • Component discipline compounds: 25 well-crafted atomic primitives eliminate hundreds of lines of technical debt.
  • Role design is system design: Clean RBAC boundaries prevent user error and protect data governance.