NPE 대응

This commit is contained in:
Rinjae
2025-12-19 13:30:05 +09:00
parent d719b75c40
commit d1e8c29791
@@ -23,11 +23,10 @@ public class ObpGwMetricService {
}
/**
* UPSERT 판단을 위한 기존 데이터 조회
* UPSERT 판단을 위한 기존 데이터 조회 (NULL 안전)
*/
public Optional<ObpGwMetric> findByUniqueKey(LocalDateTime timeslice, String apiId, String clientId, String hostname, String orgId) {
return repository.findByTimesliceAndApiIdAndClientIdAndHostnameAndOrgId(
timeslice, apiId, clientId, hostname, orgId);
return repository.findByUniqueKeyNullSafe(timeslice, apiId, clientId, hostname, orgId);
}
/**