Get rid of SymSync in OpenSim.ini, old way of object sync no longer works (via RegionSyncServer).

SyncListenerAddress/Port renamed as SyncServerAddress/Port.
dsg
Huaiyu (Kitty) Liu 2011-01-20 16:19:51 -08:00
parent e39d2ab14f
commit 677889d3b6
6 changed files with 32 additions and 21 deletions

View File

@ -388,8 +388,8 @@ namespace OpenSim.Framework
//SYMMETRIC SYNC
//IP:port for the symmetric sync listener this actor is configured to connect to
private string m_syncListenerAddr = String.Empty;
private int m_syncListenerPort;
private string m_syncServerAddr = String.Empty;
private int m_syncServerPort;
//IP:port for the avatar sync server this actor is configured to connect to
private string m_avatarSyncServerAddr = String.Empty;
private int m_avatarSyncServerPort;
@ -687,13 +687,13 @@ namespace OpenSim.Framework
}
//SYMMETRIC SYNC
public string SyncListenerAddress
public string SyncServerAddress
{
get { return m_syncListenerAddr; }
get { return m_syncServerAddr; }
}
public int SyncListenerPort
public int SyncServerPort
{
get { return m_syncListenerPort; }
get { return m_syncServerPort; }
}
public string AvatarSyncServerAddress
{
@ -873,18 +873,18 @@ namespace OpenSim.Framework
ScopeID = new UUID(config.GetString("ScopeID", UUID.Zero.ToString()));
// SYMMETRIC SYNC
m_syncListenerAddr = config.GetString("SyncListenerAddress", String.Empty);
m_syncListenerPort = config.GetInt("SyncListenerPort", -1);
m_syncServerAddr = config.GetString("SyncServerAddress", String.Empty);
m_syncServerPort = config.GetInt("SyncServerPort", -1);
//if either IP or port is not configured, we set IP to empty to raise warning later
if (m_syncListenerPort == -1)
m_syncListenerAddr = String.Empty;
if (m_syncServerPort == -1)
m_syncServerAddr = String.Empty;
m_avatarSyncServerAddr = config.GetString("AvatarSyncServerAddress", String.Empty);
m_avatarSyncServerPort = config.GetInt("AvatarSyncServerPort", -1);
if (m_avatarSyncServerPort == -1)
m_avatarSyncServerAddr = String.Empty;
string quarkLocation = config.GetString("SyncQuarkLocation", String.Empty);
string quarkLocation = config.GetString("SyncQuarkLocation", "1000,1000");
string[] quarkLocElements = location.Split(new char[] { ',' });

View File

@ -77,7 +77,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
m_scene.RegisterModuleInterface<IRegionSyncClientModule>(this);
m_symsync = syncConfig.GetBoolean("SymSync", false);
//m_symsync = syncConfig.GetBoolean("SymSync", false);
// Setup the command line interface
m_scene.EventManager.OnPluginConsole += EventManager_OnPluginConsole;
@ -160,7 +160,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
private Object m_client_lock = new Object();
private RegionSyncClient m_client = null;
private bool m_symsync = false;
//private bool m_symsync = false;
#endregion
@ -253,7 +253,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
m_log.Warn("[REGION SYNC CLIENT MODULE] Starting RegionSyncClient");
m_client = new RegionSyncClient(m_scene, m_serveraddr, m_serverport);
m_client.SetSymSync(m_symsync);
//m_client.SetSymSync(m_symsync);
m_client.Start();
}
}

View File

@ -307,15 +307,18 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
//SYMMETRIC SYNC: do not handle terrian and object updates
case RegionSyncMessage.MsgType.GetTerrain:
{
/*
if (!m_scene.RegionSyncServerModule.IsSymSync)
{
Send(new RegionSyncMessage(RegionSyncMessage.MsgType.Terrain, m_scene.Heightmap.SaveToXmlString()));
RegionSyncMessage.HandleSuccess(LogHeader, msg, "Terrain sent");
}
* */
return;
}
case RegionSyncMessage.MsgType.GetObjects:
{
/*
if (!m_scene.RegionSyncServerModule.IsSymSync)
{
EntityBase[] entities = m_scene.GetEntities();
@ -329,6 +332,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
}
RegionSyncMessage.HandleSuccess(LogHeader, msg, "Sent all scene objects");
}
* */
return;
}
//end of SYMMETRIC SYNC

