Skip to content

Commit

Permalink
Add logging when SituationNumber is null - for traceability
Browse files Browse the repository at this point in the history
  • Loading branch information
lassetyr committed Oct 21, 2024
1 parent 90d7bce commit 95938c8
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/main/java/no/rutebanken/anshar/data/Situations.java
Original file line number Diff line number Diff line change
Expand Up @@ -308,8 +308,12 @@ public Collection<PtSituationElement> addAll(String datasetId, List<PtSituationE
AtomicInteger alreadyExpiredCounter = new AtomicInteger(0);
AtomicInteger ignoredCounter = new AtomicInteger(0);
sxList.stream()
.filter(situation -> situation.getSituationNumber() != null)
.forEach(situation -> {

if (situation.getSituationNumber() == null) {
logger.warn("SituationNumber is null, skipping");
return;
}
TimingTracer timingTracer = new TimingTracer("single-sx");

SiriObjectStorageKey key = createKey(datasetId, situation);
Expand Down

0 comments on commit 95938c8

Please sign in to comment.