Skip to main content
  1. For the sake of clarity, I decided to go with the public call to getConfig().

  2. The config object's responsibility is to get and store data from the db. Therefore, it would be better to have a separate class do the work of bootstrapping the config tables. My code now looks something like:

    protected override void OnStart(string[] args) { ConfigBootstrapper.GetConfigTablesReady(); ConfigSingleton.GetInstance.getConfig();

     Poller = new Poller();
     Poller.Start();
    
     Logger.Warn("service started.");
    

    }

Joseph
  • 393
  • 4
  • 7