Joel Freeman - 2009-06-18

I used the "Simple + XML-RPC" implementation of Redstone, where instead of having to hook up the system to a webserver you can just generate a makeshift java webserver.

It has worked well for me, but one issue I had was that every time the Simple webserver received an RPC, it would print information about the call.  Turns out that the current version (version 1.0) always has debug-mode turned on.

The solution is to download the source code for the smallest JAR file, make a few changes, compile, and then JAR it into a replacement JAR. The JAR file contains two classes: Main.java and Server.java

--------------------------------------------------

Here are the changes:

In Server, change the constructor to:

public Server( int port, boolean debug ) throws Exception
{
address = new InetSocketAddress( port );
connection = new SocketConnection( this );
xmlRpcServer = new XmlRpcServer();
if (debug) xmlRpcServer.addInvocationInterceptor( new DebugInvocationInterceptor() );
}

I instantiate the Simple Server programatically, so Main wasn't relevant to me. Nonetheless just for the heck of it in Main:

Change line 58 to: server = new Server( Integer.parseInt( args[ 0 ] ), true );