Example #1
0
        static void Main(string[] args)
        {
            //ServicePointManager.DefaultConnectionLimit = 100;
            //var config = new RabbitMissionConfig("amqp://127.0.0.1",serializerType:SerializerType.MessagePack);
            var server = MissionFactory.CreateServer().UseRabbit("rabbit", new Logger());

            Container.Server = server;
            //ServicePointManager.DefaultConnectionLimit = 10;
            using (WebApp.Start <Startup>(url: "http://127.0.0.1:9008/"))
            {
                Console.WriteLine("host:{0}", "http://localhost:9008/");
                Console.WriteLine("Press [enter] to quit...");
                Console.ReadLine();
                server.Dispose();
            }
        }