Ignore:
Timestamp:
Feb 11, 2010, 3:48:49 PM (12 years ago)
Author:
arnold
Message:

Completely redesigned Manager-JobAdmin-Worker-infrastructure to distribute Jobs with a Peer-to-Peer infrastructure to remote CT2-Workspaces.

To test this infrastructure, open 2 instances of CT and load P2P_Manager_NEW_DES.cte and in the other instance P2P_Worker_NEW.cte.
HINT: Working with remote peers isn't possible every time, because the so called "SuperNode", which is necessary for relaying, sometimes goes down. But testing this infrastructure on different computers in the same network should work every time.

Location:
trunk/CrypPlugins/PeerToPeerPublisher
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/CrypPlugins/PeerToPeerPublisher/P2PPublisher.cs

    r1129 r1137  
    189189            if (this.p2pPublisher != null && !this.p2pPublisher.Started)
    190190            {
    191                 this.p2pPublisher.Start(this.settings.TopicName, (long)this.settings.SendAliveMessageInterval);
     191                this.p2pPublisher.Start(this.settings.TopicName, (long)this.settings.SendAliveMessageInterval * 1000);
    192192            }
    193193
     
    196196                this.p2pPublisher = new P2PPublisherBase(this.P2PControl);
    197197                this.p2pPublisher.OnGuiMessage += new P2PPublisherBase.GuiMessage(p2pPublisher_OnGuiMessage);
    198                 this.p2pPublisher.Start(this.settings.TopicName, (long)this.settings.SendAliveMessageInterval);
     198                this.p2pPublisher.Start(this.settings.TopicName, (long)this.settings.SendAliveMessageInterval * 1000);
    199199            }
    200200        }
  • trunk/CrypPlugins/PeerToPeerPublisher/P2PPublisherBase.cs

    r1129 r1137  
    8383            /* BEGIN: CHECKING WHETHER THERE HAS ALREADY EXIST ANOTHER PUBLISHER */
    8484            this.topic = sTopic;
    85             this.aliveMessageInterval = aliveMessageInterval * 1000;
     85            this.aliveMessageInterval = aliveMessageInterval;
    8686            AssignManagement(this.aliveMessageInterval);
    8787
     
    230230                    {
    231231                        GuiLogging("ALREADY REGISTERED peer with ID " + sender, NotificationLevel.Info);
    232                         // only for testing reasons
    233                         this.p2pControl.SendToPeer(PubSubMessageType.RegisteringAccepted, sender);
    234232                    }
    235233                    break;
  • trunk/CrypPlugins/PeerToPeerPublisher/SubscribersManagement.cs

    r1107 r1137  
    5757        public virtual bool Add(PeerId subscriberId)
    5858        {
     59            bool retValue = false;
    5960            if (!this.checkList.ContainsKey(subscriberId))
    6061            {
     
    6465                {
    6566                    this.checkList.Add(subscriberId, this.dateTimeNow);
    66                 }
    67                 return true;
    68             }
    69             else
    70                 return false;
     67                    retValue = true;
     68                }
     69            }
     70            return retValue;
    7171
    7272        }
Note: See TracChangeset for help on using the changeset viewer.