refactor-backend-04-service

Installation
SKILL.md

Service-Layer Structure — refactor-chain · backend lane · step 04/09

Bundle: refactor-chain (self-diagnosing, self-healing fix-it pipeline). Phase: do-the-work · Prerequisite: refactor-backend-03-dao-model · Next: refactor-backend-05-controller. Adaptivity / conditional: repo-agnostic — works on any layered backend project in any registry-detected stack; directory names are configurable (interface package defaults to facade/, but api/ or any project convention is fine).

Purpose

Check and, on request, fix the structure of the service layer so that every service interface lives in one dedicated interface package and every implementation lives in impl/. The skill classifies each file with a deterministic decision tree, reports findings at FAIL/WARN/INFO severity, and performs confirmation-gated moves that never touch business logic — only package lines, import lines, and file locations change.

When to use

  • After the DAO/model step (03) has run and before the controller step (05).
  • You say things like: "service layer check", "service layer fix", "check interface/impl separation", "consolidate scattered impl folders", "move ServiceImpl classes into impl/".
  • Service interfaces sit loose in the service/ root or inside business sub-packages, or implementations are scattered across per-feature impl/ folders.
Installs
5
GitHub Stars
3
First Seen
Jul 6, 2026
refactor-backend-04-service — ahmedbenaw/refactor-chain