Reload this Page

Modules that allow Ultrapeers to forward query responses


Reply
Thread Tools
Search this Thread
Display Modes
  #1  
Old March 31st, 2007, 10:31 PM
G0NZ0's Avatar
G0NZ0 G0NZ0 is offline
Tropical Storm
 
Join Date: Feb 2007
Location: San Diego CA
Posts: 5
Default Modules that allow Ultrapeers to forward query responses

For research purposes, I would need to locate which modules allow Ultrapeers to forward the query responses. The goal of the research would be to implement filters on ultrapeers that allow for instance filters on the basis of extension + size (example, if the query results is a mp3 file less than 500 KB, then drop the query that you are propagating).
I tried modifying the file /core/com/limegroup/gnutella/Response.java but it is not the correct one (guess it is just the response regarding files that come from that specific peer, not responses that are routed back).

Does anyone have any idea about which file i should modify?
Thanks a bunch in advance for any suggestion!
Reply With Quote
  #2  
Old March 31st, 2007, 11:33 PM
Sam's Avatar
Sam Sam is offline
software developer
 
Join Date: Mar 2006
Location: new york
Posts: 1,613
Default

Response is just a container of data, it doesn't do any actual logic.

The code you're looking for is likely in MessageRouter.handleQueryReply. The line that says, "rh.handleQueryReply(queryReply, handler);" is the actual handling of the reply. Depending on what is implementing the ReplyHandler, it may show the reply in the GUI, forward it along a ManagedConnection, send it over UDP, or a variety of other things.

Be aware that not all query replies travel through the network. Many queries are marked as wanting OOB results, and the replier will reply directly to the querier using UDP. Also note that even when the query is in going through the network, the existing logic tries very hard to avoid parsing the reply itself (because parsing all replies passing through an Ultrapeer would be very expensive CPU-wise), so adding this burden may have some unexpected results.
Reply With Quote
  #3  
Old April 1st, 2007, 12:53 AM
G0NZ0's Avatar
G0NZ0 G0NZ0 is offline
Tropical Storm
 
Join Date: Feb 2007
Location: San Diego CA
Posts: 5
Default

I understand.
Thank you so much for your prompt and exhaustive reply, it's been really helpful to me.
__________________
~~~ There are 10 types of people, those who understand binary, and those who don't. ~~~
Reply With Quote
Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
Forum Jump


All times are GMT. The time now is 02:29 PM.


Powered by vBulletin® Version 3.7.1
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.