mirror of
https://github.com/opensim/opensim.git
synced 2026-08-06 01:06:30 +08:00
Make the "debug http" command available for robust as well as the simulator. This allows one to see incoming requests as they happen.
This required making everything use the common MainServer class for registering and retrieving http servers, rather than duplicate structures.
This commit is contained in:
@@ -30,6 +30,7 @@ using log4net;
|
||||
using System.Reflection;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using OpenSim.Framework.Servers;
|
||||
using OpenSim.Framework.Servers.HttpServer;
|
||||
using OpenSim.Server.Base;
|
||||
using OpenSim.Server.Handlers.Base;
|
||||
@@ -92,27 +93,24 @@ namespace OpenSim.Server
|
||||
if (parts.Length > 1)
|
||||
friendlyName = parts[1];
|
||||
|
||||
IHttpServer server = m_Server.HttpServer;
|
||||
if (port != 0)
|
||||
server = m_Server.GetHttpServer(port);
|
||||
IHttpServer server;
|
||||
|
||||
if (port != m_Server.DefaultPort && port != 0)
|
||||
m_log.InfoFormat("[SERVER]: Loading {0} on port {1}", friendlyName, port);
|
||||
if (port != 0)
|
||||
server = MainServer.GetHttpServer(port);
|
||||
else
|
||||
m_log.InfoFormat("[SERVER]: Loading {0}", friendlyName);
|
||||
server = MainServer.Instance;
|
||||
|
||||
m_log.InfoFormat("[SERVER]: Loading {0} on port {1}", friendlyName, server.Port);
|
||||
|
||||
IServiceConnector connector = null;
|
||||
|
||||
Object[] modargs = new Object[] { m_Server.Config, server,
|
||||
configName };
|
||||
connector = ServerUtils.LoadPlugin<IServiceConnector>(conn,
|
||||
modargs);
|
||||
Object[] modargs = new Object[] { m_Server.Config, server, configName };
|
||||
connector = ServerUtils.LoadPlugin<IServiceConnector>(conn, modargs);
|
||||
|
||||
if (connector == null)
|
||||
{
|
||||
modargs = new Object[] { m_Server.Config, server };
|
||||
connector =
|
||||
ServerUtils.LoadPlugin<IServiceConnector>(conn,
|
||||
modargs);
|
||||
connector = ServerUtils.LoadPlugin<IServiceConnector>(conn, modargs);
|
||||
}
|
||||
|
||||
if (connector != null)
|
||||
@@ -132,4 +130,4 @@ namespace OpenSim.Server
|
||||
return 0;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user