Thread: Packet routing
View Single Post
  #1 (permalink)  
Old July 3rd, 2002
Cakkie Cakkie is offline
Disciple
 
Join Date: May 26th, 2002
Posts: 13
Cakkie is flying high
Default Packet routing

I ahve a few questions about routing packets. If I send a PING or QUERY, I assign a GUID to my packet, I store the packet so that I can look it up when I receive a PONG or QUERYHIT. No problem here, since I created the GUID, and I started the packet.

However, what should I do if I receive a packet, and need to forward it. A PING or QUERY I forward to each connection (except the originating), but what about PONG and QUERYHIT, to which socket must I send this? I can imagine I have to keep track of this too, but I don't really have a clue on how to do this. I could just send it to each connection, but that would create a large "polution", wouldn't it?

I was also told that each packet must have a unique ID, and if you come across the same ID twice, the second packet should be dropped from the network, since you already procedded it. But what happens when someone does a QUERYHIT, using the GUID from the QUERY, that would result in the packet beeing removed from the network almost immediatly.
Reply With Quote