<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
       xmlns:websocket="http://www.springframework.org/schema/websocket"
       xsi:schemaLocation="http://www.springframework.org/schema/beans
       http://www.springframework.org/schema/beans/spring-beans-4.0.xsd
       http://www.springframework.org/schema/websocket
       http://www.springframework.org/schema/websocket/spring-websocket-4.0.xsd">

    <bean id="agWebsocket" class="com.ag.web.websocket.AgWebSocketHander" />
        <websocket:handlers>
            <websocket:mapping path="/echo" handler="agWebsocket" />
            <websocket:handshake-interceptors>
                <bean class="com.ag.web.websocket.AgHandshakeInterceptor" />
            </websocket:handshake-interceptors>
        </websocket:handlers>
</beans>