天天看点

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:

我采用的第二种方法,加上之后没有再打印异常信息了。

另:参考