EndRequest事件处理的作用是处理完"处理引擎(ProcessingEngine)"中的任务(Task)。

        void IOrchardHost .EndRequest() {
            Logger.Debug( "EndRequest");
            EndRequest();
        }
  
         protected virtual void EndRequest() {
            // Synchronously process all pending tasks. It's safe to do this at this point
            // of the pipeline, as the request transaction has been closed, so creating a new
            // environment and transaction for these tasks will behave as expected.)
            while (_processingEngine.AreTasksPending()) {
                _processingEngine.ExecuteNextTask();
            }
        }
"操作引擎(Processing Engine)" 是一个任务容器,EndRequest中对添加到容器内的任务进行同步处理。关于"操作引擎"我们在适当的时候来分析。
 
相关类型:
Orchard.Environment.State.DefaultProcessingEngine: IProcessingEngine
Orchard.Environment.State.ShellStateCoordinator : IShellStateManagerEventHandler, IShellDescriptorManagerEventHandler
Orchard.Warmup.Services.WarmupScheduler : IWarmupScheduler, IWarmupEventHandler
Orchard.Recipes.Services.RecipeScheduler : IRecipeScheduler, IRecipeSchedulerEventHandler
Orchard.Indexing.Services.UpdateIndexScheduler : IUpdateIndexScheduler, IIndexNotifierHandler


相关文章:

  • 2021-07-31
  • 2023-02-14
  • 2021-07-02
  • 2021-08-25
  • 2021-06-05
  • 2021-08-28
  • 2021-09-05
猜你喜欢
  • 2022-01-16
  • 2021-08-28
  • 2022-01-07
  • 2022-02-19
相关资源
相似解决方案