Esempio n. 1
0
        private void StartServer()
        {
            ReplicationService service = new ReplicationService(new Dictionary <string, IReplicator> {
                { "s1", serverReplicator }
            });

            server = NewHttpServer <ReplicationServlet>(service);
            port   = ServerPort(server);
            host   = ServerHost(server);
        }
Esempio n. 2
0
        private void StartServer()
        {
            ReplicationService service = new ReplicationService(new Dictionary <string, IReplicator> {
                { "s1", serverReplicator }
            });

#if FEATURE_ASPNETCORE_ENDPOINT_CONFIG
            server = NewHttpServer(service, mockErrorConfig);                      // Call like this to use ReplicationServerMiddleware on the specific path /replicate/{shard?}/{action?}, but allow other paths to be served
#else
            server = NewHttpServer <ReplicationServlet>(service, mockErrorConfig); // Call like this to use ReplicationServlet as a Startup Class
#endif

            port = ServerPort(server);
            host = ServerHost(server);
        }