private void RegisterToTcAdmin()
        {
            CheckSettings();

            var settings =
                new TCAdminSettings(true, _moduleConfig.DebugTcAdmin, _moduleConfig.DebugTcAdminSql);
            var config = new TCAdminClientConfiguration(_moduleConfig.SqlString,
                                                        _moduleConfig.SqlEncrypted, "TCAdminModule", settings);
            var client = new TcAdminClient(config);

            client.SetAppSettings();
        }
Example #2
0
        public static void RegisterToTcAdmin()
        {
            var config = TcAdminConfiguration.GetConfiguration();
            var tcAdminClientConfiguration =
                new TCAdminClientConfiguration(config.ConnectionString, config.Encrypted, "TCAdminCrons", new TCAdminSettings(false));

            _ = new TcAdminClient(tcAdminClientConfiguration);
            try
            {
                new Server(1).Find();
                Log.Information("Registered to TCAdmin successfully.");
            }
            catch (Exception e)
            {
                Log.Error(e, e.Message);
            }
        }