🗃️ chunk size change
This commit is contained in:
부모
bda2d812ff
커밋
bff4de17c7
@ -103,7 +103,7 @@ public class ShipDetailUpdateJobConfig extends BaseJobConfig<ShipDetailCompariso
|
||||
|
||||
@Override
|
||||
protected int getChunkSize() {
|
||||
return 1; // API에서 100개씩 가져오므로 chunk도 100으로 설정
|
||||
return 20; // API에서 100개씩 가져오므로 chunk도 100으로 설정
|
||||
}
|
||||
|
||||
@Bean(name = "ShipDetailUpdateJob")
|
||||
|
||||
@ -47,7 +47,7 @@ public class ShipDetailUpdateDataReader extends BaseApiReader<ShipDetailComparis
|
||||
// DB 해시값을 저장할 맵
|
||||
private Map<String, String> dbMasterHashes;
|
||||
private int currentBatchIndex = 0;
|
||||
private final int batchSize = 1;
|
||||
private final int batchSize = 20;
|
||||
|
||||
public ShipDetailUpdateDataReader(WebClient webClient, JdbcTemplate jdbcTemplate, ObjectMapper objectMapper,BatchDateService batchDateService) {
|
||||
super(webClient);
|
||||
@ -261,18 +261,12 @@ public class ShipDetailUpdateDataReader extends BaseApiReader<ShipDetailComparis
|
||||
.uri(url, uriBuilder -> uriBuilder
|
||||
// 맵에서 파라미터 값을 동적으로 가져와 세팅
|
||||
.queryParam("shipsCategory", params.get("shipsCategory"))
|
||||
// .queryParam("fromYear", params.get("fromYear"))
|
||||
// .queryParam("fromMonth", params.get("fromMonth"))
|
||||
// .queryParam("fromDay", params.get("fromDay"))
|
||||
// .queryParam("toYear", params.get("toYear"))
|
||||
// .queryParam("toMonth", params.get("toMonth"))
|
||||
// .queryParam("toDay", params.get("toDay"))
|
||||
.queryParam("fromYear", "2025")
|
||||
.queryParam("fromMonth", "10")
|
||||
.queryParam("fromDay", "15")
|
||||
.queryParam("toYear", "2025")
|
||||
.queryParam("toMonth", "12")
|
||||
.queryParam("toDay", "17")
|
||||
.queryParam("fromYear", params.get("fromYear"))
|
||||
.queryParam("fromMonth", params.get("fromMonth"))
|
||||
.queryParam("fromDay", params.get("fromDay"))
|
||||
.queryParam("toYear", params.get("toYear"))
|
||||
.queryParam("toMonth", params.get("toMonth"))
|
||||
.queryParam("toDay", params.get("toDay"))
|
||||
.build())
|
||||
.retrieve()
|
||||
.bodyToMono(ShipUpdateApiResponse.class)
|
||||
|
||||
불러오는 중...
Reference in New Issue
Block a user