-
Notifications
You must be signed in to change notification settings - Fork 1
[BE-Feature] 개인 일정 동기화 구현 #374
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
Merged
Merged
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
0d62e97
feat: long polling 구현
kwon204 c106751
feat: syncToken 구현
kwon204 b924797
feat: syncToken을 사용한 동기화와 long polling 응답 구현
kwon204 0230405
chore: 주석 삭제 및 swagger 추가
kwon204 012c4f1
feat: DeferredResultManager 추가
kwon204 d167799
feat: long polling을 위한 DeferredResult 객체 관리 클래스 추가
kwon204 bf9060c
refactor: syncToken 삭제 및 리팩토링
kwon204 09cdae8
test: 테스트 코드 수정
kwon204 3849064
fix: timeout 시간 6초 -> 60초로 변경
kwon204 e1213ba
refactor: 사용하지 않는 클래스 삭제
kwon204 cf9d4fa
fix: deferredResult가 setResult() 되지 않는 버그 수정
kwon204 04c9a8a
fix: 반복 요청을 하면 이전의 연결은 끊고 새로운 연결만 유지하도록 수정
kwon204 7e115ba
refactor: long polling 연결 여부 확인 로직 변경
kwon204 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
17 changes: 17 additions & 0 deletions
17
backend/src/main/java/endolphin/backend/domain/personal_event/dto/SyncPersonalEvent.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,17 @@ | ||
| package endolphin.backend.domain.personal_event.dto; | ||
|
|
||
| import endolphin.backend.global.google.dto.GoogleEvent; | ||
| import java.time.LocalDateTime; | ||
|
|
||
| public record SyncPersonalEvent( | ||
| String googleEventId, | ||
| String title, | ||
| LocalDateTime startDateTime, | ||
| LocalDateTime endDateTime, | ||
| String status | ||
| ) { | ||
kwon204 marked this conversation as resolved.
Show resolved
Hide resolved
|
||
| public static SyncPersonalEvent from(GoogleEvent event) { | ||
| return new SyncPersonalEvent(event.eventId(), event.summary(), event.startDateTime(), | ||
| event.endDateTime(), event.status().getValue()); | ||
| } | ||
| } | ||
20 changes: 20 additions & 0 deletions
20
backend/src/main/java/endolphin/backend/domain/personal_event/dto/SyncResponse.java
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,20 @@ | ||
| package endolphin.backend.domain.personal_event.dto; | ||
|
|
||
| import java.util.List; | ||
|
|
||
| public record SyncResponse( | ||
| List<SyncPersonalEvent> events, | ||
| String type | ||
| ) { | ||
| public static SyncResponse timeout() { | ||
| return new SyncResponse(null, "timeout"); | ||
| } | ||
|
|
||
| public static SyncResponse sync(List<SyncPersonalEvent> events) { | ||
| return new SyncResponse(events, "sync"); | ||
| } | ||
|
|
||
| public static SyncResponse replaced() { | ||
| return new SyncResponse(null, "replaced"); | ||
| } | ||
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
28 changes: 0 additions & 28 deletions
28
backend/src/main/java/endolphin/backend/global/sse/CalendarEventController.java
This file was deleted.
Oops, something went wrong.
49 changes: 0 additions & 49 deletions
49
backend/src/main/java/endolphin/backend/global/sse/SseEmitters.java
This file was deleted.
Oops, something went wrong.
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.