-
Notifications
You must be signed in to change notification settings - Fork 3
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
Bug/#341 유저가 다른 주식에 접근할 때 예전 주식의 실시간 데이터가 보이는 버그 수정 #350
Merged
Merged
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
bbb9b62
♻️ refactor: 분봉 데이터 callback 형태로 바꿔 우선순위 큐 적용, 리팩토링
swkim12345 fc145a9
♻️ refactor: 분단위 데이터 수집 stock limit 200, 콜백함수로 리팩토링
swkim12345 fc840c9
🐛 fix: afterUpdate 적용 위한 upsert구문으로 변경
swkim12345 9ae9f3a
💄 style: 분단위 테스트 이후 테스트 코드 삭제 및 조건 원복
swkim12345 3ae677c
💄 style: dto 안 쓰이는 속성 삭제
swkim12345 31d2ef7
💄 style: console.log 삭제
swkim12345 72edf0d
📝 docs: liveData에 unsubscribe, subscribe 메시지 info로 출력 추가
swkim12345 65ecaaa
🐛 fix: 알람을 한번만 보내고 삭제처리하게 만듦
swkim12345 ac48ade
🐛 fix: 유저가 동시에 다른 주식 방에 있는 것을 방지
swkim12345 c69ebd9
🐛 fix: 유저가 동시에 다른 주식에 접속하는 것을 막음
swkim12345 d45d2e6
🐛 fix: client leave 추ㅏㄱ
swkim12345 a4571c1
🐛 fix: leave 코드가 values를 검사하는 로직보다 뒤에 있어 발생되는 문제 해결
swkim12345 f2ad68b
🐛 fix: delete도 이동
swkim12345 629b47d
🐛 fix: deadlock 발생 없이 동시성 제어
swkim12345 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 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 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 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 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 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
60 changes: 49 additions & 11 deletions
60
packages/backend/src/scraper/openapi/type/openapiMinuteData.type.ts
This file contains 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 |
---|---|---|
@@ -1,35 +1,73 @@ | ||
/* eslint-disable @typescript-eslint/no-explicit-any */ | ||
|
||
export type MinuteData = { | ||
export type MinuteDataOutput1 = { | ||
prdy_vrss: string; | ||
prdy_vrss_sign: string; | ||
prdy_ctrt: string; | ||
stck_prdy_clpr: string; | ||
acml_vol: string; | ||
acml_tr_pbmn: string; | ||
hts_kor_isnm: string; | ||
stck_prpr: string; | ||
}; | ||
|
||
export type MinuteDataOutput2 = { | ||
stck_bsop_date: string; | ||
stck_cntg_hour: string; | ||
acml_tr_pbmn: string; | ||
stck_prpr: string; | ||
stck_oprc: string; | ||
stck_hgpr: string; | ||
stck_lwpr: string; | ||
cntg_vol: string; | ||
}; | ||
|
||
export type MinuteData = { | ||
stck_bsop_date: string; | ||
stck_cntg_hour: string; | ||
acml_tr_pbmn: string; | ||
acml_vol: string; | ||
stck_prpr: string; | ||
stck_oprc: string; | ||
stck_hgpr: string; | ||
stck_lwpr: string; | ||
cntg_vol: string; | ||
}; | ||
|
||
export type UpdateStockQuery = { | ||
fid_etc_cls_code: string; | ||
fid_cond_mrkt_div_code: 'J' | 'W'; | ||
fid_input_iscd: string; | ||
fid_input_hour_1: string; | ||
fid_pw_data_incu_yn: 'Y' | 'N'; | ||
export const isMinuteDataOutput1 = (data: any): data is MinuteDataOutput1 => { | ||
return ( | ||
data !== null && | ||
typeof data === 'object' && | ||
typeof data.prdy_vrss === 'string' && | ||
typeof data.prdy_vrss_sign === 'string' && | ||
typeof data.prdy_ctrt === 'string' && | ||
typeof data.stck_prdy_clpr === 'string' && | ||
typeof data.acml_vol === 'string' && | ||
typeof data.acml_tr_pbmn === 'string' && | ||
typeof data.hts_kor_isnm === 'string' && | ||
typeof data.stck_prpr === 'string' | ||
); | ||
}; | ||
|
||
export const isMinuteData = (data: any) => { | ||
export const isMinuteDataOutput2 = (data: any): data is MinuteDataOutput2 => { | ||
return ( | ||
data && | ||
data !== null && | ||
typeof data === 'object' && | ||
typeof data.stck_bsop_date === 'string' && | ||
typeof data.stck_cntg_hour === 'string' && | ||
typeof data.acml_tr_pbmn === 'string' && | ||
typeof data.stck_prpr === 'string' && | ||
typeof data.stck_oprc === 'string' && | ||
typeof data.stck_hgpr === 'string' && | ||
typeof data.stck_lwpr === 'string' && | ||
typeof data.cntg_vol === 'string' && | ||
typeof data.acml_tr_pbmn === 'string' | ||
typeof data.cntg_vol === 'string' | ||
); | ||
}; | ||
|
||
export type UpdateStockQuery = { | ||
fid_etc_cls_code: string; | ||
fid_cond_mrkt_div_code: 'J' | 'W'; | ||
fid_input_iscd: string; | ||
fid_input_hour_1: string; | ||
fid_pw_data_incu_yn: 'Y' | 'N'; | ||
}; |
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이렇게 하면 일부는 알림을 못보내지 않나요?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
이거 없앤 다음에 다시 보낼게요!