Skip to content

Commit

Permalink
v1.1.0 aws 계정 이관작업 (#262)
Browse files Browse the repository at this point in the history
* chore: config hotfix 반영 (#249)

* hotfix: 랭킹 조회 업데이트

* hotfix: RestControllerAdvice 순서 적용

* refactor: SlackNotification 어노테이션 기반으로 수정

* fix: 빌드 오류 해결

* refactor: 검색 기능 쿼리 변경 (#254)

* feat: init.sql fulltext index 추가

* refactor: 엔티티에 FullText Index 정보 추가

* feat: custom hibernate sql 추가 (match against), 적용

* refactor: test 코드 수정

* feat: 쿠폰 캐싱 기능 구현 (#255)

* retactor : ClockHolder 메서드명 변경

* feat: ClockHolder 시간 추가

* style: ClockHolder 및 메서드명 변경

* feat : Cache 기능 추가

* docs : Reame 작성

* refactor: Match Against 변경

* refactor: rollback

* feat: restdoc openapi 연동 (#259)

* refactor: Readme 수정 (#261)

* feat: java scouter 추가

* refactor: Readme 파일 수정

* fix: aws 다른 계정 이관하면서 acm 추가로 인한 수정

* fix: docker-compose certbot 해제

* feat: rds config 수정

---------

Co-authored-by: parksey <parkseyeon99@naver.com>
Co-authored-by: kmebin <blowhuiee@gmail.com>
Co-authored-by: Youngmyung Kim <83266154+ymkim97@users.noreply.github.com>
Co-authored-by: 홍혁준 <31675711+HyuckJuneHong@users.noreply.github.com>
Co-authored-by: ymkim97 <rladudaud97@naver.com>
  • Loading branch information
6 people authored Mar 10, 2024
1 parent 20fcf79 commit 7da0544
Show file tree
Hide file tree
Showing 52 changed files with 893 additions and 2,220 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -124,3 +124,4 @@ src/main/resources/config
!application-test.yml
src/main/generated
dump.rdb
/src/main/resources/firebase-local.json
55 changes: 54 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,54 @@
# moabam-BE
## 🐥 MOABAM 서비스

![img.png](readme-image/img.png)

![img_1.png](readme-image/img_1.png)

<br><br>

## 👨‍👨‍👧 Backend Team 소개

| 김영명 | 김희빈(PO) | 박세연 | 신재윤 | 홍혁준(SM) |
|:------------------------------------------------------------------------------:|:------------------------------------------------------------------------------:|:------------------------------------------------------------------------------:|:------------------------------------------------------------------------------:|:------------------------------------------------------------------------------:|
| DEVELOPER | DEVELOPER | DEVELOPER | DEVELOPER | DEVELOPER |
| <img src="https://avatars.githubusercontent.com/u/83266154?v=4" width="250" /> | <img src="https://avatars.githubusercontent.com/u/72112845?v=4" width="250" /> | <img src="https://avatars.githubusercontent.com/u/54196094?v=4" width="250" /> | <img src="https://avatars.githubusercontent.com/u/87688023?v=4" width="250" /> | <img src="https://avatars.githubusercontent.com/u/31675711?v=4" width="250" /> |
| [ymkim97](https://github.com/ymkim97) | [kmebin](https://github.com/kmebin) | [parksey](https://github.com/parksey) | [DevUni](https://github.com/Shin-Jae-Yoon) | [HongDosan](https://github.com/HyuckJuneHong) |
| 방 도메인, 루틴 인증(메인) | 상품 도메인, 결제, 에러 알림, BE 팀장 | 회원 도메인, 랭킹 어드민 페이지 | 방 도메인, 루틴 인증(서브), 인프라 (AWS, CI/CD) | 쿠폰 도메인, 알림, 선착순 이벤트, 캐싱 |

<br><br>

## 공통 협업 방식

![img.png](readme-image/협업.png)

## 서비스 아키텍처

![img.png](readme-image/서비스-아키텍처.png)

## CI/CD 파이프라인

![img.png](readme-image/파이프라인.png)

## 테이블 아키텍처

![img.png](readme-image/table.png)

## API 명세

![img.png](readme-image/api.png)

## 컨벤션

![img_1.png](readme-image/컨벤션.png)

## Config 관리

![img.png](readme-image/콘피그.png)

## Test

![img.png](readme-image/테스트.png)

## 협업 규칙
![image](https://github.com/team-moabam/moabam-BE/assets/31675711/1c9ae816-9174-42fd-959a-bad9f375878d)

111 changes: 51 additions & 60 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ plugins {
id 'org.sonarqube' version '4.4.1.3373'
id 'jacoco'
id 'checkstyle'
id 'org.asciidoctor.jvm.convert' version '3.3.2'
id 'com.epages.restdocs-api-spec' version '0.18.4'
}

group = 'com.moabam'
Expand All @@ -15,21 +15,27 @@ java {
sourceCompatibility = '17'
}

ext {
snippetsDir = file('build/generated-snippets')
compileJava {
options.compilerArgs << '-parameters'
options.encoding = 'UTF-8'
}

compileTestJava {
options.compilerArgs << '-parameters'
options.encoding = 'UTF-8'
}

def querydslSrcDir = 'src/main/generated'

clean {
delete file(querydslSrcDir)
}

tasks.withType(JavaCompile) {
options.generatedSourceOutputDirectory = file(querydslSrcDir)
}

configurations {
asciidoctorExtensions

compileOnly {
extendsFrom annotationProcessor
}
Expand Down Expand Up @@ -58,7 +64,14 @@ dependencies {

// Test
testImplementation 'org.springframework.boot:spring-boot-starter-test'
testImplementation 'com.squareup.okhttp3:mockwebserver:4.11.0'
testImplementation 'com.squareup.okhttp3:mockwebserver'

// RestDocs
testImplementation 'org.springframework.restdocs:spring-restdocs-mockmvc'
testImplementation 'com.epages:restdocs-api-spec-mockmvc:0.18.4'

// Swagger
implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.2.0'

// Querydsl
implementation 'com.querydsl:querydsl-jpa:5.0.0:jakarta'
Expand All @@ -75,6 +88,9 @@ dependencies {
// Apache Commons Lang 3
implementation 'org.apache.commons:commons-lang3:3.13.0'

// Cache
implementation 'org.springframework.boot:spring-boot-starter-cache'

// Redis
implementation 'org.springframework.boot:spring-boot-starter-data-redis'

Expand All @@ -92,12 +108,6 @@ dependencies {
// JSON parser
implementation 'org.json:json:20230618'

// Asciidoctor
asciidoctorExtensions 'org.springframework.restdocs:spring-restdocs-asciidoctor'

// RestDocs
testImplementation 'org.springframework.restdocs:spring-restdocs-mockmvc'

// S3
implementation platform("io.awspring.cloud:spring-cloud-aws-dependencies:3.0.2")
implementation 'io.awspring.cloud:spring-cloud-aws-starter-s3'
Expand All @@ -110,9 +120,6 @@ dependencies {

// Logback Slack Appender
implementation 'com.github.maricn:logback-slack-appender:1.6.1'

// Swagger
implementation 'org.springdoc:springdoc-openapi-starter-webmvc-ui:2.2.0'
}

tasks.named('test') {
Expand All @@ -134,28 +141,25 @@ jacocoTestReport {

afterEvaluate {
classDirectories.setFrom(
files(classDirectories.files.collect {
fileTree(dir: it, excludes: [
"**/*Application*",
"**/*Config*",
"**/*Request*",
"**/*Response*",
"**/*Exception*",
"**/*Mapper*",
"**/*ErrorMessage*",
"**/*DynamicQuery*",
"**/*BaseTimeEntity*",
"**/*HealthCheckController*",
"**/*S3Manager*",
] + Qdomains)
})
files(classDirectories.files.collect {
fileTree(dir: it, excludes: [
"**/*Application*",
"**/*Config*",
"**/*Request*",
"**/*Response*",
"**/*Exception*",
"**/*Mapper*",
"**/*ErrorMessage*",
"**/*DynamicQuery*",
"**/*BaseTimeEntity*",
"**/*HealthCheckController*",
"**/*S3Manager*",
] + Qdomains)
})
)
}
}

compileJava.options.encoding = 'UTF-8'
compileTestJava.options.encoding = 'UTF-8'

tasks.withType(Checkstyle).configureEach {
reports {
xml.required = true
Expand All @@ -177,37 +181,24 @@ sonar {
property "sonar.host.url", "https://sonarcloud.io"
property 'sonar.coverage.jacoco.xmlReportPaths', 'build/reports/jacoco/test/jacocoTestReport.xml'
property 'sonar.coverage.exclusions', '**/test/**, **/Q*.java, **/*Doc*.java, **/resources/** ' +
',**/*Application*.java , **/*Config*.java, **/*Request*.java, **/*Response*.java ,**/*Exception*.java ' +
',**/*ErrorMessage*.java, **/*Mapper*.java, **/*DynamicQuery*, **/*BaseTimeEntity*, **/*HealthCheckController* ' +
', **/*S3Manager*.java'
',**/*Application*.java , **/*Config*.java, **/*Request*.java, **/*Response*.java ,**/*Exception*.java ' +
',**/*ErrorMessage*.java, **/*Mapper*.java, **/*DynamicQuery*, **/*BaseTimeEntity*, **/*HealthCheckController* ' +
', **/*S3Manager*.java'
property 'sonar.java.checkstyle.reportPaths', 'build/reports/checkstyle/main.xml'
}
}

test {
outputs.dir snippetsDir
}
openapi3 {
servers = [
{ url = 'http://localhost:8080' },
{ url = 'http://dev.moabam.com' }
]

asciidoctor {
configurations 'asciidoctorExtensions'
inputs.dir snippetsDir
dependsOn test
}
title = 'MOABAM API DOCS'
format = 'json'

asciidoctor.doFirst {
delete file('src/main/resources/static/docs')
}

tasks.register('copyDocument', Copy) {
dependsOn asciidoctor
from file("build/docs/asciidoc")
into file("src/main/resources/static/docs")
}

bootJar {
dependsOn copyDocument
}

build {
dependsOn copyDocument
copy {
from 'build/api-spec'
into 'src/main/resources/static/docs'
}
}
3 changes: 2 additions & 1 deletion infra/Dockerfile
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@ ARG SPRING_ACTIVE_PROFILES
ENV SPRING_ACTIVE_PROFILES ${SPRING_ACTIVE_PROFILES}

COPY build/libs/moabam-server-0.0.1-SNAPSHOT.jar moabam.jar
COPY src/main/resources/config/agent.java/ agent.java

ENTRYPOINT ["java", "-jar", "-Duser.timezone=Asia/Seoul", "-Dspring.profiles.active=${SPRING_ACTIVE_PROFILES}", "/moabam.jar"]
ENTRYPOINT ["java", "-javaagent:agent.java/scouter.agent.jar", "-Dsocuter.config=agent.java/conf/scouter.conf", "-jar", "-Duser.timezone=Asia/Seoul", "-Dspring.profiles.active=${SPRING_ACTIVE_PROFILES}", "/moabam.jar"]
Loading

0 comments on commit 7da0544

Please sign in to comment.