diff options
Diffstat (limited to '')
-rw-r--r-- | OpenSim/Addons/Groups/GroupsMessagingModule.cs | 34 |
1 files changed, 31 insertions, 3 deletions
diff --git a/OpenSim/Addons/Groups/GroupsMessagingModule.cs b/OpenSim/Addons/Groups/GroupsMessagingModule.cs index bbb5e05..bd8db32 100644 --- a/OpenSim/Addons/Groups/GroupsMessagingModule.cs +++ b/OpenSim/Addons/Groups/GroupsMessagingModule.cs | |||
@@ -56,8 +56,8 @@ namespace OpenSim.Groups | |||
56 | private IGroupsServicesConnector m_groupData = null; | 56 | private IGroupsServicesConnector m_groupData = null; |
57 | 57 | ||
58 | // Config Options | 58 | // Config Options |
59 | private bool m_groupMessagingEnabled = false; | 59 | private bool m_groupMessagingEnabled; |
60 | private bool m_debugEnabled = true; | 60 | private bool m_debugEnabled; |
61 | 61 | ||
62 | /// <summary> | 62 | /// <summary> |
63 | /// If enabled, module only tries to send group IMs to online users by querying cached presence information. | 63 | /// If enabled, module only tries to send group IMs to online users by querying cached presence information. |
@@ -120,7 +120,7 @@ namespace OpenSim.Groups | |||
120 | return; | 120 | return; |
121 | } | 121 | } |
122 | 122 | ||
123 | m_debugEnabled = groupsConfig.GetBoolean("DebugEnabled", true); | 123 | m_debugEnabled = groupsConfig.GetBoolean("MessagingDebugEnabled", m_debugEnabled); |
124 | 124 | ||
125 | m_log.InfoFormat( | 125 | m_log.InfoFormat( |
126 | "[Groups.Messaging]: GroupsMessagingModule enabled with MessageOnlineOnly = {0}, DebugEnabled = {1}", | 126 | "[Groups.Messaging]: GroupsMessagingModule enabled with MessageOnlineOnly = {0}, DebugEnabled = {1}", |
@@ -140,6 +140,14 @@ namespace OpenSim.Groups | |||
140 | scene.EventManager.OnMakeChildAgent += OnMakeChildAgent; | 140 | scene.EventManager.OnMakeChildAgent += OnMakeChildAgent; |
141 | scene.EventManager.OnIncomingInstantMessage += OnGridInstantMessage; | 141 | scene.EventManager.OnIncomingInstantMessage += OnGridInstantMessage; |
142 | scene.EventManager.OnClientLogin += OnClientLogin; | 142 | scene.EventManager.OnClientLogin += OnClientLogin; |
143 | |||
144 | scene.AddCommand( | ||
145 | "Debug", | ||
146 | this, | ||
147 | "debug groups messaging verbose", | ||
148 | "debug groups messaging verbose <true|false>", | ||
149 | "This setting turns on very verbose groups messaging debugging", | ||
150 | HandleDebugGroupsMessagingVerbose); | ||
143 | } | 151 | } |
144 | 152 | ||
145 | public void RegionLoaded(Scene scene) | 153 | public void RegionLoaded(Scene scene) |
@@ -227,6 +235,26 @@ namespace OpenSim.Groups | |||
227 | 235 | ||
228 | #endregion | 236 | #endregion |
229 | 237 | ||
238 | private void HandleDebugGroupsMessagingVerbose(object modules, string[] args) | ||
239 | { | ||
240 | if (args.Length < 5) | ||
241 | { | ||
242 | MainConsole.Instance.Output("Usage: debug groups messaging verbose <true|false>"); | ||
243 | return; | ||
244 | } | ||
245 | |||
246 | bool verbose = false; | ||
247 | if (!bool.TryParse(args[4], out verbose)) | ||
248 | { | ||
249 | MainConsole.Instance.Output("Usage: debug groups messaging verbose <true|false>"); | ||
250 | return; | ||
251 | } | ||
252 | |||
253 | m_debugEnabled = verbose; | ||
254 | |||
255 | MainConsole.Instance.OutputFormat("{0} verbose logging set to {1}", Name, m_debugEnabled); | ||
256 | } | ||
257 | |||
230 | /// <summary> | 258 | /// <summary> |
231 | /// Not really needed, but does confirm that the group exists. | 259 | /// Not really needed, but does confirm that the group exists. |
232 | /// </summary> | 260 | /// </summary> |