Skip to content

Commit

Permalink
OK-591 Use timestamps from SiirtotiedostoProsessi
Browse files Browse the repository at this point in the history
  • Loading branch information
msiukola committed Oct 3, 2024
1 parent 91a5227 commit 2aba386
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@

import fi.vm.sade.service.valintaperusteet.ovara.ajastus.impl.SiirtotiedostoProsessiRepositoryImpl;
import fi.vm.sade.service.valintaperusteet.service.impl.SiirtotiedostoServiceImpl;
import java.time.LocalDateTime;
import java.time.OffsetDateTime;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
Expand Down Expand Up @@ -33,7 +32,8 @@ public String createNextSiirtotiedosto() {

try {
String resultInfo =
siirtotiedostoServiceImpl.createSiirtotiedostot(LocalDateTime.now(), LocalDateTime.now());
siirtotiedostoServiceImpl.createSiirtotiedostot(
uusi.getWindowStart().toLocalDateTime(), uusi.getWindowEnd().toLocalDateTime());
uusi.setSuccess(true);
uusi.setInfo(resultInfo);
uusi.setRunEnd(OffsetDateTime.now());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,7 @@ private HakuparametritDTO createDto(String hakukohdeOid) {
}

public String createSiirtotiedostot(LocalDateTime startDatetime, LocalDateTime endDatetime) {
logger.info("Creating siirtotiedostot for window {} - {}", startDatetime, endDatetime);
List<String> oids = hakukohdeViiteDAO.findNewOrChangedHakukohdeOids(startDatetime, endDatetime);
List<String> siirtotiedostoKeys = new ArrayList<>();
String operationId = UUID.randomUUID().toString();
Expand Down

0 comments on commit 2aba386

Please sign in to comment.