|
|
Going POSTAL! JaxRpc, Axis, SSL, Resin
I'm going soo crazy with this issue that I'm not even sure where to start...
Let's see... Resin app uses Spring/Axis/JaxRpc to call a remote web service over SSL.Code:
org..beans.factory.BeanCreationException: Error creating
bean with name 'paymentClient' defined in ServletContext resource [/WEB-INF/ulct-registration-servlet.xml]:
Invocation of init method failed; nested exception is javax.xml.rpc.ServiceException:
Error processing WSDL document:
java.io.FileNotFoundException: froms:
Caused by: javax.xml.rpc.ServiceException: Error processing WSDL document:
java.io.FileNotFoundException: froms:
at org.apache.axis.client.Service.initService(Service.java:250)
at org.apache.axis.client.Service.lt;initgt;(Service.java:165)
at org.apache.axis.client.ServiceFactory.createService(ServiceFactory.java:198)
at org..remoting.jaxrpc.LocalJaxRpcServiceFactory.createService(LocalJaxRpcServiceFactory.java:295)
This suggests that JSSE isn't installed or configured, but I can write a straight java app that uses an Axis/JaxRpc apps.
I've googled my last google trying to find ANYTHING about this, but nothing...
I'm lost for any ideas. HELP! I swear! I'll shoot something! (I don't want to, its a nice machine!)
mands.PaymentInfoCommandlt;/valuegt;lt;/propertygt;
lt;property name=quot;commandNamequot;gt;lt;valuegt;paymentInfoCmdlt;/valuegt;lt;/propertygt;
lt;property name=quot;validatorquot; ref=quot;registrationControllerquot;/gt;
lt;property name=quot;sessionFormquot;gt;lt;valuegt;falselt;/valuegt;lt;/propertygt;
lt;property name=quot;paymentServicequot; ref=quot;paymentClientquot;/gt;
lt;property name=quot;emailUtilquot; ref=quot;emailUtilquot;/gt; lt;/beangt; lt;bean id=quot;viewResolverquot; class=quot;org..web.servlet.view.InternalResourceViewResolverquot;gt; lt;property name=quot;viewClassquot;gt;lt;valuegt;org..web.servlet.view.JstlViewlt;/valuegt;lt;/propertygt; lt;property name=quot;prefixquot;gt;lt;valuegt;/WEB-INF/jsp/lt;/valuegt;lt;/propertygt; lt;property name=quot;suffixquot;gt;lt;valuegt;.jsplt;/valuegt;lt;/propertygt; lt;/beangt;
lt;/beansgt;
AxisPaymentServicePortProxyFactory.java
Code:
package org.app.clients;
import javax.xml.namespace.QName;
import javax.xml.rpc.Service;
import org.apache.axis.encoding.TypeMapping;
import org.apache.axis.encoding.TypeMappingRegistry;
import org.apache.axis.encoding.ser.BeanDeserializerFactory;
import org.apache.axis.encoding.ser.BeanSerializerFactory;
import org..remoting.jaxrpc.JaxRpcPortProxyFactoryBean;
import org.service.payment.shared.BillingPaymentInfo;
import org.service.payment.shared.CreditCardPaymentInfo;
import org.service.payment.shared.CustomField;
import org.service.payment.shared.ECheckPaymentInfo;
import org.service.payment.shared.Order;
import org.service.payment.shared.PaymentInfo;
import org.service.payment.shared.ProductLineItem;
import org.service.payment.shared.Response;
import org.service.payment.shared.State;
import org.service.payment.shared.StateHistory;
import org.service.payment.shared.ValidationResult;
public class AxisPaymentServicePortProxyFactoryBean extends JaxRpcPortProxyFactoryBean {
protected void postProcessJaxRpcService(Service service) {
TypeMappingRegistry registry = (TypeMappingRegistry) service.getTypeMappingRegistry();
TypeMapping mapping = (TypeMapping) registry.createTypeMapping();
registerBeanMapping(mapping, ValidationResult.class,quot;ValidationResultquot;);
registerBeanMapping(mapping, PaymentInfo.class,quot aymentInfoquot;);
registerBeanMapping(mapping, BillingPaymentInfo.class,quot;BillingPaymentInfoquot;);
registerBeanMapping(mapping, ECheckPaymentInfo.class,quot;ECheckPaymentInfoquot;);
registerBeanMapping(mapping, CreditCardPaymentInfo.class,quot;CreditCardPaymentInfoquot;);
registerBeanMapping(mapping, CustomField.class,quot;CustomFieldquot;);
registerBeanMapping(mapping, ProductLineItem.class,quot roductLineItemquot;);
registerBeanMapping(mapping, State.class,quot;Statequot;);
registerBeanMapping(mapping, StateHistory.class,quot;StateHistoryquot;);
registerBeanMapping(mapping, Order.class,quot;Orderquot;);
registerBeanMapping(mapping, Response.class,quot;Responsequot;);
registry.register(quot;soap/encoding/quot;, mapping);
}
protected void registerBeanMapping(TypeMapping mapping, Class type, String name) {
QName qName = new QName(quot;payment/quot;, name);
mapping.register(type, qName, new BeanSerializerFactory(type, qName), new BeanDeserializerFactory(type, qName));
}
}
PaymentService.java
Code:
package org.app.clients;
import org.service.payment.shared.Order;
import org.service.payment.shared.Response;
public interface PaymentService {
public Response authcapture(Order order);
public Response validate(Order order);
} |
|