Current Task

INIT-012 — Database Connection Validation

Mandatory References (read before writing any code):

- AI.md (Sections 21–27 — operational rules)
- PROJECT.md
- WORKFLOW.md
- IMPLEMENTATION_ROADMAP.md
- Sprint 0 Execution Plan
- DBP
- ADR
- MIB — locate INIT-012 and read "Files Expected"
- TCS

Review the implementation of:

- INIT-001
- INIT-002
- INIT-005
- INIT-003
- INIT-004
- INIT-006
- INIT-007
- INIT-008

before making any changes.

Review the project memory:

.ai/memory/

to understand previous implementation decisions and architectural reasoning.

Requirements

Implement ONLY Task INIT-012.

Do NOT implement any part of INIT-009 or later tasks.

The purpose of INIT-012 is to validate and finalize the database connection layer already introduced in INIT-008.

The implementation must follow the approved documentation exactly.

Expected responsibilities include only those documented for INIT-012.

Rules

- Native PHP 7.4 only.
- Framework-agnostic implementation.
- Keep Database independent from Router.
- Keep Database independent from Session.
- Keep Database independent from Middleware.
- Keep Database independent from Authentication.
- No business logic.
- No migrations.
- No seeders.
- No schema creation.
- No ORM.
- No query builder.
- No transaction manager unless explicitly documented.
- Do NOT modify BaseModel unless required by documentation.
- Do NOT introduce caching or pooling.

Create ONLY the files listed under INIT-012 "Files Expected".

If implementation requires files not listed in the documentation:

STOP.

Explain why.

Wait for approval.

If documentation conflicts are found:

STOP.

Explain the conflict.

Reference the conflicting documents.

Wait for approval.

Do NOT execute:

- git add
- git commit
- git push
- git tag
- git merge
- git checkout

Do NOT modify documentation.

Do NOT continue to INIT-009.

After implementation provide:

1. Implementation Summary
2. Files Created (verify against MIB)
3. Files Modified
4. Acceptance Criteria Verification
5. Definition of Done Checklist
6. Proposed Git Commit Message (do NOT execute)
7. Documentation Deviations (if any)

Implementation ends after INIT-012.

Wait for approval.