Hi So i am trying to run the socket.io-java-client from Gottox and simple by just opening the project in eclips(import) AND running BasicExample.java i am getting this error
Error while handshaking Server returned HTTP response code: 400 for URL: http://localhost:3000/socket.io/1/
I tried many solution but was not able to run it, also i am running the nodejs server on port 3000.
var app = require('express')();
var http = require('http').Server(app);
var io = require('socket.io')(http);
app.get('/', function(req, res){
res.sendfile('index.html');
});
io.on('connection', function(socket){
console.log('a user connected');
socket.on('message', function(msg){
io.emit('message', msg);
console.log('1111111111111111111');
});
});
http.listen(3000, function(){
console.log('listening on *:3000');
});