MME-5 Remove @Lob annotations.
This commit is contained in:
parent
24832449f6
commit
164a3aa5f0
@ -5,6 +5,7 @@ import io.hypersistence.utils.hibernate.type.json.JsonBinaryType;
|
||||
import jakarta.persistence.*;
|
||||
import lombok.Data;
|
||||
import org.hibernate.annotations.Type;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
import java.time.OffsetDateTime;
|
||||
import java.util.UUID;
|
||||
@ -26,7 +27,7 @@ public class Job {
|
||||
@Column(nullable = false, updatable = false)
|
||||
private OffsetDateTime created;
|
||||
|
||||
private OffsetDateTime modified;
|
||||
private @Nullable OffsetDateTime modified;
|
||||
|
||||
@Column(nullable = false)
|
||||
@Enumerated(EnumType.STRING)
|
||||
@ -48,13 +49,11 @@ public class Job {
|
||||
@Column(nullable = false)
|
||||
private OffsetDateTime runAfter;
|
||||
|
||||
private String lockedBy;
|
||||
private @Nullable String lockedBy;
|
||||
|
||||
private OffsetDateTime lockedAt;
|
||||
private @Nullable OffsetDateTime lockedAt;
|
||||
|
||||
@Lob
|
||||
@Column(columnDefinition = "TEXT")
|
||||
@Basic(fetch = FetchType.LAZY)
|
||||
private String lastError;
|
||||
private @Nullable String lastError;
|
||||
|
||||
}
|
||||
|
||||
@ -41,14 +41,11 @@ public class Recipe {
|
||||
@Nullable
|
||||
private Integer totalTime;
|
||||
|
||||
@Lob
|
||||
@Column(name = "raw_text", columnDefinition = "TEXT", nullable = false)
|
||||
@Basic(fetch = FetchType.LAZY)
|
||||
@Column(columnDefinition = "TEXT", nullable = false)
|
||||
private String rawText;
|
||||
|
||||
@Lob
|
||||
@Column(name = "cached_rendered_text", columnDefinition = "TEXT")
|
||||
@Basic(fetch = FetchType.LAZY)
|
||||
@Column(columnDefinition = "TEXT")
|
||||
@Nullable
|
||||
private String cachedRenderedText;
|
||||
|
||||
@ManyToOne(optional = false)
|
||||
|
||||
@ -53,6 +53,8 @@ public class RecipeDraft {
|
||||
private @Nullable Integer preparationTime;
|
||||
private @Nullable Integer cookingTime;
|
||||
private @Nullable Integer totalTime;
|
||||
|
||||
@Column(columnDefinition = "TEXT")
|
||||
private @Nullable String rawText;
|
||||
|
||||
@Type(JsonBinaryType.class)
|
||||
|
||||
@ -4,6 +4,7 @@ import app.mealsmadeeasy.api.recipe.Recipe;
|
||||
import app.mealsmadeeasy.api.user.User;
|
||||
import jakarta.persistence.*;
|
||||
import lombok.Data;
|
||||
import org.jetbrains.annotations.Nullable;
|
||||
|
||||
import java.time.OffsetDateTime;
|
||||
|
||||
@ -22,12 +23,11 @@ public final class RecipeComment {
|
||||
|
||||
private OffsetDateTime modified;
|
||||
|
||||
@Lob
|
||||
@Basic(fetch = FetchType.LAZY)
|
||||
@Column(columnDefinition = "TEXT", nullable = false)
|
||||
private String rawText;
|
||||
|
||||
@Lob
|
||||
@Basic(fetch = FetchType.LAZY)
|
||||
@Column(columnDefinition = "TEXT")
|
||||
@Nullable
|
||||
private String cachedRenderedText;
|
||||
|
||||
@ManyToOne
|
||||
|
||||
Loading…
Reference in New Issue
Block a user