예제 #1
0
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        static void Main()
        {
            MsQueue <LogModel> msQueue = new MsQueue <LogModel>(AppSettings.GetValue("log_msqueue"));

            msQueue.CreateQueue();

            ServiceBase[] ServicesToRun;
            ServicesToRun = new ServiceBase[]
            {
                new Service1()
            };
            ServiceBase.Run(ServicesToRun);
        }
예제 #2
0
        protected void Application_Start()
        {
            AreaRegistration.RegisterAllAreas();
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);

            MsQueue <LogModel> logMsQueue = new MsQueue <LogModel>(AppSettings.GetValue("log_msqueue"));

            logMsQueue.CreateQueue();

            MsQueue <FileConvertModel> fileTaskMsQueue = new MsQueue <FileConvertModel>(AppSettings.GetValue("file_msqueue"));

            fileTaskMsQueue.CreateQueue();

            MsQueue <string> taskSchedulingMsqueue = new MsQueue <string>(AppSettings.GetValue("task_scheduling_msqueue"));

            taskSchedulingMsqueue.CreateQueue();
        }