Ejemplo n.º 1
0
        // Debugging Commands


        // Crash server_id
        public void CrashSync(string fields)
        {
            // match right PCS
            string basePcsUrl          = BaseUrlExtractor.Extract(ServerIdsToUrls[fields]);
            ProcessCreationService pcs = PCSs[basePcsUrl];

            pcs.Crash(fields);
        }
Ejemplo n.º 2
0
        public void StartProcess(string url, string fields, string exePath, string id)
        {
            // match right PCS
            string basePcsUrl          = BaseUrlExtractor.Extract(url);
            ProcessCreationService pcs = PCSs[basePcsUrl];

            pcs.Start(@exePath, fields, id);
        }
Ejemplo n.º 3
0
        private static void Main(string[] args)
        {
            var server = new Server {
                Services = { ProcessCreationService.BindService(_serverService) },
                Ports    = { new ServerPort("localhost", Port, ServerCredentials.Insecure) }
            };

            server.Start();
            Console.WriteLine("Process Creation Server listening on port " + Port);
            ReadCommands();

            server.ShutdownAsync().Wait();
        }
Ejemplo n.º 4
0
        public Pcs()
        {
            infos = new List <ProcessStartInfo>();
            //--------------------------------PM Interface creation-----------------------------------//
            remotePCS = new ProcessCreationService();
            channel   = new TcpChannel(10001);

            ChannelServices.RegisterChannel(channel, false);
            RemotingServices.Marshal(remotePCS, "remotePCS",
                                     typeof(ProcessCreationService));

            //---------------------------------------------------------------------------------------//

            operatorProcesses          = new List <Process>();
            remotePCS.createOperators += new DelCreateOperator(ProcessCreator);
        }