*) Bugfix for httpdSoapHandler Initialisation.

git-svn-id: https://svn.berlios.de/svnroot/repos/yacy/trunk@545 6c8d7289-2bf4-0310-a012-ef5d649a1542
pull/1/head
theli 20 years ago
parent c3e1abffaf
commit 8c62fb49ba

@ -613,7 +613,14 @@ public final class httpd implements serverHandler {
if (this.prop.containsKey("PATH") && this.prop.getProperty("PATH").startsWith("/soap")) { if (this.prop.containsKey("PATH") && this.prop.getProperty("PATH").startsWith("/soap")) {
if (soapHandler == null) { if (soapHandler == null) {
try { try {
soapHandler = (httpdHandler) Class.forName("de.anomic.soap.httpdSoapHandler").newInstance(); // creating the soap handler class by name
Class soapHandlerClass = Class.forName("de.anomic.soap.httpdSoapHandler");
// Look for the proper constructor
Constructor soapHandlerConstructor = soapHandlerClass.getConstructor( new Class[] { serverSwitch.class } );
// creating the new object
soapHandler = (httpdHandler)soapHandlerConstructor.newInstance( new Object[] { this.switchboard } );
} catch (Exception e) { } catch (Exception e) {
sendRespondHeader(this.prop,this.session.out,httpVersion,503,null); sendRespondHeader(this.prop,this.session.out,httpVersion,503,null);
return serverCore.TERMINATE_CONNECTION; return serverCore.TERMINATE_CONNECTION;

Loading…
Cancel
Save