【问题标题】:Exception in integration of banking api银行 api 集成异常
【发布时间】:2012-06-05 06:07:14
【问题描述】:

这是一个要求我检查的异常。在对 ICICI 银行进行 API 集成时引发了此异常。

java.lang.Exception:CreateInstance 失败:新 com.opus.epg.sfa.java.BillToAddress

参考网址:http://kndexim.com/java/SFAClient/TestPages/TestSsl.php

我基本上是一名 J2EE 开发人员,我对 php 和 .我知道这与一些类路径问题有关。我能得到一个解决方案吗?如果我的问题不清楚,请询问我将提供更多详细信息。

web.xml 文件内容如下

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">

<web-app>
    <!-- support for Java EE cluster, remove this line if you want to put non-serializable objects into the java_session() -->
    <distributable/>

    <!-- Your system PHP executable. Default is /usr/bin/php-cgi or c:/Program Files/PHP/php-cgi.exe -->  
    <!--<context-param><param-name>php_exec</param-name><param-value>php-cgi</param-value></context-param>-->
    <!-- Prefer a system PHP executable, if available. Otherwise use the PHP from the .war file. Default is Off -->
    <context-param><param-name>prefer_system_php_exec</param-name><param-value>On</param-value></context-param>

    <!-- Handle PHP urls which cannot be expressed using a standard servlet spec 2.2 url-pattern, 
         e.g.: *.php/delete/from?what=that You may remove this and the filter-mapping below -->
    <filter><filter-name>PhpCGIFilter</filter-name><filter-class>php.java.servlet.PhpCGIFilter</filter-class></filter>
    <filter-mapping><filter-name>PhpCGIFilter</filter-name><url-pattern>/*</url-pattern></filter-mapping>

    <!-- Attach the JSR223 script factory to the servlet context -->
    <listener><listener-class>php.java.servlet.ContextLoaderListener</listener-class></listener>

    <!-- PHP Servlet: back-end for Apache or IIS -->
    <servlet><servlet-name>PhpJavaServlet</servlet-name><servlet-class>php.java.servlet.PhpJavaServlet</servlet-class></servlet>

    <!-- PHP CGI servlet: when IIS or Apache are not available -->
    <servlet><servlet-name>PhpCGIServlet</servlet-name><servlet-class>php.java.servlet.fastcgi.FastCGIServlet</servlet-class></servlet>

    <!-- PHP Servlet Mapping -->
    <servlet-mapping><servlet-name>PhpJavaServlet</servlet-name><url-pattern>*.phpjavabridge</url-pattern></servlet-mapping>

    <!-- PHP CGI Servlet Mapping -->
    <servlet-mapping><servlet-name>PhpCGIServlet</servlet-name><url-pattern>*.php</url-pattern></servlet-mapping>

    <!-- Welcome files -->
    <welcome-file-list>
        <welcome-file>index.php</welcome-file>
    </welcome-file-list>

</web-app>

【问题讨论】:

  • 是否应该包含servlet.jar、servlet-api.jar?

标签: java php exception


【解决方案1】:

有一个 ClassNotFoundException。典型原因是 jar 丢失。

尝试查找此类 com.opus.epg.sfa.java.BillToAddress 并将类/jar 包含在类路径中。

【讨论】:

    【解决方案2】:

    WebappClassLoader 没有在其中定义类 com.opus.epg.sfa.java.BillToAddress

    您应该确保包含该类的 jar 包含在类路径中,一旦这样做,请使用 java_require('someJar.jar') 将其包含到您的类路径中。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2014-12-06
      • 2017-10-18
      • 1970-01-01
      • 1970-01-01
      • 2017-09-19
      • 1970-01-01
      • 1970-01-01
      • 2016-06-15
      相关资源
      最近更新 更多