Hi everybody,
I'm using Spring in a J2EE application and I get the following error:
Thanks and regards
Edited by: valeof on Jul 23, 2009 9:27 AM
I'm using Spring in a J2EE application and I get the following error:
ERROR 181625 10:55:09,750 controller.SISComboController error.134 - doService - eccezione view - java.lang.reflect.InvocationTargetException
[23/07/09 10.56.19:875 CEST] 00000045 ServletWrappe E SRVE0068E: Impossibile richiamare il metodo service() per il servlet SISComboController. Eccezione generata : java.lang.NullPointerException
at it.icg.sis.view.controller.SISComboController.doService(SISComboController.java:55)
at com.sysdat.servlet.SysdatHttpServlet.doGet(SysdatHttpServlet.java:57)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:743)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1212)
at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:629)
at com.ibm.ws.webcontainer.webapp.WebApp.handleRequest(WebApp.java:2837)
at com.ibm.ws.webcontainer.webapp.WebGroup.handleRequest(WebGroup.java:220)
at com.ibm.ws.webcontainer.VirtualHost.handleRequest(VirtualHost.java:204)
at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1681)
at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:77)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:421)
at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:367)
at com.ibm.ws.http.channel.inbound.impl.HttpICLReadCallback.complete(HttpICLReadCallback.java:94)
at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java:548)
at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java:601)
at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun(WorkQueueManager.java:934)
at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java:1021)
at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java:1332)
This is part of the file SISComboController.java:
try {
SISSuggestObj sisObj = new SISSuggestObj();
sisObj.req = req;
Object[] parObj = {sisObj};
Class[] parClass = {sisObj.getClass()};
SISComboViewHelper sisDojoObject = new SISComboViewHelper();
Method method_ = sisDojoObject.getClass().getMethod("carica"+dataCombo+"Combo", parClass );
jSONObject = (JSONObject)method_.invoke(sisDojoObject, parObj );
} catch (Exception e) {
Log.getInstance().error(this.getClass().getName(), "doService - eccezione view - "+e.toString());
}
The metodo I'm calling is:
public JSONObject caricaGaranzieCombo(SISSuggestObj sisObj){
JSONObject jSONObject = null;
List listaGara = new ArrayList();
List listaGaraFormBean = new ArrayList();
SISVwTabelleGaraService service=(SISVwTabelleGaraService)SpringFactory.getSISBean(SpringFactory.SERVICES,"sisVwTabelleGaraService");
VwTabelleGaraCriteria example=new VwTabelleGaraCriteria();
try {
listaGara = service.selectByExample(example);
SISVwTabelleGaraViewHelper helper = new SISVwTabelleGaraViewHelper();
listaGaraFormBean=helper.formattaListaVwTabelleGaraFormBean(listaGara);
jSONObject = helper.formattaGaranzieCombo(listaGaraFormBean);
} catch (Exception e) {
e.printStackTrace();
}
return jSONObject;
}
In serviceConfig.xml of Spring we have:
<bean id="id_VwTabelleGaraDao" class="it.icg.sis.business.daoImpl.SISVwTabelleGaraDaoImpl">
<property name="sqlMapClient">
<ref bean="sqlMapClient"/>
</property>
</bean>
<bean id="sisVwTabelleGaraService" class="it.icg.sis.business.serviceImpl.SISVwTabelleGaraServiceImpl">
<constructor-arg ref="id_VwTabelleGaraDao"/>
</bean>
I've got an error when I try to instantiate the service: can somebody help me?Thanks and regards
Edited by: valeof on Jul 23, 2009 9:27 AM