+week2.JPA-challenge
+
+
+ ### Member Test
+
+ 
+
+
+
+ ### Song Test
+
+ 
+
+
+
+ ### PlayList Test
+
+ 
+
+
+
+### PlayListSong Test
+
+
+
+
+
diff --git a/YoungJu-Lee-Spring/build.gradle b/YoungJu-Lee-Spring/build.gradle
index a1389d9..a7b06bb 100644
--- a/YoungJu-Lee-Spring/build.gradle
+++ b/YoungJu-Lee-Spring/build.gradle
@@ -33,6 +33,9 @@ dependencies {
// h2 연결
runtimeOnly 'com.h2database:h2'
+
+ // 쿼리 파라미터 확인
+ implementation 'com.github.gavlyukovskiy:p6spy-spring-boot-starter:1.9.0'
}
tasks.named('test') {
diff --git a/YoungJu-Lee-Spring/src/main/java/com/example/YoungJu_Lee_Spring/YoungJuLeeSpringApplication.java b/YoungJu-Lee-Spring/src/main/java/com/example/YoungJu_Lee_Spring/YoungJuLeeSpringApplication.java
index 3116cc9..56e676f 100644
--- a/YoungJu-Lee-Spring/src/main/java/com/example/YoungJu_Lee_Spring/YoungJuLeeSpringApplication.java
+++ b/YoungJu-Lee-Spring/src/main/java/com/example/YoungJu_Lee_Spring/YoungJuLeeSpringApplication.java
@@ -2,8 +2,10 @@
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
+import org.springframework.data.jpa.repository.config.EnableJpaAuditing;
@SpringBootApplication
+@EnableJpaAuditing
public class YoungJuLeeSpringApplication {
public static void main(String[] args) {
diff --git a/YoungJu-Lee-Spring/src/main/java/com/example/YoungJu_Lee_Spring/domain/Album.java b/YoungJu-Lee-Spring/src/main/java/com/example/YoungJu_Lee_Spring/domain/Album.java
new file mode 100644
index 0000000..0177b98
--- /dev/null
+++ b/YoungJu-Lee-Spring/src/main/java/com/example/YoungJu_Lee_Spring/domain/Album.java
@@ -0,0 +1,31 @@
+package com.example.YoungJu_Lee_Spring.domain;
+
+import jakarta.persistence.*;
+import lombok.*;
+import java.util.List;
+import java.util.ArrayList;
+
+@Entity
+@Getter
+@NoArgsConstructor(access = AccessLevel.PROTECTED)
+@AllArgsConstructor
+@Builder
+public class Album {
+ @Id
+ @GeneratedValue(strategy = GenerationType.IDENTITY)
+ @Column(name = "album_id")
+ private Long id;
+
+ private String title;
+
+ @ManyToOne(fetch = FetchType.LAZY)
+ @JoinColumn(name = "artist_id")
+ private Artist artist;
+ public void setArtist(Artist artist) {
+ this.artist = artist;
+ }
+
+ @OneToMany(mappedBy = "album", cascade = CascadeType.ALL)
+ private List