title: WebSocket handshake: Unexpected response code: 404 -
body: <p>I am learning about websockets and followed the instructions here: <a href="http://www.oracle.com/webfolder/technetwork/tutorials/obe/java/HomeWebsocket/WebsocketHome.html" rel="nofollow">http://www.oracle.com/webfolder/technetwork/tutorials/obe/java/HomeWebsocket/WebsocketHome.html</a></p>
  
  <p>I' using tomcat v8.0.21 to deploy my webapp but get the following error</p>
  
  <p>My JavaScript Project looks fine, when I visit the webapp: my localhost and visit WebSocketJavaScriptProject</p>
  
  <p>Although in the console window get the error: WebSocket connection to 'ws://localhost:8080/WebsocketHome/actions' failed: Error during WebSocket handshake: Unexpected response code: 404</p>
  
  <p>My code lives here: <a href="https://github.com/darkcloudi/WebSocketProject" rel="nofollow">https://github.com/darkcloudi/WebSocketProject</a></p>
  
  <p>Difference between my app and the example on Oracle is I have split it as two projects one service and the other webapp. </p>
  
  <p>I cannot figure out why I would be getting a 404 as the service .war file is called WebsocketHome. Any ideas what would be causing this issue? Usually a 404 is not found so guessing it cannot finding the service , i'm sure i'm doing something stupid but cannot figure out where the problem is</p>
  
  <p>Thanks</p>