BusinessFaultException

BusinessFaultException

以下代码段:

static void listComposites(Locator myLocator) throws Exception {
        ExecutorService myExecutor = Executors.newFixedThreadPool(10);
        try {
                List<CompositeDN> compositesDN = getCompositesDN(myLocator);

                System.out.println("Pippo");

                for (CompositeDN myCompositeDN : compositesDN) {
                    System.out.println("Pluto");
                    Composite composite = myLocator.lookupComposite(myCompositeDN.toString());
                    System.out.println("Paperino");
                    System.out.println("Composite = " + composite);
                    System.out.println("Mode: " + composite.getMode() + " state: " + composite.getState());
                }

                List<Composite> composites = getComposites(myLocator);
            System.out.println("Composites: " + composites.size());
            /*
            for (Composite myComposite : composites) {
                System.out.println("Processing " + myComposite.toString());
                System.out.println("CompositeDN " + myComposite.getCompositeDN().toString());
                System.out.println("Processing: " + myComposite.getCompositeDN().toString() + " instances " +
                                   myComposite.getInstanceCount());
//                try {
//                    Runnable myRunnable =
//                        new CompositeInstancePurgerRunnable(myComposite, getCompositeInstanceFilter());
//                   // myExecutor.execute(myRunnable);
//                } catch (Exception e) {
//                    System.out.println("\tError during purge instances: " + getStacktrace(e));
//                }
            }
            */
        } catch (Exception e) {
            System.out.println("\tError during list composites: " + getStacktrace(e));
        }
        myExecutor.shutdown();

    }


引发异常java.lang.ClassNotFoundException: oracle.fabric.common.BusinessFaultException

这是此段的输出:

Pippo
Pluto
Error during list composites: java.lang.ClassNotFoundException: oracle.fabric.common.BusinessFaultException
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
...


不知道我的类路径中是否缺少某些内容,或者我做错了什么。

最佳答案

似乎您缺少包含fabric-common.jarBusinessFaultException

通常,您需要包括以下罐子:

xmlparserv2
weblogic remote client
SOAMiddleware\jdeveloper\soa\modules\oracle.soa.mgmt_11.1.1\soa-infra-mgmt.jar
SOAMiddleware\oracle_common\modules\oracle.fabriccommon_11.1.1\fabric-common.jar
SOAMiddleware\jdeveloper\soa\modules\oracle.soa.fabric_11.1.1\fabric-client.jar
SOAMiddleware\jdeveloper\soa\modules\oracle.soa.fabric_11.1.1\fabric-ext.jar
SOAMiddleware\jdeveloper\soa\modules\oracle.soa.fabric_11.1.1\fabric-runtime.jar
SOAMiddleware\jdeveloper\soa\modules\oracle.soa.fabric_11.1.1\oracle-soa-client-api.jar
SOAMiddleware\jdeveloper\soa\modules\oracle.soa.fabric_11.1.1\oracle.soa.fabric.jar


http://biemond.blogspot.com/2009/11/calling-soa-suite-direct-binding.html

08-05 03:12