Skip to content

Commit

Permalink
Brreg-stub hibernate 6 migrering
Browse files Browse the repository at this point in the history
#deploy-brreg-stub
  • Loading branch information
stigus committed Oct 20, 2023
1 parent 3ee01e9 commit 0c74e8d
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
import jakarta.persistence.SequenceGenerator;
import jakarta.persistence.Table;
import jakarta.validation.constraints.NotNull;
import lombok.Getter;
Expand All @@ -16,7 +18,8 @@
public class HentRolle {

@Id
@GeneratedValue
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "hentrolle_seq")
@SequenceGenerator(name = "hentrolle_seq", sequenceName = "HENTROLLE_SEQ", allocationSize = 1)
private Long id;

@NotNull(message = "orgnr must not be null")
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,9 @@
import jakarta.persistence.Column;
import jakarta.persistence.Entity;
import jakarta.persistence.GeneratedValue;
import jakarta.persistence.GenerationType;
import jakarta.persistence.Id;
import jakarta.persistence.SequenceGenerator;
import jakarta.persistence.Table;
import jakarta.validation.constraints.NotNull;
import lombok.Getter;
Expand All @@ -16,7 +18,8 @@
public class Rolleoversikt {

@Id
@GeneratedValue
@GeneratedValue(strategy = GenerationType.SEQUENCE, generator = "rolleoversikt_seq")
@SequenceGenerator(name = "rolleoversikt_seq", sequenceName = "ROLLEOVERSIKT_SEQ", allocationSize = 1)
private Long id;

@NotNull(message = "fnr must not be null")
Expand Down

0 comments on commit 0c74e8d

Please sign in to comment.