该程序从salesforce中提取数据并将其写入文本文件。
请帮助我理解错误原因。
Exception in thread "main" java.lang.ExceptionInInitializerError
at org.apache.axis.client.Service.getAxisClient(Service.java:104)
at org.apache.axis.client.Service.<init>(Service.java:113)
at com.sforce.soap.partner.SforceServiceLocator.<init>(SforceServiceLocator.java:16)
at com.ncr.common.dataaccess.UserAuthentication.nscLogin(UserAuthentication.java:171)
at com.ncr.common.dataaccess.UserAuthentication.getNscLogin(UserAuthentication.java:122)
at com.ncr.extract.lms.NSCPartnerContactExtractLMS.startExtract(NSCPartnerContactExtractLMS.java:403)
at com.ncr.extract.lms.NSCPartnerContactExtractLMS.main(NSCPartnerContactExtractLMS.java:85)
Caused by: org.apache.commons.logging.LogConfigurationException: org.apache.commons.logging.LogConfigurationException: java.lang.NullPointerException (Caused by java.lang.NullPointerException) (Caused by org.apache.commons.logging.LogConfigurationException: java.lang.NullPointerException (Caused by java.lang.NullPointerException))
at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:543)
at org.apache.commons.logging.impl.LogFactoryImpl.getInstance(LogFactoryImpl.java:235)
at org.apache.commons.logging.LogFactory.getLog(LogFactory.java:370)
at org.apache.axis.components.logger.LogFactory.getLog(LogFactory.java:37)
at org.apache.axis.handlers.BasicHandler.<clinit>(BasicHandler.java:43)
... 7 more
Caused by: org.apache.commons.logging.LogConfigurationException: java.lang.NullPointerException (Caused by java.lang.NullPointerException)
at org.apache.commons.logging.impl.LogFactoryImpl.getLogConstructor(LogFactoryImpl.java:397)
at org.apache.commons.logging.impl.LogFactoryImpl.newInstance(LogFactoryImpl.java:529)
... 11 more
Caused by: java.lang.NullPointerException
at org.apache.commons.logging.impl.LogFactoryImpl.getLogConstructor(LogFactoryImpl.java:374)
... 12 more
答案 0 :(得分:2)
您并没有真正提供有关您的代码的大量信息,而且很难从这个堆栈跟踪中说些什么。似乎log4j存在问题。你见过this related post吗?还要确保log4j lib包含在构建路径中。