diff --git a/src/main/java/com/server/capple/domain/answer/entity/AnswerHeart.java b/src/main/java/com/server/capple/domain/answer/entity/AnswerHeart.java index cf218498..604b73b6 100644 --- a/src/main/java/com/server/capple/domain/answer/entity/AnswerHeart.java +++ b/src/main/java/com/server/capple/domain/answer/entity/AnswerHeart.java @@ -1,10 +1,10 @@ package com.server.capple.domain.answer.entity; -import jakarta.persistence.Id; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Getter; import lombok.NoArgsConstructor; +import org.springframework.data.annotation.Id; import org.springframework.data.redis.core.RedisHash; @Getter @@ -13,6 +13,7 @@ @AllArgsConstructor @RedisHash("AnswerHeart") public class AnswerHeart { + @Id private Long answerId; private Long memberId; diff --git a/src/main/java/com/server/capple/domain/question/entity/QuestionHeart.java b/src/main/java/com/server/capple/domain/question/entity/QuestionHeart.java index 231ad2e9..b7dc4167 100644 --- a/src/main/java/com/server/capple/domain/question/entity/QuestionHeart.java +++ b/src/main/java/com/server/capple/domain/question/entity/QuestionHeart.java @@ -1,6 +1,6 @@ package com.server.capple.domain.question.entity; -import jakarta.persistence.Id; +import org.springframework.data.annotation.Id; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Getter; diff --git a/src/main/java/com/server/capple/domain/tag/Tag.java b/src/main/java/com/server/capple/domain/tag/Tag.java index 58ee104c..117dc2d5 100644 --- a/src/main/java/com/server/capple/domain/tag/Tag.java +++ b/src/main/java/com/server/capple/domain/tag/Tag.java @@ -1,6 +1,6 @@ package com.server.capple.domain.tag; -import jakarta.persistence.Id; +import org.springframework.data.annotation.Id; import lombok.AllArgsConstructor; import lombok.Builder; import lombok.Getter;