static void Main(string[] args) { var components = new List <IAppServerComponent>(); var webQueryManagerAppServiceHost = new AppServiceHostServerComponent <WebQueryManagerAppService, AuthenticateUserAppOperationHandler>(); //var webQueryManagerAppServiceGetTree = new AppServiceHostServerComponent<WebQueryManagerAppService, GetQueryTreeAppOperationHandler>(); var webQueryHost = new WcfServiceHostServerComponent <IWebQueryManager, WebQueryManagerService>(); components.Add(webQueryManagerAppServiceHost); components.Add(webQueryHost); using (var serverHost = AppServerHost.Create("WebQueryAppServer", components)) { try { serverHost.Start(); } catch (Exception e) { Console.WriteLine("Exception: " + e.Message); } Console.WriteLine("Press enter to stop the server host"); Console.ReadKey(); serverHost.Stop(); } Console.WriteLine("Press enter for exit"); Console.ReadKey(); }
static void Main(string[] args) { var components = new List <IAppServerComponent>(); var sdrnsControllerAppServiceHost = new AppServiceHostServerComponent <SdrnsControllerAppService, GetMeasTaskAppOperationHandler>(); var sdrnsControllerWcfServiceHost = new WcfServiceHostServerComponent <ISdrnsController, SdrnsControllerService>(); var coreServicesComponent = new CoreServicesServerComponent(); var dataLayerComponent = new DataLayerCoreServicesServerComponent(); var msSqlComponent = new MsSqlDataLayerCoreServicesServerComponent(); //var oracleComponent = new OracleLayerCoreServicesServerComponent(); var sdrnsRunServiceComponent = new RunServiceComponent(); components.Add(sdrnsControllerAppServiceHost); components.Add(sdrnsControllerWcfServiceHost); components.Add(coreServicesComponent); components.Add(dataLayerComponent); components.Add(msSqlComponent); ///components.Add(oracleComponent); components.Add(sdrnsRunServiceComponent); using (var serverHost = AppServerHost.Create("WebQueryAppServer", components)) { try { serverHost.Start(); } catch (Exception e) { Console.WriteLine("Exception: " + e.Message); } Console.WriteLine("Press enter to stop the server host"); Console.ReadKey(); serverHost.Stop(); } Console.WriteLine("Press enter for exit"); Console.ReadKey(); }