Explictly close down the StatsReporter so that we can shutdown its timer

This is another step necessary for the scene to be garbage collected between performance tests
0.7.4.1
Justin Clark-Casey (justincc) 2012-03-06 19:05:32 +00:00
parent b3449e998a
commit 0f4cdc0c5b
2 changed files with 8 additions and 0 deletions

View File

@ -1076,6 +1076,8 @@ namespace OpenSim.Region.Framework.Scenes
{
m_log.InfoFormat("[SCENE]: Closing down the single simulator: {0}", RegionInfo.RegionName);
StatsReporter.Close();
m_restartTimer.Stop();
m_restartTimer.Close();

View File

@ -185,6 +185,12 @@ namespace OpenSim.Region.Framework.Scenes
OnSendStatsResult += StatsManager.SimExtraStats.ReceiveClassicSimStatsPacket;
}
public void Close()
{
m_report.Elapsed -= statsHeartBeat;
m_report.Close();
}
public void SetUpdateMS(int ms)
{
statsUpdatesEveryMS = ms;