boaz-lol / lp-server

리그오브레전드 패치노트 데이터화 프로젝트 서버
0 stars 0 forks source link

[DB] core-mongodb 모듈 생성 및 Sub Database 연결 #11

Closed sunnyineverywhere closed 4 months ago

sunnyineverywhere commented 5 months ago

application-mongo.yaml

spring:
  data:
    mongodb:
      uri: # url 입력

storage/core-mongo/build.gradle.kts

import org.springframework.boot.gradle.tasks.bundling.BootJar

val jar: Jar by tasks
val bootJar: BootJar by tasks

bootJar.enabled = false
jar.enabled = true

allOpen {
    annotation("jakarta.persistence.Entity")
    annotation("jakarta.persistence.MappedSuperclass")
    annotation("jakarta.persistence.Embeddable")
}

dependencies {
    implementation("org.springframework.boot:spring-boot-starter-data-mongodb")
    implementation("org.springframework.boot:spring-boot-starter-data-mongodb-reactive")
}