There is a problem in maintaining the general condition of the data table "Test" in an ad p2p network using : WCF (NetPeerTcpBinding, NetTcpBinding, PNRP) and net Sync Framework (Custom DbSyncProvider). Each node has at least two endpoints NetPeerTcpBinding and NetTcpBinding. I understand the WCF NetPeerTcpBinding not allow to synchronize the table with all the sites in the sequence used class KnowledgeSyncProvider-BeginSession ... EndSession because message is sent to multiple nodes simultaneously. Correct me if I'm wrong, that's just my guess. If we develop this idea further , something that would synchronize the table "online" all nodes need one message transfer knowledge and data add, update or delete a row that would each node receiving the message , synchronized table itself without interacting with the sender of the message . Suppose node «A» appeared after some absence in the cloud - in this case it is synchronized in the usual way with which two Custom DbSyncProvider synchronized with each other, via a binding NetTcpBinding, with any of the sites found using PeerNameResolver in namespace System.Net. PeerToPeer, call this node «B», and the result of the synchronization node «B» NetPeerTcpBinding spreads through messaging .Is it possible to implement such a scheme , or not? Can someone solved a similar problem in any other way ?
not sure exactly what you're asking here. are you trying to sync all nodes at the same time? or are you trying to broadcast to all nodes? sync framework syncs two replicas at the most at a given sync session.
likewise, you're issue seems to be with your WCF config, not with Sync Framework.
The challenge is to synchronize all the nodes of the cloud. Table "Test" in the database provisioned pattern "Not sql server". We can only simultaneously syncronize two databases together BD1 (DbSyncProvider)-SyncOrchestrator-BD2 (DbSyncProvider). Suppose a user on one of the nodes in the table "Test" entry is added. Table changed , those changes somehow be extended to all other nodes. If we take as a basis for binding NetPeerTcpBinding then there can only be broadcast to all nodes , ie we can not synchronize because the database on different nodes together.
Then I see two variants :
1) to broadcast "DataRow" added row on each node clouds add this row to the table "Test". Only in this case the table metadata SyncKnowledge Scope_Info remains unchanged, and the synchronization of these tables will appear conflict LocalInsertRemoteInsert, which is undesirable.
2) broadcasts SyncKnowledge, data replicas and "DataRow" added row in a single message . Each node receiving this message simulates synchronization making the necessary changes to tables tracking and Scope_Info. Ie as it turns out unidirectional synchronization . Is that possible? I understand when a unidirectional synchronization from the " source provider " to " destination provider " no change in the tables tracking and Scope_Info « source provider " is not provided , the changes are only in the tables " of the destination ?"
After the appearance of the site «A» in the network must be bi-directional sync in the usual way with any of the nodes through NetTcpBinding ( node «B»). Those changes , which received node «B» we broadcast to all other nodes . I wonder whether it is possible to realize the variant of broadcasting №2 ? Example WCF configuration can be downloaded here http://uafile.com/file/34609/P2PChat-7z.html. It's a bit modified example of the chat and there are two variants. P2PChatV1 can only be run on different computers in the network because use one port. After entering the required some time that would have seen each other nodes. Pressing the send in the application resolver sends a different message to each node through NetTcpBinding.
- Edited by Andrey1307 Wednesday, January 22, 2014 8:53 AM