Ejemplo n.º 1
0
        static void Main(string[] args)
        {
            ServerSettings     registrySettings  = ServerSettings.LoadSettings();
            RegistryHttpServer registryServer    = new RegistryHttpServer(registrySettings);
            FileBasedRegistry  fileBasedRegistry = new FileBasedRegistry();

            fileBasedRegistry.StartDiscovery();
            registryServer.SetRegistryProvider(fileBasedRegistry);
            registryServer.Run();
        }
Ejemplo n.º 2
0
        private static void LoadRegistry()
        {
            ServerSettings registrySettings = ServerSettings.CreateSettings();

            registrySettings.ServerConfig.Hosting = new HostingConfiguration()
            {
                Urls = new List <string>()
                {
                    "http://localhost:4999"
                }
            };

            RegistryHttpServer registryServer    = new RegistryHttpServer(registrySettings);
            FileBasedRegistry  fileBasedRegistry = new FileBasedRegistry();

            registryServer.SetRegistryProvider(fileBasedRegistry);
            registryServer.RunAsync();
        }