public override async Task RunAsync(string[] args) { await using Ice.Communicator communicator = Initialize(ref args); if (args.Length < 1) { throw new ArgumentException("Usage: server testdir"); } communicator.SetProperty("TestAdapter.Endpoints", GetTestEndpoint(0, "tcp")); Ice.ObjectAdapter adapter = communicator.CreateObjectAdapter("TestAdapter"); adapter.Add("factory", new ServerFactory(args[0] + "/../certs")); await adapter.ActivateAsync(); await communicator.WaitForShutdownAsync(); }
public override async Task RunAsync(string[] args) { if (args.Length < 1) { throw new ArgumentException("Usage: server testdir"); } await Communicator.ActivateAsync(); Communicator.SetProperty("TestAdapter.Endpoints", GetTestEndpoint(0, "tcp")); Communicator.SetProperty("TestAdapter.AcceptNonSecure", "Always"); Ice.ObjectAdapter adapter = Communicator.CreateObjectAdapter("TestAdapter"); adapter.Add("factory", new ServerFactory(args[0] + "/../certs")); await adapter.ActivateAsync(); ServerReady(); await Communicator.ShutdownComplete; }