Merge branch 'master' of melanie@opensimulator.org:/var/git/opensim

mysql-performance
Melanie 2009-11-26 17:05:48 +00:00
commit 41226dc991
6 changed files with 34 additions and 9 deletions

View File

@ -348,9 +348,17 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
UUID ospResolvedId = OspResolver.ResolveOspa(item.CreatorId, m_scene.CommsManager); UUID ospResolvedId = OspResolver.ResolveOspa(item.CreatorId, m_scene.CommsManager);
if (UUID.Zero != ospResolvedId) if (UUID.Zero != ospResolvedId)
{
item.CreatorIdAsUuid = ospResolvedId; item.CreatorIdAsUuid = ospResolvedId;
// XXX: For now, don't preserve the OSPA in the creator id (which actually gets persisted to the
// database). Instead, replace with the UUID that we found.
item.CreatorId = ospResolvedId.ToString();
}
else else
{
item.CreatorIdAsUuid = m_userInfo.UserProfile.ID; item.CreatorIdAsUuid = m_userInfo.UserProfile.ID;
}
item.Owner = m_userInfo.UserProfile.ID; item.Owner = m_userInfo.UserProfile.ID;

View File

@ -280,7 +280,7 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver
string savePath = (cmdparams.Length > 6 ? cmdparams[6] : DEFAULT_INV_BACKUP_FILENAME); string savePath = (cmdparams.Length > 6 ? cmdparams[6] : DEFAULT_INV_BACKUP_FILENAME);
m_log.InfoFormat( m_log.InfoFormat(
"[INVENTORY ARCHIVER]: Saving archive {0} from inventory path {1} for {2} {3}", "[INVENTORY ARCHIVER]: Saving archive {0} using inventory path {1} for {2} {3}",
savePath, invPath, firstName, lastName); savePath, invPath, firstName, lastName);
Guid id = Guid.NewGuid(); Guid id = Guid.NewGuid();

View File

@ -259,9 +259,16 @@ namespace OpenSim.Region.CoreModules.Avatar.Inventory.Archiver.Tests
= InventoryArchiveUtils.FindItemByPath(scene.InventoryService, userInfo.UserProfile.ID, item1Name); = InventoryArchiveUtils.FindItemByPath(scene.InventoryService, userInfo.UserProfile.ID, item1Name);
Assert.That(foundItem1, Is.Not.Null, "Didn't find loaded item 1"); Assert.That(foundItem1, Is.Not.Null, "Didn't find loaded item 1");
// We have to disable this check since loaded items that did find users via OSPA resolution are now only storing the
// UUID, not the OSPA itself.
// Assert.That(
// foundItem1.CreatorId, Is.EqualTo(item1.CreatorId),
// "Loaded item non-uuid creator doesn't match original");
Assert.That( Assert.That(
foundItem1.CreatorId, Is.EqualTo(item1.CreatorId), foundItem1.CreatorId, Is.EqualTo(userItemCreatorUuid.ToString()),
"Loaded item non-uuid creator doesn't match original"); "Loaded item non-uuid creator doesn't match original");
Assert.That( Assert.That(
foundItem1.CreatorIdAsUuid, Is.EqualTo(userItemCreatorUuid), foundItem1.CreatorIdAsUuid, Is.EqualTo(userItemCreatorUuid),
"Loaded item uuid creator doesn't match original"); "Loaded item uuid creator doesn't match original");

View File

@ -247,8 +247,7 @@ namespace OpenSim.Region.Framework.Scenes.Animation
else if (m_movementAnimation == "LAND") else if (m_movementAnimation == "LAND")
{ {
float landElapsed = (float)(Environment.TickCount - m_animTickFall) / 1000f; float landElapsed = (float)(Environment.TickCount - m_animTickFall) / 1000f;
if ((m_animTickFall != 0) && (landElapsed <= FALL_DELAY))
if (landElapsed <= FALL_DELAY)
return "LAND"; return "LAND";
} }

View File

@ -62,7 +62,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
public void Initialise(IConfigSource config) public void Initialise(IConfigSource config)
{ {
m_log.Info("[RegionReady] Initialising"); //m_log.Info("[RegionReady] Initialising");
m_config = config.Configs["RegionReady"]; m_config = config.Configs["RegionReady"];
if (m_config != null) if (m_config != null)
@ -74,8 +74,8 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
} }
} }
if (!m_enabled) // if (!m_enabled)
m_log.Info("[RegionReady] disabled."); // m_log.Info("[RegionReady] disabled.");
} }
public void AddRegion(Scene scene) public void AddRegion(Scene scene)
@ -92,7 +92,7 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
m_scene.EventManager.OnEmptyScriptCompileQueue += OnEmptyScriptCompileQueue; m_scene.EventManager.OnEmptyScriptCompileQueue += OnEmptyScriptCompileQueue;
m_scene.EventManager.OnOarFileLoaded += OnOarFileLoaded; m_scene.EventManager.OnOarFileLoaded += OnOarFileLoaded;
m_log.InfoFormat("[RegionReady]: Enabled for region {0}", scene.RegionInfo.RegionName); m_log.DebugFormat("[RegionReady]: Enabled for region {0}", scene.RegionInfo.RegionName);
} }
public void RemoveRegion(Scene scene) public void RemoveRegion(Scene scene)
@ -120,7 +120,6 @@ namespace OpenSim.Region.OptionalModules.Scripting.RegionReady
} }
#endregion #endregion
void OnEmptyScriptCompileQueue(int numScriptsFailed, string message) void OnEmptyScriptCompileQueue(int numScriptsFailed, string message)
{ {

View File

@ -1987,6 +1987,18 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api
//KF: Do NOT use this next line if using ODE physics engine. This need a switch based on .ini Phys Engine type //KF: Do NOT use this next line if using ODE physics engine. This need a switch based on .ini Phys Engine type
// part.ParentGroup.AbsolutePosition = part.ParentGroup.AbsolutePosition; // part.ParentGroup.AbsolutePosition = part.ParentGroup.AbsolutePosition;
// So, after thinking about this for a bit, the issue with the part.ParentGroup.AbsolutePosition = part.ParentGroup.AbsolutePosition line
// is it isn't compatible with vehicles because it causes the vehicle body to have to be broken down and rebuilt
// It's perfectly okay when the object is not an active physical body though.
// So, part.ParentGroup.ResetChildPrimPhysicsPositions(); does the thing that Kitto is warning against
// but only if the object is not physial and active. This is important for rotating doors.
// without the absoluteposition = absoluteposition happening, the doors do not move in the physics
// scene
if (part.PhysActor != null && !part.PhysActor.IsPhysical)
{
part.ParentGroup.ResetChildPrimPhysicsPositions();
}
} }
/// <summary> /// <summary>