Пример #1
0
        public IActionResult RunJobs()
        {
            Task.Factory.StartNew(() =>
            {
                try
                {
                    DoubanHouseCrawler.AnalyzeDoubanHouseContent();

                    //Job要执行的逻辑代码
                    PinPaiGongYuHouseCrawler.CapturPinPaiHouseInfo();

                    PeopleRentingCrawler.CapturHouseInfo();

                    DoubanHouseCrawler.CaptureHouseInfoFromConfig();

                    HouseSourceInfo.RefreshHouseSourceInfo();
                }
                catch (Exception ex)
                {
                    LogHelper.Error("RunJobs", ex);
                }
            });

            return(View());
        }
Пример #2
0
        public IActionResult RunJobs()
        {
            DoubanHouseCrawler.CaptureHouseInfoFromConfig();
            PinPaiGongYuHouseCrawler.CapturPinPaiHouseInfo();
            HouseSourceInfo.RefreshHouseSourceInfo();
            PeopleRentingCrawler.CapturHouseInfo();

            //Task.Factory.StartNew(() =>
            //{
            //    try
            //    {

            //        PeopleRentingCrawler.CapturHouseInfo();
            //        DoubanHouseCrawler.CaptureHouseInfoFromConfig();
            //        DoubanHouseCrawler.AnalyzeDoubanHouseContentAll();
            //        HouseSourceInfo.RefreshHouseSourceInfo();
            //    }
            //    catch (Exception ex)
            //    {
            //        LogHelper.Error("RunJobs", ex);
            //    }

            //});

            return(View());
        }