View File

@ -124,7 +124,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
m_peSyncServerport = syncConfig.GetInt(peServerPort, DefaultPort);
DefaultPort++;
m_symsync = syncConfig.GetBoolean("SymSync", false);
// m_symsync = syncConfig.GetBoolean("SymSync", false);
//Get quark information
QuarkInfo.SizeX = syncConfig.GetInt("QuarkSizeX", (int)Constants.RegionSize);
@ -156,6 +156,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
m_scene.EventManager.OnRemovePresence += new EventManager.OnRemovePresenceDelegate(EventManager_OnRemovePresence);
//SYMMETRIC SYNC: do not handle object updates
/*
if (!m_symsync)
{
m_scene.SceneGraph.OnObjectCreate += new ObjectCreateDelegate(SceneGraph_OnObjectCreate);
@ -164,6 +165,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
//m_scene.StatsReporter.OnSendStatsResult += new SimStatsReporter.SendStatResult(StatsReporter_OnSendStatsResult);
m_scene.EventManager.OnOarFileLoaded += new EventManager.OarFileLoaded(EventManager_OnOarFileLoaded);
}
* */
//end of SYMMETRIC SYNC
// Start the server and listen for RegionSyncClients
m_serveraddr = m_scene.RegionInfo.AvatarSyncServerAddress;
@ -301,6 +303,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
// as parts may be updated many many times very quickly. Need to implement a higher resolution send in heartbeat
//SYMMETRIC SYNC: do not handle object updates
/*
if (!m_symsync)
{
foreach (SceneObjectGroup sog in primUpdates)
@ -315,6 +318,7 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
}
}
}
* */
//end of SYMMETRIC SYNC
foreach (ScenePresence presence in presenceUpdates)
{
@ -520,12 +524,15 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
private SceneToPhysEngineSyncServer m_sceneToPESyncServer = null;
//a boolean variable to indicate in symmetric sync is configured
private bool m_symsync = false;
//private bool m_symsync = false;
/*
public bool IsSymSync
{
get { return IsSymSync; }
}
* */
//quark related information
//private int QuarkInfo.SizeX;
//private int QuarkInfo.SizeY;

View File

@ -566,8 +566,8 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
//string addr = m_sysConfig.GetString(m_scene.RegionInfo.RegionName+"_SyncListenerIPAddress", IPAddrUnknown);
//int port = m_sysConfig.GetInt(m_scene.RegionInfo.RegionName+"_SyncListenerPort", PortUnknown);
string addr = m_scene.RegionInfo.SyncListenerAddress;
int port = m_scene.RegionInfo.SyncListenerPort;
string addr = m_scene.RegionInfo.SyncServerAddress;
int port = m_scene.RegionInfo.SyncServerPort;
m_log.Warn(LogHeader + ": listener addr: " + addr + ", port: " + port);
@ -592,8 +592,8 @@ namespace OpenSim.Region.CoreModules.RegionSync.RegionSyncModule
//string addr = m_sysConfig.GetString(m_scene.RegionInfo.RegionName + "_SyncListenerIPAddress", IPAddrUnknown);
//int port = m_sysConfig.GetInt(m_scene.RegionInfo.RegionName + "_SyncListenerPort", PortUnknown);
string addr = m_scene.RegionInfo.SyncListenerAddress;
int port = m_scene.RegionInfo.SyncListenerPort;
string addr = m_scene.RegionInfo.SyncServerAddress;
int port = m_scene.RegionInfo.SyncServerPort;
if (!addr.Equals(IPAddrUnknown) && port != PortUnknown)
{

View File

@ -39,7 +39,7 @@ namespace OpenSim.Region.Framework.Interfaces
bool Active { get; }
bool Synced { get; }
bool IsSymSync { get; } //If SymSync is set to true in the config file, then Symmetric Sync is running and object updates should be handled through RegionSyncModule
//bool IsSymSync { get; } //If SymSync is set to true in the config file, then Symmetric Sync is running and object updates should be handled through RegionSyncModule
void QueuePartForUpdate(SceneObjectPart part);
void QueuePresenceForTerseUpdate(ScenePresence presence);