diff options
author | Melanie | 2009-08-14 14:18:56 +0100 |
---|---|---|
committer | Melanie | 2009-08-14 14:18:56 +0100 |
commit | 7a2a2e68e7e235b9d79c09d98a4cf0b6f87a2a85 (patch) | |
tree | 40505bc8d848210ba6440e9273c38033ae815bd7 /OpenSim | |
parent | Deal with possible race in TestAddNeighborRegion in ScenePresenceTests (diff) | |
download | opensim-SC_OLD-7a2a2e68e7e235b9d79c09d98a4cf0b6f87a2a85.zip opensim-SC_OLD-7a2a2e68e7e235b9d79c09d98a4cf0b6f87a2a85.tar.gz opensim-SC_OLD-7a2a2e68e7e235b9d79c09d98a4cf0b6f87a2a85.tar.bz2 opensim-SC_OLD-7a2a2e68e7e235b9d79c09d98a4cf0b6f87a2a85.tar.xz |
Remove the script sponsor logic because scripts are timing out again.
This needs to be looked into. This commit, unfortunately, reinstates
a memory leak in regions that see significant script fluctuation,
e.g. lots of scripted attachments, or script development.
Diffstat (limited to 'OpenSim')
4 files changed, 15 insertions, 19 deletions
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs index ff85b96..691732a 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/LSL_Api.cs | |||
@@ -125,9 +125,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
125 | 125 | ||
126 | if (lease.CurrentState == LeaseState.Initial) | 126 | if (lease.CurrentState == LeaseState.Initial) |
127 | { | 127 | { |
128 | lease.InitialLeaseTime = TimeSpan.FromMinutes(1.0); | 128 | lease.InitialLeaseTime = TimeSpan.FromMinutes(0); |
129 | lease.RenewOnCallTime = TimeSpan.FromSeconds(10.0); | 129 | // lease.RenewOnCallTime = TimeSpan.FromSeconds(10.0); |
130 | lease.SponsorshipTimeout = TimeSpan.FromMinutes(1.0); | 130 | // lease.SponsorshipTimeout = TimeSpan.FromMinutes(1.0); |
131 | } | 131 | } |
132 | return lease; | 132 | return lease; |
133 | } | 133 | } |
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs index 6539bda..6e3a3ab 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Implementation/OSSL_Api.cs | |||
@@ -166,9 +166,9 @@ namespace OpenSim.Region.ScriptEngine.Shared.Api | |||
166 | 166 | ||
167 | if (lease.CurrentState == LeaseState.Initial) | 167 | if (lease.CurrentState == LeaseState.Initial) |
168 | { | 168 | { |
169 | lease.InitialLeaseTime = TimeSpan.FromMinutes(1.0); | 169 | lease.InitialLeaseTime = TimeSpan.FromMinutes(0); |
170 | lease.RenewOnCallTime = TimeSpan.FromSeconds(10.0); | 170 | // lease.RenewOnCallTime = TimeSpan.FromSeconds(10.0); |
171 | lease.SponsorshipTimeout = TimeSpan.FromMinutes(1.0); | 171 | // lease.SponsorshipTimeout = TimeSpan.FromMinutes(1.0); |
172 | } | 172 | } |
173 | return lease; | 173 | return lease; |
174 | } | 174 | } |
diff --git a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/ScriptBase.cs b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/ScriptBase.cs index d119a77..838cafb 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/ScriptBase.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Api/Runtime/ScriptBase.cs | |||
@@ -42,16 +42,17 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase | |||
42 | public partial class ScriptBaseClass : MarshalByRefObject, IScript | 42 | public partial class ScriptBaseClass : MarshalByRefObject, IScript |
43 | { | 43 | { |
44 | private Dictionary<string, MethodInfo> inits = new Dictionary<string, MethodInfo>(); | 44 | private Dictionary<string, MethodInfo> inits = new Dictionary<string, MethodInfo>(); |
45 | private ScriptSponsor m_sponser; | 45 | // private ScriptSponsor m_sponser; |
46 | 46 | ||
47 | public override Object InitializeLifetimeService() | 47 | public override Object InitializeLifetimeService() |
48 | { | 48 | { |
49 | ILease lease = (ILease)base.InitializeLifetimeService(); | 49 | ILease lease = (ILease)base.InitializeLifetimeService(); |
50 | if (lease.CurrentState == LeaseState.Initial) | 50 | if (lease.CurrentState == LeaseState.Initial) |
51 | { | 51 | { |
52 | lease.InitialLeaseTime = TimeSpan.FromMinutes(1.0); | 52 | // Infinite |
53 | lease.RenewOnCallTime = TimeSpan.FromSeconds(10.0); | 53 | lease.InitialLeaseTime = TimeSpan.FromMinutes(0); |
54 | lease.SponsorshipTimeout = TimeSpan.FromMinutes(1.0); | 54 | // lease.RenewOnCallTime = TimeSpan.FromSeconds(10.0); |
55 | // lease.SponsorshipTimeout = TimeSpan.FromMinutes(1.0); | ||
55 | } | 56 | } |
56 | return lease; | 57 | return lease; |
57 | } | 58 | } |
@@ -79,7 +80,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase | |||
79 | } | 80 | } |
80 | } | 81 | } |
81 | 82 | ||
82 | m_sponser = new ScriptSponsor(); | 83 | // m_sponser = new ScriptSponsor(); |
83 | } | 84 | } |
84 | 85 | ||
85 | private Executor m_Executor = null; | 86 | private Executor m_Executor = null; |
@@ -112,7 +113,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase | |||
112 | return; | 113 | return; |
113 | 114 | ||
114 | ILease lease = (ILease)RemotingServices.GetLifetimeService(data as MarshalByRefObject); | 115 | ILease lease = (ILease)RemotingServices.GetLifetimeService(data as MarshalByRefObject); |
115 | lease.Register(m_sponser); | 116 | // lease.Register(m_sponser); |
116 | 117 | ||
117 | MethodInfo mi = inits[api]; | 118 | MethodInfo mi = inits[api]; |
118 | 119 | ||
@@ -126,7 +127,7 @@ namespace OpenSim.Region.ScriptEngine.Shared.ScriptBase | |||
126 | 127 | ||
127 | public void Close() | 128 | public void Close() |
128 | { | 129 | { |
129 | m_sponser.Close(); | 130 | // m_sponser.Close(); |
130 | } | 131 | } |
131 | 132 | ||
132 | public Dictionary<string, object> GetVars() | 133 | public Dictionary<string, object> GetVars() |
diff --git a/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs b/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs index 4211ced..7bbaac0 100644 --- a/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs +++ b/OpenSim/Region/ScriptEngine/Shared/Instance/ScriptInstance.cs | |||
@@ -53,7 +53,7 @@ using OpenSim.Region.ScriptEngine.Interfaces; | |||
53 | 53 | ||
54 | namespace OpenSim.Region.ScriptEngine.Shared.Instance | 54 | namespace OpenSim.Region.ScriptEngine.Shared.Instance |
55 | { | 55 | { |
56 | public class ScriptInstance : MarshalByRefObject, IScriptInstance, ISponsor | 56 | public class ScriptInstance : MarshalByRefObject, IScriptInstance |
57 | { | 57 | { |
58 | // private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | 58 | // private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); |
59 | 59 | ||
@@ -1006,10 +1006,5 @@ namespace OpenSim.Region.ScriptEngine.Shared.Instance | |||
1006 | { | 1006 | { |
1007 | return true; | 1007 | return true; |
1008 | } | 1008 | } |
1009 | |||
1010 | public TimeSpan Renewal(ILease lease) | ||
1011 | { | ||
1012 | return lease.InitialLeaseTime; | ||
1013 | } | ||
1014 | } | 1009 | } |
1015 | } | 1010 | } |