Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feat: 안전한 파일 제거 method 추가 #291

Merged
merged 5 commits into from
Jul 10, 2024

Conversation

huGgW
Copy link
Collaborator

@huGgW huGgW commented Jul 7, 2024

Feat: 안전한 파일 제거 method 추가

한줄 요약

  • MainImage, Attachment에 대하여 transaction이 완료했을 경우만 파일을 제거하는 method를 추가하였습니다.

상세 설명

  • CommonFileService.removeFile이 transaction이 commit되었을 경우 event를 listen하여 주어진 경로의 파일을 제거합니다.

17a02c9 Feat: Create file delete event.
998be6c Feat: Create File Delete Event Listener, only delete file when transaction commit.
eeb765d Feat: Add remove entity method which publish file delete event.

TODO

기존 deprecated된 파일 safe delete 방식 제거.

@huGgW huGgW requested a review from leeeryboy July 7, 2024 07:42
@huGgW huGgW self-assigned this Jul 7, 2024
Copy link

github-actions bot commented Jul 7, 2024

Test Results

12 files  12 suites   1s ⏱️
59 tests 59 ✔️ 0 💤 0
66 runs  66 ✔️ 0 💤 0

Results for commit d4842a1.

♻️ This comment has been updated with latest results.

@huGgW huGgW force-pushed the feat/transaction-safe-file-deletion branch from c72800b to 133b8ad Compare July 7, 2024 15:49
Copy link
Contributor

@leeeryboy leeeryboy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@leeeryboy leeeryboy merged commit 8b6bba1 into develop Jul 10, 2024
3 checks passed
@huGgW huGgW deleted the feat/transaction-safe-file-deletion branch July 11, 2024 15:21
leeeryboy added a commit that referenced this pull request Jul 16, 2024
* Feat: Internal GET, PUT API 추가 (#288)

* Refactor: Remove unused interface

* Feat: Create Internal Entity, Dto

* Feat: Create Internal Repository, Service.

* Feat: Create Internal Controller

* Test: Add Test for Internal Domain.

* Feat: Main API에서 중요 공지 갯수 optional하게 전달하도록 수정 (#289)

* Feat: Change to get count optional for repositories.

* Feat: Change service method to get important count as optional.

* Feat: Change importCnt query param as optional.

* 인증서 세팅 + migrate api 일부 삭제 (#290)

* delete migrate api

* set new ssl certificate

* style: ktlint

* Feat: 안전한 파일 제거 method 추가 (#291)

* Feat: Create file delete event.

* Feat: Create File Delete Event Listener, only delete file when transaction commit.

* Feat: Add remove entity method which publish file delete event.

* Refactor: change old delete method name to deprecated.

---------

Co-authored-by: Junhyeong Kim <leeeryboy@gmail.com>

* Feat: Staff 수정 API 추가 (#292)

* Feat: Add request body for create, modify staff.

* Refactor: Make DTO as representation of entity.

* Refactor: Change language as changable.

* Feat: Change CUD method to properly update file, search index.

* Feat: Change CUD api to use proper request body, remove migrate api.

* Comment: Add comment.

* Test: Fix staff service test.

* fix: 교수회의실 예약 권한 변경 (#293)

* fix: 교수회의실 예약 권한 변경

* fix: 교수회의실 예약 권한 변경

* 로그인 취약점 수정 및 Caddyfile.dev 추가 (#295)

* update deprecated methods and enable csrf

* create Caddyfile.dev

* add swagger reverse proxy

* remove swagger related path

* update api for single html page (#294)

* feat: update guide

* update search entity

* update degree requirements

* save csrf cookie (#297)

* 스프링 세션 설정 변경 (#298)

* fix timeout to 9h and set cookie same-site lax

* disable csrf

* remove unnecessary import

* Feat: Professor 수정 API 추가 (#296)

* Feat: Add Request Body for create, update.

* Feat: Change DTO to use representation layer purely.

* Feat: Change service method to use request body, delete files properly.

* Refactor: Remove unused method.

* Feat: Change request body for create, update. Change update to POST.

* Test: Fix test to use updated request body.

* Comment: Add newImage multipart description for updateProfessor.

* Refactor: Remove unused migrate codes.

* Refactor: change updateProfessor api to PUT

---------

Co-authored-by: 우혁준 (Logan) <whjoon0225@naver.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants