Hey I am writing an app in Twisted, and as it stands I have 4 servers bound two different ports all communicating with the client via JSON. Is there anyway to bind these 4 servers to the same port and have the interactions remain the same?
For instance say the client subscribes to two different feeds, transmitted via a direct socket.
R...
I'm using Scala's remote actors, but round-trip time (even of a trivial message) is 80ms, presumably due to underlying socket not having the TCP/IP Nagle algorithm disabled (also known as TCP_NODELAY), or at least that's what someone with some experience with Java RMI informs me.
All I'm doing in the client to get a link to the remote a...
Hi all,
My app makes an outbound connection to a server using a specific source port (in anticipation of firewall problems - a hardened system will probably require ports to be specified ahead of time).
My problem is that my app makes the connection initially. However, if the connection ever breaks it will try again but the socket wil...
I have a SocketServer accepting incoming connections. For security reasons I should only allow local connections (connections from the machine on which server is running).
How can I determine if an incoming connection is from another machine? Is the following code safe for this?
Socket socket = someServerSocket.accept();
String remoteA...
Please tell mw how to convert a TCP IP socket into NON Blocking socket. I am aware of the fcntl() function but I heard that they are not always reliable.
...
Does someone know of a good .Net socket sniffer?
I'm trying to build an IM sniffer that can show the Unicode chars correctly.
TY
...
Yahoo has multiple rooms for a game. For example, let's choose Chess. For Chess, they have multiple rooms, and every rooms has multiple tables.
What would be the reason to have multiple rooms ?
Will the server be slower with 1 room and 10.000 tables than 10 rooms and 1000 tables for each room ?
If yes, please make me understand why. I ...
Hello
I'm reading from a Socket's InputStream. Because I'm parsing the incoming data on the fly, I'm required to read character by character.
Does BufferedReader.read() the same thing as InputStream.read() does ? (assuming that BufferedReader has been constructed with the InputStream as base)
Is it more efficient to use InputStream.re...
I am developing an application in android to connect emulator to server and then read, edit and write on it. Has any one worked on such application please let me know. Else guide how to develop this application.
I am using Socket in my application. i am able to run the code when my machine is server and client but not able to do when c...
hiho,
i intend to develop just a litte network application, something like a chat. so i downloaded xampp for windows and installed it (also as service), mysql included. well, i started the apache (and mysql) as service and just wrote the short line in java:
try {
Socket sock = new Socket("127.0.0.1", 21);
System.out.println...
We are designing a p2p applications using c++ which transmits voice to other peer using UDP.
We are capturing a mic signal in a buffer in the thread which captures voice for one second in the while loop. For every second voice captured in buffer it splits it into packets and sends to the other peer. Now I need a proper data structure a...
Hello All,
I have implemented the client server using socket programming in C on Unix OS. I have used the non blocking socket at client end. I want to implement the two way communication. But its working only with one way i.e. Client can read and write the data on server, but server can not read or write data on client.
Client
nread =...
I try to communicate via TCP Socket between a QT4-Application (MyApp) and Cayuga (written in C++).
The connection part works fine, i.e. Cayuga connects to MyApp.
Now, MyApp is sending some data to Cayuga, but nothing is received.
void MyApp::init()
QTcpServer *m_server;
QTcpSocket *clientConnection;
//Open socket for transmission
m...
Hi to all,
I have write a game on OpenGl, and want to make it a multiplayer game.
I'm working on Windows, but I'm actually a C#-programmer. Socket programming goes
too easy at C#, but at c++ I can not solve it :(
Which library should I use? winsock and winsock2 libraries are too complicated.
Is there any library easy to use like in C#...
Hi,
My code looks like this, this is Server code (Runnable)
public void run() {
while (true) {
try {
System.out.println("Waiting for client...");
this.socket = serverSocket.accept();
System.out.println("Client accepted");
while (true) {
readCommand();
...
Does anyone know why should I use Winpcap and not just .Net sockets to sniff packets on my local pc?
TY
...
I'm using Perl sockets in AIX 5.3, Perl version 5.8.2
I have a server written in Perl sockets. There is a option called "Blocking", which can be set to 0 or 1. When I use Blocking => 0 and run the server and client send data (5000 bytes), I am able to recieve only 2902 bytes in one call. When I use Blocking => 1, I am able to recieve al...
I've a non-blocking socket currently subscribed to:
ev.events = EPOLLIN | EPOLLPRI | EPOLLERR | EPOLLHUP | EPOLLRDHUP| EPOLLET;
It receives a couple of EPOLLINs which I read non-blocking till EAGAIN and then I receive HUP & RDHUP, sometimes with a few bytes more to read.
The other side is just:
send(socket,960_bytes_buffer)
close(s...
Hi there,
A SocketException error is thrown when a client disconnects through Read/Write/Accept operations.
When a SocketException is thrown I would love to have details about that 'Client' socket --
namely the Socket.RemoteEndPoint
Any way of getting this from the SocketException object?
I am particulary interested in obtaining req...
I'm trying to figure out a protocol to use with domain sockets and can't find information on how blindly the domain sockets can be trusted.
Can data be lost? Are messages always received in the same order as sent? Even when using datagram sockets?
Are transfers atomic? When reading the socket, can I trust that I get the whole message o...