天天看點

Axis和Log4j一起使用時,出現異常org.apache.axis.ConfigurationException

調用成功,但是出現異常出現異常:org.apache.axis.configurationexception:

no service named  is available org.apache.axis.configurationexception: no

service named  is available

解決方法:stackoverflow上 

just a guess, but it looks like that error message is reporting that you‘ve left the service name blank. i imagine the code that generates that error message looks like this: 
according to the  linked to by @arnonym, this exception is somewhat misleading. in the first attempt to find the service a configurationexception is thrown and caught. it is logged at debug level by the configurationexception class. then another attempt is made using a different method to find the service that may then succeed. the workaround for this is to just change the log level on the configurationexception class to info in your log4j.properties:

我采用的第二種方法,加上之後沒有再列印異常資訊了。

另:參考