Skip to content

Commit

Permalink
Revert "Sanere Leesah FoedselV1" (#1175)
Browse files Browse the repository at this point in the history
* Revert "Sanere Leesah FoedselV1 (#1174)"

This reverts commit ff7020e.

* Må beholde FoedselV1 så lenge VTP sender hendelser

* Unødig import
  • Loading branch information
jolarsen committed Jun 17, 2024
1 parent ff7020e commit 8fb7067
Show file tree
Hide file tree
Showing 4 changed files with 16 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -105,9 +105,9 @@ void handleMessage(String key, Personhendelse payload) { // key er spesialtegn +
private void håndterFødselsdato(Personhendelse payload) {
var foedselsdato = payload.getFoedselsdato();
if (foedselsdato != null) {
loggMottakMedDato(payload, "fødsel dato", "fødselsdato", foedselsdato.getFoedselsdato());
loggMottakMedDato(payload, "fødselsdato", "fødselsdato", foedselsdato.getFoedselsdato());
} else {
loggMottakUtenDato(payload, "fødsel dato");
loggMottakUtenDato(payload, "fødselsdato");
}
var pdlFødsel = oversetter.oversettFødselsdato(payload);
prosesserHendelseVidereHvisRelevant(pdlFødsel);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ public class PdlLeesahOversetter {

private static final Logger LOG = LoggerFactory.getLogger(PdlLeesahOversetter.class);

public static final String FØDSEL = "FOEDSEL_V1";
public static final String FØDSELSDATO = "FOEDSELSDATO_V1";
public static final String DØD = "DOEDSFALL_V1";
public static final String DØDFØDSEL = "DOEDFOEDT_BARN_V1";
Expand Down
2 changes: 2 additions & 0 deletions domene/src/main/resources/avro/leesah/Personhendelse.avdl
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
protocol PersonhendelseProto {
import idl "doedfoedtbarn/DoedfoedtBarn.avdl";
import idl "doedsfall/Doedsfall.avdl";
import idl "foedsel/Foedsel.avdl";
import idl "foedselsdato/Foedselsdato.avdl";
import idl "utflytting/Utflytting.avdl";

Expand All @@ -25,6 +26,7 @@ protocol PersonhendelseProto {

union { null, no.nav.person.pdl.leesah.doedfoedtbarn.DoedfoedtBarn } doedfoedtBarn = null;
union { null, no.nav.person.pdl.leesah.doedsfall.Doedsfall } doedsfall = null;
union { null, no.nav.person.pdl.leesah.foedsel.Foedsel } foedsel = null;
union { null, no.nav.person.pdl.leesah.foedselsdato.Foedselsdato } foedselsdato = null;
union { null, no.nav.person.pdl.leesah.utflytting.UtflyttingFraNorge } utflyttingFraNorge = null;
}
Expand Down
11 changes: 11 additions & 0 deletions domene/src/main/resources/avro/leesah/foedsel/Foedsel.avdl
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
@namespace("no.nav.person.pdl.leesah.foedsel")
protocol FoedselV1 {

record Foedsel {
union { null, int } foedselsaar = null;
union { null, date } foedselsdato = null;
union { null, string } foedeland = null;
union { null, string } foedested = null;
union { null, string } foedekommune = null;
}
}

0 comments on commit 8fb7067

Please sign in to comment.