Windows Vista Forums
Vista Forums Home Join Vista Forums Donate Vista Tutorials Tags

Welcome to Vista Forums we are your forum to discuss Windows Vista x64 and x86 systems. Whether you need help or just want to post an idea you have on Vista, this is the forum for you.
Register at Vista forums...the world biggest Windows Vista resource Join Vista Forums Now

Go Back   Vista Forums > Microsoft Technical Newsgroups > Indigo

Hosting Multiple NetPeerTcpBinding Clients

 
 
Thread Tools Display Modes
Old 05-04-2006   #1 (permalink)
Michael Primeaux
Guest
 
Posts: n/a

Hosting Multiple NetPeerTcpBinding Clients

Hi,

Contextual Information
------------------------

I'm creating a Distributed Hash Table (DHT) implementation to be used in a
commercial application. Currently, I use the TcpClient and UdpClient classes
in my membership and routing layer. I've decided to modify the routing layer
to use WCF. Without going into much detail, the routing layer is implemented
as a class library so I can simulate many nodes in a single process. The
node class' ctor accepts a URL, which allows me to monotonically increment
the TCP port on each node (i.e. "net.tcp://localhost:5001/someUri",
"net.tcp://localhost:5002/someUri",..., "net.tcp://localhost:n/someUri"). I
use the URI in my EndpointAddress.

In addition to the net.tcp binding, I'd like each node joins P2P mesh
(duplex) to "listen" for join and leave events.

Scenario
--------------------------
To simplify the scenario assume I have a console application that creates 10
nodes. After creation of all nodes, each node issues a join request over the
net.p2p channel, which is a OneWay call per the service contract. Let's go
with the "join" request for now. Upon receipt of a join request, the
receiving node will issue a net.tcp request to the sender.

Questions
---------------------------

I have the following questions:

[1] Am I able to define the net.p2p endpoint mentioned above in my
app.config file such that all node instances (10 in the process) work as
expected or must I programmatically create the broadcast channel for each
node? Basically, *think* I want to simulate the Basic/Binding/Net/PeerTcp
WinFx sample except that instead of having two separate console applications
(one for each receiver) and another console application for the sender, I
want to have one console application where all nodes function as both sender
and receiver. Another option is to model each node as in the Chat example
(duplex channel).

[2] As related to the Basic/Binding/Net/PeerTcp example and the
/Scenario/PeerChannel/Chat sample, how do they differ in terms of WCF? It
seems the PeerTcp sample is a one way P2P mesh and the Chat sample is
two-way P2P mesh.

Kindest regards,
Michael


 
Old 05-05-2006   #2 (permalink)
Michael Primeaux
Guest
 
Posts: n/a

SOLVED: Hosting Multiple NetPeerTcpBinding Clients

Please disregard my below email. The answers to my below questions are:

[1] No. I ended up having to programmatically create the WCF
ServiceEndpoint.
[2] The Chat sample is a duplex channel and the PeerTcp sample is not.


"Michael Primeaux" <mjprimeaux@msn.com> wrote in message
news:us1vCL$bGHA.1856@TK2MSFTNGP03.phx.gbl...
> Hi,
>
> Contextual Information
> ------------------------
>
> I'm creating a Distributed Hash Table (DHT) implementation to be used in a
> commercial application. Currently, I use the TcpClient and UdpClient
> classes in my membership and routing layer. I've decided to modify the
> routing layer to use WCF. Without going into much detail, the routing
> layer is implemented as a class library so I can simulate many nodes in a
> single process. The node class' ctor accepts a URL, which allows me to
> monotonically increment the TCP port on each node (i.e.
> "net.tcp://localhost:5001/someUri",
> "net.tcp://localhost:5002/someUri",..., "net.tcp://localhost:n/someUri").
> I use the URI in my EndpointAddress.
>
> In addition to the net.tcp binding, I'd like each node joins P2P mesh
> (duplex) to "listen" for join and leave events.
>
> Scenario
> --------------------------
> To simplify the scenario assume I have a console application that creates
> 10 nodes. After creation of all nodes, each node issues a join request
> over the net.p2p channel, which is a OneWay call per the service contract.
> Let's go with the "join" request for now. Upon receipt of a join request,
> the receiving node will issue a net.tcp request to the sender.
>
> Questions
> ---------------------------
>
> I have the following questions:
>
> [1] Am I able to define the net.p2p endpoint mentioned above in my
> app.config file such that all node instances (10 in the process) work as
> expected or must I programmatically create the broadcast channel for each
> node? Basically, *think* I want to simulate the Basic/Binding/Net/PeerTcp
> WinFx sample except that instead of having two separate console
> applications (one for each receiver) and another console application for
> the sender, I want to have one console application where all nodes
> function as both sender and receiver. Another option is to model each node
> as in the Chat example (duplex channel).
>
> [2] As related to the Basic/Binding/Net/PeerTcp example and the
> /Scenario/PeerChannel/Chat sample, how do they differ in terms of WCF? It
> seems the PeerTcp sample is a one way P2P mesh and the Chat sample is
> two-way P2P mesh.
>
> Kindest regards,
> Michael
>



 
 
 

Thread Tools
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
bug in the PS hosting API... graycats PowerShell 4 06-16-2008 10:57 AM
Need Hosting? - Best selling hosting providers listed here HostingFreakzz@gmail.com Avalon 0 08-17-2006 01:04 PM








Vistax64.com is an independent web site and has not been authorized,
sponsored, or otherwise approved by Microsoft Corporation.
"Windows Vista", the Start Orb, and related materials are trademarks of Microsoft Corp.
© Designer Media 2005-2008

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49