/// <summary> /// 配置请求管道 /// </summary> public void Configure(IApplicationBuilder app, ILoggerFactory loggerFactory) { loggerFactory.AddBucketLog(app, "Bucket.Ocelot"); app.UseCors("CorsPolicy"); //app.UseMetricsAllMiddleware(); //app.UseMetricsAllEndpoints(); app.UseOcelot().Wait(); }
/// <summary> /// 配置请求管道 /// </summary> public void Configure(IApplicationBuilder app, ILoggerFactory loggerFactory) { loggerFactory.AddBucketLog(app, "Pinzhi.Config"); // 文档 ConfigSwagger(app); // 公共配置 CommonConfig(app); }
/// <summary> /// 配置请求管道 /// </summary> public void Configure(IApplicationBuilder app, ILoggerFactory loggerFactory) { // 日志 loggerFactory.AddBucketLog(app, "Bucket.MVC"); // 文档 ConfigSwagger(app); // 公共配置 CommonConfig(app); }
/// <summary> /// 配置请求管道 /// </summary> /// <param name="app"></param> /// <param name="env"></param> /// <param name="loggerFactory"></param> public void Configure(IApplicationBuilder app, ILoggerFactory loggerFactory) { // 日志,事件驱动日志 loggerFactory.AddBucketLog(app, "Pinzhi.Identity"); // 文档 ConfigSwagger(app); // 公共配置 CommonConfig(app); }
/// <summary> /// 配置请求管道 /// </summary> public void Configure(IApplicationBuilder app, ILoggerFactory loggerFactory) { // 日志 loggerFactory.AddBucketLog(app, "Pinzhi.Platform.WebApi"); // 文档 ConfigSwagger(app); // 公共配置 CommonConfig(app); }
/// <summary> /// <summary> /// 配置请求管道 /// </summary> /// <param name="app"></param> /// <param name="env"></param> /// <param name="loggerFactory"></param> /// <param name="appLifetime"></param> public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory, IApplicationLifetime appLifetime) { // 日志,事件驱动日志 loggerFactory.AddBucketLog(app, Configuration.GetValue <string>("Project:Name")); // 文档 ConfigSwagger(app); // 公共配置 CommonConfig(app); // Autofac容器释放 appLifetime.ApplicationStopped.Register(() => { AutofacContainer.Dispose(); }); }
/// <summary> /// 配置请求管道 /// </summary> /// <param name="app"></param> /// <param name="env"></param> /// <param name="loggerFactory"></param> /// <param name="appLifetime"></param> public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory, IApplicationLifetime appLifetime) { // 日志,事件驱动日志 loggerFactory.AddBucketLog(app, Configuration.GetValue <string>("Project:Name")); // 事件订阅 ConfigureEventBus(app); // 默认启动 app.Run(async(context) => { await context.Response.WriteAsync("Hello World!"); }); }
/// <summary> /// 配置请求管道 /// </summary> /// <param name="app"></param> /// <param name="env"></param> /// <param name="loggerFactory"></param> public void Configure(IApplicationBuilder app, IHostingEnvironment env, ILoggerFactory loggerFactory) { // 日志,事件驱动日志 loggerFactory.AddBucketLog(app, Configuration.GetValue <string>("Project:Name")); // 文档 ConfigSwagger(app); // 公共配置 CommonConfig(app); // Use EventBus ConfigureEventBus(app); // 调度任务 ConfigureScheduler(app); }