본문으로 건너뛰기

모듈

이 페이지는 현재 lumie-backend/settings.gradle.kts에 포함된 Gradle 서브프로젝트의 overview 맵입니다. 모듈 계열, 공유 라이브러리, 그리고 어떤 페이지로 이동하면 reference-grade 세부 내용을 볼 수 있는지 이해할 때 사용하세요. route, DTO, 실패 계약의 세부사항은 아래에 링크된 개별 모듈 페이지를 참고하세요.

여기 있는 모든 모듈은 동일한 Spring Boot 애플리케이션 안에서 동작하며, 같은 JVM, transaction manager, PostgreSQL tenant 모델을 공유합니다.

공통 라이브러리

Path소유 범위
libs/commontenant, auth, exception, idempotency, logging, base-entity를 가로지르는 공통 지원
libs/internal-api공개된 프로세스 내부 service interface와 모듈 간 event
libs/messagingqueue 기반 exam 흐름에 사용되는 공통 AMQP 상수

이 맵 읽는 방법

  • app, libs/*, 그리고 포함된 모든 modules/* 서브프로젝트는 하나의 배포 가능한 백엔드 jar로 조립됩니다.
  • 모듈 이름은 모놀리스 내부의 소유 경계를 설명하며, 각각 따로 배포되는 Java 서비스가 아닙니다.
  • 링크된 각 모듈 페이지는 해당 모듈의 public surface, internal API, data contract, failure behavior에 대한 source of truth입니다.

플랫폼 모듈

Doc pageGradle modulePrimary source rootMain ownershipMain boundaries
Tenant Servicemodules:tenantmodules/tenant/src/main/java/com/lumie/tenanttenant registry, lifecycle state, custom ID/domain, onboarding, logoTenantServiceTenantCreatedEvent를 발행하며 auth, homepage, billing이 사용
Auth Servicemodules:authmodules/auth/src/main/java/com/lumie/authregistration, login, JWT, refresh, session, profile, avatar, OAuth2AuthService, OwnerRegisteredEvent, StudentSelfRegisteredEvent를 발행하고 Redis 및 tenant lookup에 의존
Billing Servicemodules:billingmodules/billing/src/main/java/com/lumie/billingplan, subscription, billing key, invoice, Alimtalk credit, tax invoiceTenantCreatedEvent를 소비하고 BillingService를 발행하며 Toss와 stubbed Popbill adapter를 통합
Homepage Servicemodules:homepagemodules/homepage/src/main/java/com/lumie/homepagetenant homepage config와 anonymous public homepage lookupTenantLookupPort를 통해 TenantService를 소비하며 write는 owner 전용
AI Servicemodules:aimodules/ai/src/main/java/com/lumie/aiconversation, chat proxying, tool execution, scheduled AI taskchatbot-svc와 통합되며 /internal/chatbot/**로 백엔드에 재진입하고 전용 read-only JDBC 경로 사용
Notification Servicemodules:notificationmodules/notification/src/main/java/com/lumie/notificationSMS 발송, 메시지 이력, 템플릿tenant 범위 메시지 기록과 billing quota check 사용
File Servicemodules:filemodules/file/src/main/java/com/lumie/file파일 메타데이터, 업로드/다운로드, 교재 폴더, 파일 링크MinIO와 통합되며 DB commit 후 object deletion을 예약

교육 및 운영 모듈

Doc pageGradle modulePrimary source rootMain ownershipMain boundaries
Student Servicemodules:studentmodules/student/src/main/java/com/lumie/student학생 기록, import, export, lifecycle, credential linkageStudentServiceStudentRegisteredEvent를 발행하고 auth 및 class 규칙에 의존
Staff Servicemodules:staffmodules/staff/src/main/java/com/lumie/staffstaff lifecycle, permission catalog, staff permission assignmentStaffService를 발행하고 OwnerRegisteredEvent를 소비하며 auth, billing, class, content에 의존
Class Servicemodules:classmodules/class/src/main/java/com/lumie/classroomclass, schedule, enrollment, dashboardClassService를 발행하며 staff, attendance, lecture, assignment가 사용
Attendance Servicemodules:attendancemodules/attendance/src/main/java/com/lumie/attendanceattendance session, record, export, statisticsclass와 student reference에 의존
Assignment Servicemodules:assignmentmodules/assignment/src/main/java/com/lumie/assignmentassignment, submission, dashboardAssignmentService를 발행하며 class와 student 관계에 의존
Lecture Servicemodules:lecturemodules/lecture/src/main/java/com/lumie/lecturelecture와 class 대상 lecture visibilityclass reference와 tenant-safe class-target table에 의존
Content Servicemodules:contentmodules/content/src/main/java/com/lumie/contentannouncement, Q&A, reservation, review, schedulefile link와 class-aware visibility rule에 의존
Exam Servicemodules:exammodules/exam/src/main/java/com/lumie/examexam, template, OMR job, report, analyticsRabbitMQ, MinIO, 직접 worker HTTP, 내부 report/OMR surface, student backfill event
Tuition Servicemodules:tuitionmodules/tuition/src/main/java/com/lumie/tuitionguardian, tuition invoice, tuition payment, cash receipt외부 cash receipt 및 billing adapter, 현재는 공개된 internal API surface가 거의 없음

서브시스템 구조

포함된 모듈은 몇 가지 안정적인 백엔드 서브시스템으로 묶입니다.

SubsystemModules함께 묶이는 이유
Tenant and identitytenant, auth, billing, homepagetenant bootstrap, authentication, quota, tenant-facing config
Core academy operationsstudent, staff, class, attendance, assignment, lecture, content일상적인 학원 데이터, scheduling, visibility, lifecycle 흐름
Heavy async or external integrationsexam, ai, notification, file, tuitionworker 호출, messaging, storage, payment, 문서 지향 integration

현재 사용 중인 모듈 간 패턴

  • adapter/in/internal/*Adapterlibs/internal-api 구현을 위한 일반적인 동기 경계 형태입니다.
  • @ApplicationModuleListener는 커밋 후 모듈 간 후속 처리를 위한 일반적인 비동기 경계 형태입니다.
  • 현재 libs/messaging을 직접 사용하는 모듈은 exam 하나뿐이며, 이는 RabbitMQ 기반 grading 및 report pipeline을 소유하기 때문입니다.
  • homepagestaff는 다른 모듈의 repository에 직접 접근하지 않고 공개된 계약을 소비하는 선호 패턴을 보여줍니다.

현재 빌드 참고 사항

  • app/build.gradle.kts는 위에 나열된 모든 모듈을 백엔드 jar에 포함합니다.
  • modules/activity-log는 리포지토리에는 존재하지만 settings.gradle.kts에는 없으므로 배포되지 않습니다.
  • admin-svc.md는 기존 백엔드 naming을 유지하기 때문에 staff 모듈을 문서화합니다.
  • modules:class는 Gradle 수준 이름은 class이지만 Java package root는 com.lumie.classroom을 사용합니다.

검증

cd /Users/bluemayne/Projects/Lumie/lumie-backend
./gradlew projects
cd /Users/bluemayne/Projects/Lumie/lumie-document/docusaurus
npm run build

예상 성공 신호:

  • ./gradlew projectssettings.gradle.kts에 포함된 모듈 경로를 나열하며, 여기에는 modules:student, modules:staff, modules:class, modules:attendance, modules:assignment, modules:lecture, modules:content가 포함됩니다.
  • Docusaurus가 backend/modules에 대해 MDX 또는 broken-link 오류 없이 완료됩니다.

관련 페이지