예제 #1
0
        public void Initialise(string connectionString)
        {
            m_connectionString = connectionString;
            m_log.DebugFormat("[UserLogModule]: Mssql - connecting: {0}", m_connectionString);

            try
            {
                m_database = new MSSQLManager(connectionString);
                using (SqlConnection conn = new SqlConnection(connectionString))
                {
                    conn.Open();
                    Migration m = new Migration(conn, Assembly, "mssql");
                    m.Update();
                }
            }
            catch (Exception ex)
            {
                m_log.ErrorFormat("[UserLogModule]: Initial mssql exception for URI '{0}', Exception: {1}", m_connectionString, ex.Message);
                Environment.Exit(-1);
            }
        }