fanliang11 / surging

Surging is a micro-service engine that provides a lightweight, high-performance, modular RPC request pipeline. support Event-based Asynchronous Pattern and reactive programming ,The service engine supports http, TCP, WS,Grpc, Thrift,Mqtt, UDP, and DNS protocols. It uses ZooKeeper and Consul as a registry, and integrates it. Hash, random, polling, Fair Polling as a load balancing algorithm, built-in service governance to ensure reliable RPC communication, the engine contains Diagnostic, link tracking for protocol and middleware calls, and integration SkyWalking Distributed APM
MIT License
3.24k stars 922 forks source link

建议Surging.Core.ServiceHosting ServiceHostBuilder.cs构造器加ContainerBuilder #111

Open victor596 opened 6 years ago

victor596 commented 6 years ago

RT. public ServiceHostBuilder(ContainerBuilder builder=null) { _builder = builder; _configureServicesDelegates = new List<Action>(); _registerServicesDelegates = new List<Action>(); _configureDelegates = new List<Action>(); _mapServicesDelegates = new List<Action>(); } 这样方便Surging的Autofac其它程序集的Autofac更好的整合

fanliang11 commented 6 years ago

有三种方式可以注入 1.ServiceHostBuilder 的RegisterServices 方法 2.Startup类中的ConfigureServices方法 3.继承SystemModule 具体可以参照这个文档说明https://github.com/dotnetcore/surging/blob/master/docs/docs.en/DependencyInjection.md