예제 #1
0
        static void Main( string[] args )
        {
            Console.WriteLine( "Agent control host started." );
            Console.WriteLine();

            ThreadPool.SetMinThreads( 1000, 1000 );
            ThreadPool.SetMaxThreads( 15000, 15000 );

            AgentsControl agents = new AgentsControl();
            callbackHost = new CallbackHost { Agents = agents };
            cancelSource = new CancellationTokenSource();
            ResetClient();
            StartTask();

            Console.ReadLine();
            agents.SetConnectionsCount( 0, true );
            client.Close();
            Console.WriteLine( "Bye." );
        }
예제 #2
0
        static void Main(string[] args)
        {
            Console.WriteLine("Agent control host started.");
            Console.WriteLine();

            ThreadPool.SetMinThreads(1000, 1000);
            ThreadPool.SetMaxThreads(15000, 15000);

            AgentsControl agents = new AgentsControl();

            callbackHost = new CallbackHost {
                Agents = agents
            };
            cancelSource = new CancellationTokenSource();
            ResetClient();
            StartTask();

            Console.ReadLine();
            agents.SetConnectionsCount(0, true);
            client.Close();
            Console.WriteLine("Bye.");
        }