File tree Expand file tree Collapse file tree
java/com/practice/course_registration/global/init Expand file tree Collapse file tree Original file line number Diff line number Diff line change 44# Docker Hub 사용자명 (앱 이미지: <DOCKER_USERNAME>/docker-springboot:latest)
55DOCKER_USERNAME = your-dockerhub-username
66
7+ # Spring 프로파일 (평소 prod / 부하테스트 시 prod,loadtest 로 변경하면 헤더 기반 userId 활성화)
8+ SPRING_PROFILES_ACTIVE = prod
9+
710# MySQL
811MYSQL_ROOT_PASSWORD = change-me-root-password
912DB_NAME = course_register
Original file line number Diff line number Diff line change @@ -60,6 +60,10 @@ dependencies {
6060
6161 // redisson
6262 implementation ' org.redisson:redisson-spring-boot-starter:3.27.2'
63+
64+ // monitoring (부하테스트용 지표: thread pool / connection pool / cpu)
65+ implementation ' org.springframework.boot:spring-boot-starter-actuator'
66+ implementation ' io.micrometer:micrometer-registry-prometheus'
6367}
6468
6569tasks. named(' test' ) {
Original file line number Diff line number Diff line change @@ -42,7 +42,7 @@ services:
4242 ports :
4343 - " 80:8080"
4444 environment :
45- SPRING_PROFILES_ACTIVE : prod
45+ SPRING_PROFILES_ACTIVE : ${SPRING_PROFILES_ACTIVE:- prod}
4646 DB_HOST : mysql
4747 DB_PORT : 3306
4848 DB_NAME : ${DB_NAME}
Original file line number Diff line number Diff line change @@ -50,7 +50,7 @@ public void run(String... args) {
5050 private void seedSubjects () {
5151 SubjectDay [] days = SubjectDay .values ();
5252 List <Subject > subjects = new ArrayList <>();
53- for (int i = 1 ; i <= 20 ; i ++) {
53+ for (int i = 1 ; i <= 30 ; i ++) {
5454 subjects .add (Subject .builder ()
5555 .subjectName ("테스트과목" + i )
5656 .professorName ("교수" + i )
Original file line number Diff line number Diff line change @@ -43,5 +43,15 @@ server:
4343app :
4444 seed :
4545 enabled : true
46- member-count : 100
47- member-password : test1234
46+ member-count : 2500
47+ member-password : test1234
48+
49+ # 부하테스트용 지표 노출 (thread pool / connection pool / cpu)
50+ management :
51+ endpoints :
52+ web :
53+ exposure :
54+ include : health, prometheus
55+ metrics :
56+ tags :
57+ application : course-registration
You can’t perform that action at this time.
0 commit comments