Skip to content
This repository has been archived by the owner on Aug 13, 2022. It is now read-only.

웹소켓을 이용한 1:1 채팅 구현 #30

Open
junshock5 opened this issue Aug 10, 2020 · 0 comments
Open

웹소켓을 이용한 1:1 채팅 구현 #30

junshock5 opened this issue Aug 10, 2020 · 0 comments
Labels
working 작업중입니다.

Comments

@junshock5
Copy link
Collaborator

WebSocket(WebSocket API)
웹소켓 기술을 사용하면 아무런 문제없이 순수 데이터만 실시간 전송이 가능해진다.
웹소켓 방식의 종류는
netty, 스프링, node.js, vert.x 등이 있다.
각각 특징을 조사후에 중고거래 사이트에서 적합한 것을 채택후 적용할 예정이다.

@junshock5 junshock5 added the working 작업중입니다. label Aug 10, 2020
junshock5 added a commit that referenced this issue Aug 24, 2020
- WebSocket 의존성 추가
- WebSocketConfig 추가
- json 의존성 추가
- SocketHandler class 추가
- Chatting Controller 추가
junshock5 added a commit that referenced this issue Aug 24, 2020
- 채팅 jsp 처리를 위한 servlet추가
- ModelAndView 사용 및 chat.jsp 추가
- spring.mvc.view 설정
junshock5 added a commit that referenced this issue Aug 25, 2020
- json-simple 의존성 추가
- sessionID값을 기준으로 채팅 상대방과 분리되게 JSP 변경
- 채팅 message jsonToObjectParser 함수로 파싱 되게 변경
junshock5 added a commit that referenced this issue Aug 25, 2020
- WebSocketHandlerRegistry에 방번호까지 등록
- 채팅방 생성, 이동, 정보 가져오는 method controller에 생성
- 메세지 전송 method에서 세션정보를 갖는 List를 이용해 해당 방에만 유효한 세션을 골라 발송하게 변경
- 방 생성 또는 참여 웹소켓 연결시 방의 인원을 조사후 방번호와 세션을 추가한다.
- 방 퇴장 웹소켓 종료시 해당 세션을 삭제한다.
- 채팅방, 방입장 jsp 작성
junshock5 added a commit that referenced this issue Aug 25, 2020
- messageType이 BinaryMessage인 데이터 디렉터리에 저장 및 발송
- chat.jsp에 웹소켓을 통해 fileSend함수 생성
junshock5 added a commit that referenced this issue Aug 27, 2020
- RequestMapping 으로 되어있던 api를 http method에 맞게 변경
- api에 맞는 uri 패턴으로 변경
- uri 패턴 변경에 따른 room.jsp 변경
- SoketHandler.java 파일에 필요없는 변수 삭제 및 Thread-Safe하기 위해 전역변수를 지역변수로 변경
junshock5 added a commit that referenced this issue Aug 28, 2020
- WebSocketConfig 클래스 관련 주석 추가
- ChattingController에 REST URI 규약 적용
- roomDTO builder 패턴을 이용한 생성되게 변경
- ChattingResponse, ChattingRequest 생성
- SocketHandler에 예외발생시 로그파일로 만들게 변경
- ChattingMapper, ChattingService, ChattingMapper 클래스 생성을통한
채팅방 등록 및 찾기 구현
- room.jsp 에 uri 패턴 적용에 따른 변경
junshock5 added a commit that referenced this issue Aug 31, 2020
- ChattingController에 chattingService 주입되게 변경
- roomDTOList를 DB에 저장한 데이터를 가져오게 변경
junshock5 added a commit that referenced this issue Aug 31, 2020
- application dev, release 버전 나누기
- Rooms정보 가져올시 order by 정보와 limit, offset 설정 파라미터 추가
- getLastRoomNumber 함수 추가
- ChattingController 쓰지않는 파라미터, 변수 제거
junshock5 added a commit that referenced this issue Sep 1, 2020
- 메소드명 명시적으로 변경 getRooms -> getAllRooms
- 채팅중 파일 다운로드 디렉토리를 상대적으로 변경, 파일명은 처리 시간으로 변경
- 예외처리시 e.printStackTrace(); 부분을 log.error파일에 기록
- @responsebody 메소드 위로 수정
- taskScheduler 메소드 주석 추가
junshock5 added a commit that referenced this issue Sep 1, 2020
- gitignore에 attachFile 폴더 추가
junshock5 added a commit that referenced this issue Sep 3, 2020
- Api 인자에 HashMap 형태를 DTO 타입으로 변경
- getLastRoomNumber 메소드에 NULL이 올수 있어서 예외처리, 반환 타입을 INT -> Interger로 변경
- spring배너 title 변경
junshock5 added a commit that referenced this issue Sep 3, 2020
- 무의미한 File 생성 제거
- System.getProperty("user.dir"), File.separator 를 이용한 프로젝트 상대경로 설정
- 첨부파일 경로 gitignore 추가
junshock5 added a commit that referenced this issue Sep 3, 2020
- DateUtil 생성
  yyyyMMddHHmm 형태 문자열 반환, 확인 메서드
- FileOutputStream, FileChannel 사용시 try-with-resource 적용
junshock5 added a commit that referenced this issue Sep 6, 2020
- 파일명 생성하는 DateFormat을 ThreadLocal을 사용하여 재사용하게 변경
- ChattingService에 채팅목록 검색시 Default설정 상수화
- SocketHandler에 파일 인덱스, 파일 디렉토리명 상수화, 예외처리 에러 추가
- ChattingController 필요없는 로컬변수, model 파라미터 제거
junshock5 added a commit that referenced this issue Sep 12, 2020
- System.out.println문 삭제
- Exception 문 삭제
- ThreadLocal문 변경
- 메인 어플리케이션 명 변경
junshock5 added a commit that referenced this issue Sep 15, 2020
- createRoom NPE 구문 추가
- createRoom convention 적용
- 로컬포트 삭제
- expire.products=5000 5초로 변경
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
working 작업중입니다.
Projects
None yet
Development

No branches or pull requests

1 participant