• Welcome to KonaKart Community Forum. Please login or sign up.
 

Paypal problem

Started by tronerrr, September 29, 2009, 02:57:45 pm

Previous topic - Next topic

tronerrr

I am having a problem when the paypal payment is completed and the customer is redirected back to my site.
All of that works fine but when they get back to my site they are logged out and brought to the register/login page.

If i go through with the payment through paypal and i check the payment info the gateway response is "completed" but the KonaKart Result Description: reads "There has been an unexpected exception. Please look at the log."

This is my log:


com.konakart.app.KKException: The String parameter called sessionId must be given a value. It cannot be set to null or be left empty.
        at com.konakart.bl.BaseMgr.checkRequired(Unknown Source)
        at com.konakart.bl.EmailMgr.sendOrderConfirmationEmail1(Unknown Source)
        at com.konakart.app.KKEng.sendOrderConfirmationEmail1(Unknown Source)
        at com.konakart.actions.gateways.BaseGatewayAction.sendOrderConfirmationMail(Unknown Source)
        at com.konakart.actions.ipn.PayPalAction.execute(Unknown Source)
        at org.apache.struts.action.RequestProcessor.processActionPerform(RequestProcessor.java:431)
        at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:236)
        at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1196)
        at org.apache.struts.action.ActionServlet.doPost(ActionServlet.java:432)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:637)
        at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
        at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
        at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
        at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233)
        at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191)
        at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:128)
        at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
        at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
        at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:286)
        at org.apache.coyote.http11.Http11AprProcessor.process(Http11AprProcessor.java:857)
        at org.apache.coyote.http11.Http11AprProtocol$Http11ConnectionHandler.process(Http11AprProtocol.java:565)
        at org.apache.tomcat.util.net.AprEndpoint$Worker.run(AprEndpoint.java:1509)
        at java.lang.Thread.run(Thread.java:619)

Anyone have any idea on this?

thx.

Vladimir

I faced with the same problem when develop my own payment module. As I understand it, to use the KKAppEng in payment gateway callback action, are required to log into the system and get an sessionId. This is done in module by calling sessionId = kkAppEng.getEng().login(username, password);. This sessionId is used directly in subsequent calls to the engine. But when payment module calling sending email method sendOrderConfirmationMail(kkAppEng, orderId, /* success */true), the sessionId don't passed directly in method call. Apparently, to get the sessionId, somewhere in the implementation of the method used kkAppEng.getSessionId(), but after call login method, sessionId is absent in kkAppEng! So, in my module after sessionId = kkAppEng.getEng().login(username, password);
i just put this line
kkAppEng.setSessionId(sessionId);
and then sending email processing is succeful

tronerrr