Phase 2-1: PostgreSQL DB 생성 - 211.208.115.83:5432에 kcgaidb 데이터베이스 생성 - kcg-app 사용자 + kcg 스키마 생성 Phase 2-2: Spring Boot 3.5.7 + Java 21 프로젝트 - gc.mda.kcg.KcgAiApplication 메인 클래스 - 의존성: web, security, data-jpa, validation, postgresql, flyway, actuator, cache, lombok, caffeine, jjwt(0.12.6) - Maven Wrapper 포함, .sdkmanrc로 Java 21 고정 Phase 2-3: application.yml - DataSource: 211.208.115.83/kcgaidb (kcg-app) - JPA: ddl-auto=validate, default_schema=kcg - Flyway: classpath:db/migration, schema=kcg - Caffeine 캐시 (permissions, users) - prediction/iran-backend/cors/jwt 커스텀 설정 - application-local.yml (로컬 디버깅용) Phase 2-4: Flyway 마이그레이션 V001~V005 - V001 auth_init: auth_org, auth_user, auth_role, auth_user_role, auth_login_hist (pgcrypto 확장 포함) - V002 perm_tree: auth_perm_tree, auth_perm, auth_setting (wing 패턴의 트리 기반 RBAC) - V003 perm_seed: 5개 역할(ADMIN/OPERATOR/ANALYST/VIEWER/FIELD) + 13개 Level 0 탭 + 36개 Level 1 패널 (총 49개 리소스) + 역할별 권한 매트릭스 일괄 INSERT - V004 access_logs: auth_audit_log, auth_access_log - V005 parent_workflow: gear_group_parent_resolution, review_log, candidate_exclusions, label_sessions (iran 012/014의 백엔드 쓰기 부분만 이관) Phase 2-5: 빌드 + 기동 검증 완료 - ./mvnw clean compile 성공 - spring-boot:run으로 기동 → Flyway가 V001~V005 자동 적용 - /actuator/health UP 확인 - 14개 테이블 + flyway_schema_history 생성 확인 - ADMIN 245건, OPERATOR 22건, 다른 역할 13건 권한 시드 확인 Phase 2 임시 SecurityConfig: 모든 요청 permitAll (Phase 3에서 JWT 필터 + 트리 기반 권한 체크로 전환 예정) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
169 lines
4.5 KiB
XML
169 lines
4.5 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
|
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
|
|
<modelVersion>4.0.0</modelVersion>
|
|
<parent>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-starter-parent</artifactId>
|
|
<version>3.5.7</version>
|
|
<relativePath/> <!-- lookup parent from repository -->
|
|
</parent>
|
|
<groupId>gc.mda.kcg</groupId>
|
|
<artifactId>kcg-ai-backend</artifactId>
|
|
<version>0.0.1-SNAPSHOT</version>
|
|
<name>kcg-ai-backend</name>
|
|
<description/>
|
|
<url/>
|
|
<licenses>
|
|
<license/>
|
|
</licenses>
|
|
<developers>
|
|
<developer/>
|
|
</developers>
|
|
<scm>
|
|
<connection/>
|
|
<developerConnection/>
|
|
<tag/>
|
|
<url/>
|
|
</scm>
|
|
<properties>
|
|
<java.version>21</java.version>
|
|
</properties>
|
|
<dependencies>
|
|
<dependency>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-starter-actuator</artifactId>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-starter-cache</artifactId>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-starter-data-jpa</artifactId>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-starter-security</artifactId>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-starter-validation</artifactId>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-starter-web</artifactId>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.flywaydb</groupId>
|
|
<artifactId>flyway-core</artifactId>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.flywaydb</groupId>
|
|
<artifactId>flyway-database-postgresql</artifactId>
|
|
</dependency>
|
|
|
|
<dependency>
|
|
<groupId>org.postgresql</groupId>
|
|
<artifactId>postgresql</artifactId>
|
|
<scope>runtime</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.projectlombok</groupId>
|
|
<artifactId>lombok</artifactId>
|
|
<optional>true</optional>
|
|
</dependency>
|
|
<!-- Caffeine cache (권한 캐싱용) -->
|
|
<dependency>
|
|
<groupId>com.github.ben-manes.caffeine</groupId>
|
|
<artifactId>caffeine</artifactId>
|
|
</dependency>
|
|
<!-- JJWT (Phase 3 인증에서 사용) -->
|
|
<dependency>
|
|
<groupId>io.jsonwebtoken</groupId>
|
|
<artifactId>jjwt-api</artifactId>
|
|
<version>0.12.6</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>io.jsonwebtoken</groupId>
|
|
<artifactId>jjwt-impl</artifactId>
|
|
<version>0.12.6</version>
|
|
<scope>runtime</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>io.jsonwebtoken</groupId>
|
|
<artifactId>jjwt-jackson</artifactId>
|
|
<version>0.12.6</version>
|
|
<scope>runtime</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-starter-test</artifactId>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.springframework.security</groupId>
|
|
<artifactId>spring-security-test</artifactId>
|
|
<scope>test</scope>
|
|
</dependency>
|
|
</dependencies>
|
|
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-maven-plugin</artifactId>
|
|
<configuration>
|
|
<excludes>
|
|
<exclude>
|
|
<groupId>org.projectlombok</groupId>
|
|
<artifactId>lombok</artifactId>
|
|
</exclude>
|
|
</excludes>
|
|
</configuration>
|
|
</plugin>
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-compiler-plugin</artifactId>
|
|
<executions>
|
|
<execution>
|
|
<id>default-compile</id>
|
|
<phase>compile</phase>
|
|
<goals>
|
|
<goal>compile</goal>
|
|
</goals>
|
|
<configuration>
|
|
<annotationProcessorPaths>
|
|
<path>
|
|
<groupId>org.springframework.boot</groupId>
|
|
<artifactId>spring-boot-configuration-processor</artifactId>
|
|
</path>
|
|
<path>
|
|
<groupId>org.projectlombok</groupId>
|
|
<artifactId>lombok</artifactId>
|
|
</path>
|
|
</annotationProcessorPaths>
|
|
</configuration>
|
|
</execution>
|
|
<execution>
|
|
<id>default-testCompile</id>
|
|
<phase>test-compile</phase>
|
|
<goals>
|
|
<goal>testCompile</goal>
|
|
</goals>
|
|
<configuration>
|
|
<annotationProcessorPaths>
|
|
<path>
|
|
<groupId>org.projectlombok</groupId>
|
|
<artifactId>lombok</artifactId>
|
|
</path>
|
|
</annotationProcessorPaths>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
|
|
</project>
|