From 340ef33e2e27b2f5e9b29c41617aec9c542be5f8 Mon Sep 17 00:00:00 2001 From: Sean Dague Date: Mon, 16 Jun 2008 19:22:00 +0000 Subject: fix nhibernate driver so that it starts (based on the appearance changes it wouldn't come up). include embedded dialect specific sql files for nhibernate migrations figure out how to get the raw db connection so that migrations can work with nhibernate. create initial migration for NHibernate + SQLite + Assets. --- OpenSim/Data/Migration.cs | 3 ++- OpenSim/Data/NHibernate/Resources/SQLiteDialect/001_AssetStore.sql | 2 +- OpenSim/Data/NHibernate/Resources/UserAppearance.hbm.xml | 4 ++-- 3 files changed, 5 insertions(+), 4 deletions(-) (limited to 'OpenSim/Data') diff --git a/OpenSim/Data/Migration.cs b/OpenSim/Data/Migration.cs index 30cd3b6..9447deb 100644 --- a/OpenSim/Data/Migration.cs +++ b/OpenSim/Data/Migration.cs @@ -227,10 +227,11 @@ namespace OpenSim.Data foreach (string s in names) { + m_log.InfoFormat("[MIGRATION] - testing resoure {0}", s); Match m = _match.Match(s); if (m.Success) { - // m_log.Info("MIGRATION: Match: " + m.Groups[1].ToString()); + m_log.Info("MIGRATION: Match: " + m.Groups[1].ToString()); int version = int.Parse(m.Groups[1].ToString()); if (version > after) { using (Stream resource = _assem.GetManifestResourceStream(s)) diff --git a/OpenSim/Data/NHibernate/Resources/SQLiteDialect/001_AssetStore.sql b/OpenSim/Data/NHibernate/Resources/SQLiteDialect/001_AssetStore.sql index e553cff..07994f4 100644 --- a/OpenSim/Data/NHibernate/Resources/SQLiteDialect/001_AssetStore.sql +++ b/OpenSim/Data/NHibernate/Resources/SQLiteDialect/001_AssetStore.sql @@ -8,7 +8,7 @@ create table Assets( Description varchar(64), Local boolean, Temporary boolean, - Data blob, + Data blob ); END; \ No newline at end of file diff --git a/OpenSim/Data/NHibernate/Resources/UserAppearance.hbm.xml b/OpenSim/Data/NHibernate/Resources/UserAppearance.hbm.xml index 85d888d..0070e06 100644 --- a/OpenSim/Data/NHibernate/Resources/UserAppearance.hbm.xml +++ b/OpenSim/Data/NHibernate/Resources/UserAppearance.hbm.xml @@ -1,7 +1,7 @@ - - + + -- cgit v1.1