Skip to main content

Resolver vs Pipes?

3 replies [Last post]
davjoh
Offline
Joined: 2007-07-18

OK, I'm revisting JXTA after a long time... so this is probably a dumb question...

The Resolver service provides a query/response to a peer or group kind of messaging in JXTA
The Pipe service provides unicast/multicast (to a peer or group) kind of messaging in JXTA

Neither guarantees reliability. So does one service have any advantage over the other? Surely with Pipes we can implement query/response style on top of pipes (2 pipes or BiDiPipes), but how is that any better than just using the Resolver anyway?

Reply viewing options

Select your preferred way to display the comments and click "Save settings" to activate your changes.
adamman71
Offline
Joined: 2007-01-31

Welcome back. No dumb questions.

Answer: It depends where your priority is and what you want to do. Queries are about obtaining answers, but you can twist them into sending info too. Pipe is about transferring data, but you can twist them into a query system. But, in that case, it would require less work to use the resolver system for the same result.

Bidis are about making sure msg reach target. With the resolver, if you don't get answer after some time, you should start wondering whether the target peer is still up or whether it received the query at all...

davjoh
Offline
Joined: 2007-07-18

Thanks for your answer!

I guess with pipes, a logical connection is created which makes it easier to transfer multiple messages between peers in one 'connection', whilst with the resolver it's a kind of connectionless messaging paradigm. Is there a limit on sizes of resolver messages? Or is it like pipes with a soft MTU of approx. 64kb (I'm sure I read that limit somewhere)?

adamman71
Offline
Joined: 2007-01-31

There is no real limit but the underlying transport level MTU, which changes from devices to devices, and network to network. If you message is too big, it is chunked by the TCP/IP stack and recomposed on the other end.

MTU was implemented in core code for fairness, but it incomplete business (see https://jxta-jxse.dev.java.net/issues/show_bug.cgi?id=306)