Skip to content

Commit d9886c5

Browse files
authored
Merge pull request #20 from Lunawood/master
fix: update for final report
2 parents 3da2080 + 287d1a3 commit d9886c5

File tree

4 files changed

+40
-8
lines changed

4 files changed

+40
-8
lines changed

docker-test-server/nginx.conf

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
events {
2+
worker_connections 1024;
3+
}
4+
5+
http {
6+
upstream spring-app {
7+
server server1:8080; # 컨테이너 내부 포트 사용
8+
server server2:8080;
9+
server server3:8080;
10+
}
11+
12+
server {
13+
listen 8080;
14+
15+
location / {
16+
proxy_pass http://spring-app;
17+
proxy_set_header Host $host;
18+
proxy_set_header X-Real-IP $remote_addr;
19+
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
20+
proxy_set_header X-Forwarded-Proto $scheme;
21+
22+
proxy_connect_timeout 300;
23+
proxy_send_timeout 300;
24+
proxy_read_timeout 300;
25+
proxy_buffers 4 256k;
26+
proxy_buffer_size 128k;
27+
proxy_busy_buffers_size 256k;
28+
}
29+
}
30+
}

docker-test-server/src/main/java/com/example/server/controller/ToothController.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ public class ToothController {
3535
private final JwtTokenService jwtTokenService;
3636
private final InvalidTokenService invalidTokenService;
3737
private final ToothService toothService;
38-
private final Double totalCnt = 500.0;
38+
private final Double totalCnt = 8.0;
3939

4040
@PostMapping("")
4141
public ResponseEntity<?> mypageGetinfo

docker-test-server/src/main/java/com/example/server/jwt/JwtTokenService.java

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -9,17 +9,19 @@
99
import com.auth0.jwt.algorithms.Algorithm;
1010
import com.auth0.jwt.interfaces.DecodedJWT;
1111

12+
import io.github.cdimascio.dotenv.Dotenv;
1213
import lombok.extern.slf4j.Slf4j;
1314

1415
@Slf4j
1516
@Service
1617
public class JwtTokenService {
18+
Dotenv dotenv = Dotenv.configure().load();
19+
20+
private String secret = dotenv.get("JWT_SECRET_KEY");
1721

18-
private String secret = System.getenv("JWT_SECRET_KEY");
19-
20-
private int accessTokenExpMinutes = 600 * 1000; // 10분
22+
private int accessTokenExpMinutes = 1728000 * 1000; // 10분
2123

22-
private int refreshTokenExpMinutes = 1209600 * 1000; // 2주
24+
private int refreshTokenExpMinutes = 12096000 * 1000; // 2주
2325

2426
private final Algorithm algorithm = Algorithm.HMAC256(secret);
2527

docker-test-server/src/main/java/com/example/server/service/ToothService.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,8 +24,8 @@ public class ToothService {
2424
private void init() {
2525
toothPartEngToKor.put("UNDER_FRONT", "아랫쪽 앞니");
2626
toothPartEngToKor.put("UP_FRONT", "윗쪽 앞니");
27-
toothPartEngToKor.put("UNDER_RIGHT_CANINE", "아래쪽 오른쪽 송곳니");
28-
toothPartEngToKor.put("UP_RIGHT_CANINE", "위쪽 오른쪽 송곳니");
27+
toothPartEngToKor.put("UNDER_RIGHT_CANINE", "아랫쪽 오른쪽 송곳니");
28+
toothPartEngToKor.put("UP_RIGHT_CANINE", "윗쪽 오른쪽 송곳니");
2929
toothPartEngToKor.put("UNDER_RIGHT_MOLAR_OUTSIDE", "아랫쪽 오른쪽 어금니 바깥쪽");
3030
toothPartEngToKor.put("UP_RIGHT_MOLAR_OUTSIDE", "윗쪽 오른쪽 어금니 바깥쪽");
3131
toothPartEngToKor.put("UP_LEFT_MOLAR_CHEWING_SIDE", "윗쪽 왼쪽 어금니 씹는쪽");
@@ -45,7 +45,7 @@ public String toothPartEngToKorFunction(String englishPart) {
4545
public String evaluationPercentValue(Double percent) {
4646
if (100 == percent)
4747
return "적절해요.";
48-
else if (70 <= percent)
48+
else if (60 <= percent)
4949
return "주의해요.";
5050
return "미흡해요.";
5151
}

0 commit comments

Comments
 (0)