27,13 → 27,10 |
import java.util.HashMap; |
import java.util.List; |
import java.util.Map; |
|
import javax.xml.stream.XMLStreamException; |
|
import javax.xml.ws.BindingProvider; |
|
import net.brutex.emitter.util.EmitterUtil; |
import net.brutex.sbm.sbmappservices72.AEWebservicesFaultFault; |
import net.brutex.sbm.sbmappservices72.Sbmappservices72; |
import net.brutex.sbm.sbmappservices72.Sbmappservices72PortType; |
import net.brutex.sbm.sbmappservices72.api.Auth; |
import net.brutex.sbm.sbmappservices72.api.MultipleResponseItemOptions; |
70,6 → 67,7 |
import org.apache.cxf.frontend.ClientProxy; |
import org.apache.cxf.interceptor.LoggingInInterceptor; |
import org.apache.cxf.interceptor.LoggingOutInterceptor; |
import org.apache.cxf.jaxws.JaxWsProxyFactoryBean; |
import org.apache.http.client.ClientProtocolException; |
import org.apache.log4j.Logger; |
import org.jaxen.JaxenException; |
134,6 → 132,11 |
private static final String PARAM_CONFIG = "conf"; |
|
// |
// |
// |
private static final String CACHE_SBMPORT = "sbmappservices72"; |
|
// |
// Member variables |
// |
private final String repos; |
239,7 → 242,11 |
} |
} |
if(logmessage==null) logmessage=""; |
if(key.contains("password") && value!=null ) { |
logger.debug(String.format("Using property value '%s' for key '%s'. %s", "******", key, logmessage)); |
} else { |
if(value!=null) logger.debug(String.format("Using property value '%s' for key '%s'. %s", value, key, logmessage)); |
} |
return value; |
} |
|
400,7 → 407,7 |
out.flush(); |
|
resultxml = out.getBuffer().toString(); |
logger.debug("ALFEvent result:\n"+resultxml); |
if(isTrace) logger.debug("ALFEvent result:\n"+resultxml); |
|
} else { |
logger.debug("Xml processing is deactivated."); |
552,22 → 559,50 |
|
|
private TTItemList getTTItems(String issueid, boolean isTrace) throws MalformedURLException { |
long startTime = System.currentTimeMillis(); |
Sbmappservices72PortType port = null; |
//try { |
// JCS cache = JCS.getInstance("FileCache"); |
|
long startTime = System.currentTimeMillis(); |
/* -- */ |
// port = (Sbmappservices72PortType)cache.get(CACHE_SBMPORT); |
/* |
if(port==null) { |
Sbmappservices72 ss = new Sbmappservices72(ClassLoader.getSystemResource("sbmappservices72.wsdl") ); |
|
port = ss.getSbmappservices72(); |
|
|
BindingProvider bindingProvider = (BindingProvider) port; |
bindingProvider.getRequestContext().put( |
BindingProvider.ENDPOINT_ADDRESS_PROPERTY, endpoint); |
} |
*/ |
JaxWsProxyFactoryBean factory = new JaxWsProxyFactoryBean(); |
factory.setServiceClass(Sbmappservices72PortType.class); |
factory.setAddress(endpoint); |
port = (Sbmappservices72PortType) factory.create(); |
logger.debug("Total execution of sbmappservices72 wsdl read took '"+(System.currentTimeMillis()-startTime)+"' milliseconds."); |
Sbmappservices72PortType port = ss.getSbmappservices72(); |
|
|
// cache.put(CACHE_SBMPORT, port); |
// cache.dispose(); |
// } else { |
// logger.debug("sbmappservices72 port was read from cache."); |
// } |
|
//} catch (CacheException e1) { |
// // TODO Auto-generated catch block |
// e1.printStackTrace(); |
// this.exit(1); |
//} |
|
if(isTrace) { |
Client client = ClientProxy.getClient(port); |
if(isTrace) { |
client.getInInterceptors().add(new LoggingInInterceptor()); |
client.getOutInterceptors().add(new LoggingOutInterceptor()); |
} |
BindingProvider bindingProvider = (BindingProvider) port; |
bindingProvider.getRequestContext().put( |
BindingProvider.ENDPOINT_ADDRESS_PROPERTY, endpoint); |
|
/* -- */ |
logger.debug("Total execution of sbmappservices72 initialisation took '"+(System.currentTimeMillis()-startTime)+"' milliseconds."); |
|