mirror of
https://github.com/opensim/opensim.git
synced 2026-08-05 08:55:56 +08:00
*** BIG CHANGES : REGION STORAGE MOVED : UPDATE YOUR OpenSim.ini FROM OpenSim.ini.example **
* Now moved region storage from region to application, so we have one storage per application, instead of one per region. * Changed so that the region store providers use connectionstrings, not filenames * Removed various unfit fields and properties (call me Darwin)
This commit is contained in:
@@ -50,7 +50,7 @@ namespace OpenSim.DataStore.MonoSqlite
|
||||
private SqliteDataAdapter primDa;
|
||||
private SqliteDataAdapter shapeDa;
|
||||
private SqliteDataAdapter terrainDa;
|
||||
private String connectionString;
|
||||
private String m_connectionString;
|
||||
|
||||
/***********************************************************************
|
||||
*
|
||||
@@ -58,14 +58,14 @@ namespace OpenSim.DataStore.MonoSqlite
|
||||
*
|
||||
**********************************************************************/
|
||||
|
||||
public void Initialise(string dbfile, string dbname)
|
||||
public void Initialise(string connectionString)
|
||||
{
|
||||
connectionString = "URI=file:" + dbfile + ",version=3";
|
||||
m_connectionString = connectionString;
|
||||
|
||||
ds = new DataSet();
|
||||
|
||||
MainLog.Instance.Verbose("DATASTORE", "Sqlite - connecting: " + dbfile);
|
||||
SqliteConnection conn = new SqliteConnection(connectionString);
|
||||
MainLog.Instance.Verbose("DATASTORE", "Sqlite - connecting: " + connectionString);
|
||||
SqliteConnection conn = new SqliteConnection(m_connectionString);
|
||||
|
||||
SqliteCommand primSelectCmd = new SqliteCommand(primSelect, conn);
|
||||
primDa = new SqliteDataAdapter(primSelectCmd);
|
||||
@@ -266,7 +266,7 @@ namespace OpenSim.DataStore.MonoSqlite
|
||||
|
||||
// the following is an work around for .NET. The perf
|
||||
// issues associated with it aren't as bad as you think.
|
||||
SqliteConnection conn = new SqliteConnection(connectionString);
|
||||
SqliteConnection conn = new SqliteConnection(m_connectionString);
|
||||
conn.Open();
|
||||
MainLog.Instance.Verbose("DATASTORE", "Storing terrain revision r" + revision.ToString());
|
||||
String sql = "insert into terrain(RegionUUID, Revision, Heightfield)" +
|
||||
@@ -288,7 +288,7 @@ namespace OpenSim.DataStore.MonoSqlite
|
||||
terret.Initialize();
|
||||
// the following is an work around for .NET. The perf
|
||||
// issues associated with it aren't as bad as you think.
|
||||
SqliteConnection conn = new SqliteConnection(connectionString);
|
||||
SqliteConnection conn = new SqliteConnection(m_connectionString);
|
||||
conn.Open();
|
||||
String sql = "select RegionUUID, Revision, Heightfield from terrain" +
|
||||
" where RegionUUID=:RegionUUID order by Revision desc";
|
||||
|
||||
Reference in New Issue
Block a user