7.1 KiB
CLAUDE.md
This file provides guidance to Claude Code (claude.ai/code) when working with code in this repository.
Project Overview
eLink EMS (eLink Management System) is a web-based management service for eLink that provides configuration, monitoring, and statistics features. This is a Spring-based Java web application deployed on Tomcat or WebLogic.
Key Features
- User and permission management
- Transaction log viewing (online/batch/bulk)
- Statistics and dashboard monitoring
- Interface, layout, adapter, and routing management
- Integration with external systems (UMS, EAI batch)
Build and Development Commands
Build Commands
# Standard build
gradle build
# Build for Weblogic deployment (excludes tests)
gradle build -x test -Pprofile=weblogic
# Build WAR file
gradle war
# Clean build
gradle clean build
Running Tests
# Run all tests
gradle test
# Run specific test (use JUnit platform)
gradle test --tests "com.eactive.eai.rms.*"
Development Setup
The application is configured via environment-specific properties files in WebContent/WEB-INF/properties/:
env.D.properties- Developmentenv.T.properties- Test/Stagingenv.P.properties- Production
Local Development (Tomcat) Set the following JVM options:
-Deai.datasource.type=DEV
-Dinst.Name=emsSvr99
-Deai.tableowner=EMSADM
-Deai.systemmode=D
-Dfile.encoding=utf-8
-Dlogin.mode=db
-DLOGBACK_LOG_LEVEL=DEBUG
-Dlogback.configurationFile=classpath:logback-dev.xml
-Dhibernate.dialect=org.hibernate.dialect.Oracle12cDialect
-Dkjb_safedb.mode=fake
Profile Configuration
-Pprofile=weblogic: Usesweblogic-web.xmlinstead ofweb.xml(resolves DefaultServlet issues)
Architecture and Code Structure
Multi-Module Project
This project references several external eLink modules defined in settings.gradle:
elink-online-core- Core interfaces and classeselink-online-transformer- Message transformation logicelink-online-adapter- Communication adapterselink-online-common- Common utilitieselink-online-emsclient- EMS communication clientelink-portal-common- Portal shared componentskjb-safedb- KJB bank-specific database encryptioneapim-admin-kjb- KJB bank-specific customizations
These modules are located in sibling directories (../eapim-online/, ../elink-portal-common/, etc.)
Package Structure
com.eactive.eai
├── agent/command - Command pattern implementations
├── common - Common utilities, iBatis, JSON serialization
├── custom - Customer-specific customizations
├── rms - Main application code
│ ├── bap - Batch processing (BAP)
│ │ ├── adaptor - Batch adapters
│ │ ├── manage - Batch management (messages, servers, properties)
│ │ └── tansaction - Batch transaction tracking
│ ├── bat - Additional batch functionality
│ ├── common - RMS common (filters, startup, services)
│ ├── data - Data entities, repositories
│ ├── env - Environment configuration
│ ├── kakao - Kakao integration
│ ├── onl - Online transaction management
│ │ ├── apim - API management (portal org, users, approvals)
│ │ ├── manage - Resource management
│ │ └── transaction - Transaction handling
│ └── service - Business services
└── ext.kjb - Kwangju Bank (KJB) extensions
Technology Stack
- Framework: Spring 5.3.27 (MVC, Data JPA)
- Persistence:
- Hibernate 5.6.15 (JPA/ORM)
- iBatis 2.3.4 (legacy SQL mapping)
- QueryDSL 5.0.0 (type-safe queries)
- Database: Oracle 12c (primary), with support for MariaDB/PostgreSQL
- Logging: Logback 1.2.10 (with SLF4J)
- Build: Gradle 8.x with Java 8
- View: JSP with JSTL
- Other: Quartz scheduler, EhCache, Jackson, Lombok, MapStruct
Spring Configuration
- Root context:
WebContent/WEB-INF/applicationContext.xml - Servlet context:
WebContent/WEB-INF/springapp-servlet.xml - Environment-specific configs loaded based on
${eai.systemmode}system property - Component scanning enabled with annotation-based configuration
Data Access Patterns
The application uses dual persistence:
- JPA/Hibernate - For newer entity-based code in
com.eactive.eai.rms.data.entity - iBatis - For legacy SQL mappings in
src/main/resources/com/eactive/eai/**/*.xml
Repositories use Spring Data JPA conventions, Services use @Service, Controllers use @RestController/@Controller.
Key Initialization
AppInitializer- Main application startup bean that sets system propertiesCustomizingAppInitializer- Customer-specific initialization- System properties:
inst.Name,eai.tableowner,eai.systemmode,theme.color
KJB (Kwangju Bank) Specific Configuration
Property Management
KJB-specific properties are stored in database table TSEAIRM24 with group name 'Monitoring'. Key properties handled by com.eactive.ext.kjb.common.KjbProperty:
Email Notification (via EAI Batch)
kjb.eai_batch.url- EAI batch server URL for email sendingkjb.ums.eai_batch.send_dir- Email file send directory (default:/Data/eapim/portal/sendmail/snd)kjb.ums.eai_batch.backup_dir- Email backup directory (default:/Data/eapim/portal/sendmail/bak)kjb.ums.eai_batch.interface_id- Interface ID for customer email (e.g.,UAGFF00001UIE)
UMS (SMS/LMS/KakaoTalk) Integration
kjb.ums.host_url- UMS API endpointkjb.ums.api_key- UMS API authentication keykjb.ums.connection_timeout- Connection timeout in secondskjb.ums.response_timeout- Response timeout in seconds
Security
- Custom password encoder:
KjbSafedbPasswordEncoderfor SafeDB integration - Set
-Dkjb_safedb.mode=fakefor local development without SafeDB
Database Vendor Support
The application supports multiple databases via vendor-specific SQL mapping files:
- Oracle:
*-oracle.xml - MariaDB:
*-mariadb.xml - PostgreSQL:
*-postgresql.xml
Database vendor is configured in properties files via db.vendor and hibernate.dialect.
WAR Deployment
The WAR file is built as eapim-admin.war with context path /monitoring.
Weblogic Deployment: Use -Pprofile=weblogic to include weblogic-web.xml configuration.
Important Notes
- Encoding: System uses UTF-8. CharacterEncodingFilter applies UTF-8 to all requests except
*.excelpatterns. - XSS Protection: CrossScriptingFilter applied to all requests via
com.eactive.eai.rms.common.filter.CrossScriptingFilter - Real-time Updates: All management changes are reflected immediately in both DB and memory
- Instance Name: Each deployment must have unique
inst.Namefor clustering - Table Owner: Oracle schema owner specified via
eai.tableownerproperty