Skip to content

Commit 12ad4ba

Browse files
authored
Refactor/101 room detail (#104)
* feat: cors 설정 * 웹소켓 * 웹소켓
1 parent b0bb3b1 commit 12ad4ba

File tree

2 files changed

+5
-6
lines changed

2 files changed

+5
-6
lines changed

src/main/java/com/oronaminc/join/websocket/config/WebSocketConfig.java

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@
99
import org.springframework.web.socket.config.annotation.WebSocketMessageBrokerConfigurer;
1010
import org.springframework.web.socket.config.annotation.WebSocketTransportRegistration;
1111
import org.springframework.web.socket.handler.WebSocketHandlerDecoratorFactory;
12-
import org.springframework.web.socket.server.support.HttpSessionHandshakeInterceptor;
1312

1413
import com.oronaminc.join.websocket.handshake.CustomHandshakeHandler;
1514
import com.oronaminc.join.websocket.session.CustomWebSocketHandlerDecorator;
@@ -48,15 +47,16 @@ public void registerStompEndpoints(StompEndpointRegistry registry) {
4847
registry.addEndpoint("/ws")
4948
.setAllowedOriginPatterns("*")
5049
// websocket 연결 전 쿠키 체크
51-
.addInterceptors(new HttpSessionHandshakeInterceptor())
50+
// .addInterceptors(new HttpSessionHandshakeInterceptor())
5251
// websocket 연결 후 principal 생성
53-
.setHandshakeHandler(handshakeHandler)
52+
// .setHandshakeHandler(handshakeHandler)
5453
.withSockJS();
5554

5655
registry.addEndpoint("/ws")
5756
.setAllowedOriginPatterns("*")
58-
.addInterceptors(new HttpSessionHandshakeInterceptor())
59-
.setHandshakeHandler(handshakeHandler);
57+
// .addInterceptors(new HttpSessionHandshakeInterceptor())
58+
// .setHandshakeHandler(handshakeHandler)
59+
;
6060

6161
registry.setErrorHandler(stompErrorHandler);
6262
}

src/main/java/com/oronaminc/join/websocket/session/CurrentParticipantEventHandler.java

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22

33
import static com.oronaminc.join.global.exception.ErrorCode.*;
44

5-
import com.oronaminc.join.global.exception.ErrorCode;
65
import java.security.Principal;
76
import java.util.Set;
87

0 commit comments

Comments
 (0)