Log4j:ERROR Could not instantiate class [org.jboss.logging.util.OnlyOnceErr

Hi,
when i run my standalone application i am getting following error:
I am using log4j-1.2.15.jar file.
log4j:ERROR Could not instantiate class [org.jboss.logging.util.OnlyOnceErrorHandler].
java.lang.ClassNotFoundException: org.jboss.logging.util.OnlyOnceErrorHandler
     at java.net.URLClassLoader$1.run(URLClassLoader.java:199)
     at java.security.AccessController.doPrivileged(Native Method)
     at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
     at java.lang.ClassLoader.loadClass(ClassLoader.java:289)
     at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:274)
     at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
     at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
     at java.lang.Class.forName0(Native Method)
     at java.lang.Class.forName(Class.java:141)
     at org.apache.log4j.helpers.Loader.loadClass(Loader.java:179)
     at org.apache.log4j.helpers.OptionConverter.instantiateByClassName(OptionConverter.java:320)
     at org.apache.log4j.xml.DOMConfigurator.parseErrorHandler(DOMConfigurator.java:302)
     at org.apache.log4j.xml.DOMConfigurator.parseAppender(DOMConfigurator.java:266)
     at org.apache.log4j.xml.DOMConfigurator.findAppenderByName(DOMConfigurator.java:171)
     at org.apache.log4j.xml.DOMConfigurator.findAppenderByReference(DOMConfigurator.java:184)
     at org.apache.log4j.xml.DOMConfigurator.parseChildrenOfLoggerElement(DOMConfigurator.java:502)
     at org.apache.log4j.xml.DOMConfigurator.parseRoot(DOMConfigurator.java:471)
     at org.apache.log4j.xml.DOMConfigurator.parse(DOMConfigurator.java:921)
     at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:790)
     at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:696)
     at org.apache.log4j.helpers.OptionConverter.selectAndConfigure(OptionConverter.java:471)
     at org.apache.log4j.LogManager.<clinit>(LogManager.java:125)
     at org.apache.log4j.Logger.getLogger(Logger.java:105)
     at com.DSA.common.offline.batchjob.Job.<clinit>(Job.java:37)
log4j:ERROR Could not create an Appender. Reported error follows.
java.lang.ClassNotFoundException: org.jboss.logging.appender.DailyRollingFileAppender
     at java.net.URLClassLoader$1.run(URLClassLoader.java:199)
     at java.security.AccessController.doPrivileged(Native Method)
     at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
     at java.lang.ClassLoader.loadClass(ClassLoader.java:289)
     at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:274)
     at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
     at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
     at java.lang.Class.forName0(Native Method)
     at java.lang.Class.forName(Class.java:141)
     at org.apache.log4j.helpers.Loader.loadClass(Loader.java:179)

solved by adding file
jboss-common.jar. to the classpath

Similar Messages

  • ERROR Could not instantiate class [org.jboss.logging.util.OnlyOnceErrorHand

    Hi,
    when i run my standalone application i am getting following error:
    I am using log4j-1.2.15.jar file.
    log4j:ERROR Could not instantiate class [org.jboss.logging.util.OnlyOnceErrorHandler].
    java.lang.ClassNotFoundException: org.jboss.logging.util.OnlyOnceErrorHandler
         at java.net.URLClassLoader$1.run(URLClassLoader.java:199)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:289)
         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:274)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java:141)
         at org.apache.log4j.helpers.Loader.loadClass(Loader.java:179)
         at org.apache.log4j.helpers.OptionConverter.instantiateByClassName(OptionConverter.java:320)
         at org.apache.log4j.xml.DOMConfigurator.parseErrorHandler(DOMConfigurator.java:302)
         at org.apache.log4j.xml.DOMConfigurator.parseAppender(DOMConfigurator.java:266)
         at org.apache.log4j.xml.DOMConfigurator.findAppenderByName(DOMConfigurator.java:171)
         at org.apache.log4j.xml.DOMConfigurator.findAppenderByReference(DOMConfigurator.java:184)
         at org.apache.log4j.xml.DOMConfigurator.parseChildrenOfLoggerElement(DOMConfigurator.java:502)
         at org.apache.log4j.xml.DOMConfigurator.parseRoot(DOMConfigurator.java:471)
         at org.apache.log4j.xml.DOMConfigurator.parse(DOMConfigurator.java:921)
         at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:790)
         at org.apache.log4j.xml.DOMConfigurator.doConfigure(DOMConfigurator.java:696)
         at org.apache.log4j.helpers.OptionConverter.selectAndConfigure(OptionConverter.java:471)
         at org.apache.log4j.LogManager.<clinit>(LogManager.java:125)
         at org.apache.log4j.Logger.getLogger(Logger.java:105)
         at com.DSA.common.offline.batchjob.Job.<clinit>(Job.java:37)
    log4j:ERROR Could not create an Appender. Reported error follows.
    java.lang.ClassNotFoundException: org.jboss.logging.appender.DailyRollingFileAppender
         at java.net.URLClassLoader$1.run(URLClassLoader.java:199)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:187)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:289)
         at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:274)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:235)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302)
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java:141)
         at org.apache.log4j.helpers.Loader.loadClass(Loader.java:179)

    My property file is given below:
    what i need to change here?
    log4j.rootLogger=FATAL, dest1
    log4j.logger.dsaLogging=DEBUG, dsa
    log4j.additivity.dsaLogging=false
    log4j.appender.dest1=org.apache.log4j.ConsoleAppender
    log4j.appender.dest1.layout=org.apache.log4j.PatternLayout
    log4j.appender.dest1.layout.ConversionPattern=%-5p:%l: %m%n
    log4j.appender.dest1.ImmediateFlush=true
    log4j.appender.dsa=org.apache.log4j.RollingFileAppender
    log4j.appender.dsa.File=./logs/dsa.log
    log4j.appender.dsa.MaxFileSize=2000KB
    # Previously MaxBackupIndex=2
    log4j.appender.dsa.MaxBackupIndex=5
    log4j.appender.dsa.layout=org.apache.log4j.PatternLayout
    log4j.appender.dsa.layout.ConversionPattern=%l:%d: %m%n

  • Log4j:ERROR Could not instantiate configurator

    I use
    -Dlog4j.configuratorClass=mypackage.Log4jConfigurator
    java option in startWeblogic command file
    to read changes in log4j-config.xml.
    After that I have in console.log
    og4j:ERROR A "mypackage.Log4jConfigurator" object is not assignable to a "org.apache.log4j.spi.Configurator" variable.
    log4j:ERROR The class "org.apache.log4j.spi.Configurator" was loaded by
    log4j:ERROR [weblogic.utils.classloaders.GenericClassLoader@544b02 finder: weblogic.utils.classloaders.CodeGenClassFinder@a0e9d7 annotatio
    n: consoleapp@] whereas object of type
    log4j:ERROR "mypackage.Log4jConfigurator" was loaded by [sun.misc.Launcher$AppClassLoader@12498b5].
    log4j:ERROR Could not instantiate configurator [mypackage.Log4jConfigurator].
    Could anybody help?

    Did you get a resolution? I have a similar problem with a different object, org.apache.log4j.spi.TriggeringEventEvaluator, which has been loaded by the Weblogic consoleapp. I am running in a standalone server configuration -- admin and application server are the same. Also, using exploded directories.
    Is there a way to prevent the WebLogic classloader from loading its version from the consoleapp?

  • An XJC compilation error - Could not load class (..) for type cvsversion

    I've got a strange compilation error using NetBeans 4.0 (I'd guess the version does not matter here) and Ant 1.6.2. When the following task is executed,
    <target name="compile_ofx_schema">
    <antcall target="clean-ofx"/>
    <delete dir="${ofx-jaxb-src.dir}"/>
    <mkdir dir="${ofx-jaxb-src.dir}" />
    <xjc schema="${schema.dir}/ofx102.xsd" package="com.xxx.ofx102" target="${ofx-jaxb-src.dir}">
    <arg value="-nv" />
    <arg value="-extension" />
    </xjc>
    </target>
    I get the error from NetBeans console,
    Class org.xml.sax.SAXException loaded from parent loader (parentFirst)
    Class java.io.IOException loaded from parent loader (parentFirst)
    D:\appserver\build.xml:797: unable to parse the schema. Error messages should have been provided
    at com.sun.tools.xjc.XJCTask._doXJC(XJCTask.java:334)
    at com.sun.tools.xjc.XJCTask.doXJC(XJCTask.java:283)
    at com.sun.tools.xjc.XJCTask.execute(XJCTask.java:227)
    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
    at org.apache.tools.ant.Task.perform(Task.java:364)
    at org.apache.tools.ant.Target.execute(Target.java:341)
    at org.apache.tools.ant.Target.performTasks(Target.java:369)
    at org.apache.tools.ant.Project.executeTarget(Project.java:1214)
    at org.apache.tools.ant.Project.executeTargets(Project.java:1062)
    at org.apache.tools.ant.module.bridge.impl.BridgeImpl.run(BridgeImpl.java:217)
    at org.apache.tools.ant.module.run.TargetExecutor.run(TargetExecutor.java:236)
    at org.netbeans.core.execution.RunClassThread.run(RunClassThread.java:125)
    BUILD FAILED (total time: 4 seconds)
    Could not load class (org.apache.tools.ant.tasksdefs.cvslib.CvsVersion) for type cvsversion
    Could not load class (org.apache.tools.ant.tasksdefs.cvslib.CvsVersion) for type cvsversion
    And when I run the Ant task from the command line, I don't get the error at all.
    Any help is greatly appreciated.

    That was a great finding from you. Thank you.
    I followed your alternative approach and updated the ant.jar file. The "Could not load class..." error went away but the stack trace still remains. Now I am clueless again since I have ant on the debug mode and can't find any more useful info.
    Class com.sun.tools.xjc.reader.internalizer.LocatorTable loaded from ant loader (parentFirst)
    Class java.util.HashSet loaded from parent loader (parentFirst)
    Class javax.xml.parsers.DocumentBuilderFactory loaded from parent loader (parentFirst)
    Couldn't load Resource org/netbeans/core/xml/DOMFactoryImpl.class
    Couldn't load ResourceStream for META-INF/services/javax.xml.parsers.DocumentBuilderFactory
    Class org.apache.crimson.jaxp.DocumentBuilderFactoryImpl loaded from parent loader (parentFirst)
    Class javax.xml.parsers.SAXParserFactory loaded from parent loader (parentFirst)
    Couldn't load Resource org/netbeans/core/xml/SAXFactoryImpl.class
    Couldn't load ResourceStream for META-INF/services/javax.xml.parsers.SAXParserFactory
    Class org.apache.crimson.jaxp.SAXParserFactoryImpl loaded from parent loader (parentFirst)
    Class javax.xml.parsers.DocumentBuilder loaded from parent loader (parentFirst)
    Class java.util.Map loaded from parent loader (parentFirst)
    Class javax.xml.parsers.SAXParser loaded from parent loader (parentFirst)
    Finding class com.sun.tools.xjc.reader.xmlschema.parser.XMLSchemaInternalizationLogic$ReferenceFinder
    Loaded from D:\bbw\build\Common_3.6\Packaged\appserver\lib\jaxb\jaxb-xjc.jar com/sun/tools/xjc/reader/xmlschema/parser/XMLSchemaInternalizationLogic$ReferenceFinder.class
    Finding class com.sun.tools.xjc.reader.internalizer.AbstractReferenceFinderImpl
    Loaded from D:\bbw\build\Common_3.6\Packaged\appserver\lib\jaxb\jaxb-xjc.jar com/sun/tools/xjc/reader/internalizer/AbstractReferenceFinderImpl.class
    Class org.xml.sax.helpers.XMLFilterImpl loaded from parent loader (parentFirst)
    Class com.sun.tools.xjc.reader.internalizer.AbstractReferenceFinderImpl loaded from ant loader (parentFirst)
    Class com.sun.tools.xjc.reader.xmlschema.parser.XMLSchemaInternalizationLogic$ReferenceFinder loaded from ant loader (parentFirst)
    Class org.xml.sax.XMLFilter loaded from parent loader (parentFirst)
    Finding class com.sun.tools.xjc.reader.internalizer.VersionChecker
    Loaded from D:\bbw\build\Common_3.6\Packaged\appserver\lib\jaxb\jaxb-xjc.jar com/sun/tools/xjc/reader/internalizer/VersionChecker.class
    Class com.sun.tools.xjc.reader.internalizer.VersionChecker loaded from ant loader (parentFirst)
    Finding class com.sun.tools.xjc.reader.internalizer.DOMBuilder
    Loaded from D:\bbw\build\Common_3.6\Packaged\appserver\lib\jaxb\jaxb-xjc.jar com/sun/tools/xjc/reader/internalizer/DOMBuilder.class
    Finding class com.sun.xml.bind.marshaller.SAX2DOMEx
    Loaded from D:\bbw\build\Common_3.6\Packaged\appserver\lib\jaxb\jaxb-impl.jar com/sun/xml/bind/marshaller/SAX2DOMEx.class
    Class org.xml.sax.ContentHandler loaded from parent loader (parentFirst)
    Class com.sun.xml.bind.marshaller.SAX2DOMEx loaded from ant loader (parentFirst)
    Class com.sun.tools.xjc.reader.internalizer.DOMBuilder loaded from ant loader (parentFirst)
    Class java.util.Stack loaded from parent loader (parentFirst)
    Class org.w3c.dom.Document loaded from parent loader (parentFirst)
    Class org.xml.sax.XMLReader loaded from parent loader (parentFirst)
    Class org.w3c.dom.Node loaded from parent loader (parentFirst)
    Class org.w3c.dom.Element loaded from parent loader (parentFirst)
    Class javax.xml.parsers.ParserConfigurationException loaded from parent loader (parentFirst)
    Class org.xml.sax.SAXException loaded from parent loader (parentFirst)
    Class java.io.IOException loaded from parent loader (parentFirst)
    D:\bbw\build\Common_3.6\Packaged\appserver\build.xml:799: unable to parse the schema. Error messages should have been provided
    at com.sun.tools.xjc.XJCTask._doXJC(XJCTask.java:334)
    at com.sun.tools.xjc.XJCTask.doXJC(XJCTask.java:283)
    at com.sun.tools.xjc.XJCTask.execute(XJCTask.java:227)
    at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:275)
    at org.apache.tools.ant.Task.perform(Task.java:364)
    at org.apache.tools.ant.Target.execute(Target.java:341)
    at org.apache.tools.ant.Target.performTasks(Target.java:369)
    at org.apache.tools.ant.Project.executeTarget(Project.java:1214)
    at org.apache.tools.ant.Project.executeTargets(Project.java:1062)
    at org.apache.tools.ant.module.bridge.impl.BridgeImpl.run(BridgeImpl.java:217)
    at org.apache.tools.ant.module.run.TargetExecutor.run(TargetExecutor.java:236)
    at org.netbeans.core.execution.RunClassThread.run(RunClassThread.java:125)
    BUILD FAILED (total time: 1 second)
    Any suggestions? BTW, I did not upgrade NetBeans to v5.5 due that my code is still JDK1.4 based.

  • Error: Could not find compiled resource bundle 'logging' for locale 'fr_FR'

    Hello
    I'm developping a mobile application based on Flex  4.6 + Adobe AIR 3.5
    There is no error when compiling, but when the application starts it crashes whith this error message:
    Error: Could not find compiled resource bundle 'logging' for locale 'fr_FR'.
      at mx.resources::ResourceManagerImpl/installCompiledResourceBundle()[E:\dev\4.y\frameworks\p rojects\framework\src\mx\resources\ResourceManagerImpl.as:392]
      at mx.resources::ResourceManagerImpl/installCompiledResourceBundles()[E:\dev\4.y\frameworks\ projects\framework\src\mx\resources\ResourceManagerImpl.as:306]
      at mx.resources::ResourceManagerImpl/processInfo()[E:\dev\4.y\frameworks\projects\framework\ src\mx\resources\ResourceManagerImpl.as:450]
      at mx.resources::ResourceManagerImpl()[E:\dev\4.y\frameworks\projects\framework\src\mx\resou rces\ResourceManagerImpl.as:133]
      at mx.resources::ResourceManager$/getInstance()[E:\dev\4.y\frameworks\projects\framework\src \mx\resources\ResourceManager.as:117]
      at mx.styles::StyleManagerImpl()[E:\dev\4.y\frameworks\projects\framework\src\mx\styles\Styl eManagerImpl.as:380]
      at _ASMagnetoFute_iOS_FlexInit$/init()
      at mx.managers::SystemManager/http://www.adobe.com/2006/flex/mx/internal::kickOff()[E:\dev\4.y\frameworks\projects\framework\src\mx\managers\SystemManager.as:2815]
      at mx.managers::SystemManager/http://www.adobe.com/2006/flex/mx/internal::preloader_completeHandler()[E:\dev\4.y\frameworks\projects\framework\src\mx\managers\SystemManager.as:2723]
      at flash.events::EventDispatcher/dispatchEventFunction()
      at flash.events::EventDispatcher/dispatchEvent()
      at mx.preloaders::Preloader/timerHandler()[E:\dev\4.y\frameworks\projects\framework\src\mx\p reloaders\Preloader.as:542]
      at flash.utils::Timer/_timerDispatch()
      at flash.utils::Timer/tick()
    The application is in french, both for iOS and Android.
    It is split in several libs, an application for iOS and another one for android.
    I use the same SDK for another mobile application without any problem -but it does not use the mx.logging package.
    I tried many things, like the solution described in http://forums.adobe.com/thread/758619, but it did not solve the problem. After listing the bundles used I added
    -include-resource-bundles=MagnetoFute,collections,components,core,effects,fiber,layout,log ging,messaging,rpc,serializer,skins,sparkEffects,styles,textLayout,utils,validators
    to my compiler arguments.
    Help would be greatly appreciated.

    I don't know if Adobe has an fr_FR locale for the logging bundle.  You can try creating your own to see if that is the only one missing or if there is a whole resource swc missing.

  • What does the error "Could not load class!" mean?

    I've just loaded Lookout 6.1 on a new computer and have tried to load a process file onto it.  I'm getting the error messages: "Could not load class!" and "Error running process file!" I can take the same process file and load it onto a different computer with no problems.  What should I look for?

    The direct logic driver WILL NOT work with Windows 7, and Automation Direct says they are not upgrading the driver to work with windows 7 .
    We are in the process of moving to NIOPC Servers for our DirectLogic PLCs. So far, the move has been going well.
    Jason Phillips

  • CFReport Error: Could not initialize class coldfusion.runtime.report.Report

    We are running a multi-installation set up of CF8. We have
    two instances - one we use for Flex applications, and one for basic
    CF applications. We have a complex report that needs to run on the
    Flex instance, which caused the above error. I went on to create a
    basic report from the wizard, and got the same error message. I
    then created a basic report from the wizard, and put it on the
    other instance, and WHAM - everything works just perfectly. I've
    tried a basic report using every datasource at my disposal on the
    Flex instance, and same error every time.
    As far as I can confirm from out Systems Administrator is
    that when the instances were created, they were identical to each
    other, and the only difference is that we enabled the flex
    parameters on the Flex instance. Does anyone have any ideas on what
    could be the problem, and what we can do about it?
    Thanks!
    Jenn

    Can you clarify what you mean by "the services restarted but failed to initialize the server"?  Sometimes the CF service (via Windows Services) will actually say "Starting..." instead of "Started".  Is this what you see?  Regardles, is "RequestMonitorEventProcess" is the only thing the .bat file reported?
    A few other things to check:
    Check your neo-runtime.xml file to make sure it looks legit, and check your jvm.config to make sure it's pointing to where your Java engine is.  Make sure your JVM max memory allocation is not more than 1024mb if you are on a 32-bit machine.
    Sounds like a Java problem overall, as in maybe the path is wrong or the version is wrong or the allocation is too high.  Did you recently try to update it or make any other config changes like that?

  • Javah error: could not find class file for 'com.ntv.ndkjni'

    Hi,
    My project directory  : C:\ndkJNI
    My java file directory : C:\ndkJNI\src\com\ntv\ndkjni
    My package name    : com.ntv.ndkjni
    1 ) I entry command prompt at C:\ndkJNI\src\com\ntv\ndkjni
    2 ) Javac test.java and create test.class succesfully. test.class is in  C:\ndkJNI\src\com\ntv\ndkjni folder.
    3 ) Later I used Javah, try below javah variously
         a)  javah -classpath C:\ndkJNI\src\com\ntv\ndkjni test
         b)  javah -classpath C:\ndkJNI\src\com\ntv\ndkjni.test
         x) javah -classpath C:\ndkJNI\src\com\ntv\ndkjni com.ntv.ndkjni.test
         y) javah -classpath C:\ndkJNI\src\com\ntv\ndkjni com.ntv.ndkjni test
         c)  javah -classpath C:\ndkJNI\src\com\ntv\ndkjni com.ntv.ndkjni.test
         d)  javah  com.ntv.ndkjni.test
         e) javah  com.ntv.ndkjni test
         f) javah  com.ntv.ndkjni test.class-> (error: exception in a thread illegal argument exception)
    I am searching  for 5 day. I couldnt find solution. I try different computer. I tried ubuntu and win8, the error still with me.
    Thats interesting when I delete the package com.ntv.ndkjni; from java file,  then create class file again with javac then javah can create header file succesfully.
    Please help me.
    *****************************test.java**************************
    package com.ntv.ndkjni;
    public class test {
      static
      System.loadLibrary("hello");
        public static native int toplama(int sayi1,int sayi2);

    javah takes a fully qualified class name so in your case that would be
    com.ntv.ndkjni.test
    As with all things related to java the class path is used to resolve the class based on the fully qualified name.  The name resolves STARTING at the path and then attempts to find the class BELOW the classpath by resolving the name.
    Because of that your class path should be the following
    C:\ndkJNI\src

  • SOAP Axis - Could not initialize class OperationDesc error in Receiver SOAP

    Hi,
    We are facing a issue in receiver soap scenario with NTLM Authentication.
    We have deployed the necessary jar files needed for Axis framework. But we are geting an error 'Could not initialize class org.apache.axis.description.OperationDesc'.
    Any idea how to overcome this error?
    Edited by: Aarthi on Apr 27, 2010 8:29 AM

    Yes. I checked.
    In addition to the mandatory files, we have deployed the below 3 files for NTLM.
    Jakarta-Commons Codec
    Found: org.apache.commons.codec.Encoder at D:\usr\sap\DGX\DVEBMGS00\j2ee\cluster\bin\ext\com.sap.aii.af.axisproviderlib\lib\commons-codec-1.3.jar
    Jakarta-Commons Net
    Found: org.apache.commons.net.SocketFactory at D:\usr\sap\DGX\DVEBMGS00\j2ee\cluster\bin\ext\com.sap.aii.af.axisproviderlib\lib\commons-net-1.0.0-dev.jar
    Jakarta-Commons HttpClient
    Found: org.apache.commons.codec.Encoder at D:\usr\sap\DGX\DVEBMGS00\j2ee\cluster\bin\ext\com.sap.aii.af.axisproviderlib\lib\commons-codec-1.3.jar

  • Ejb error((MARSHAL) Could not find class) when using OneToMany relationship

    I am using Netbeans 5.5 with J2EE App Server 9. I have two entity beans with a OneToMany Uni-directional relationship. I have a Remote Stateless session bean which has persistence operations for creating and searching etc.. I am accessing the remote bean via jndi from a j2ee java client. The access works fine. The session bean persist operation creates data in both the entities (cascade persist).
    But, after the data is created, when I access the entity manager find() method from the session bean via the client errors out. This error only happens for the entities with OneToMany relationship, not for OneToOne relationships.
    I am using TOPLINK persistence provider accessing a derby data source. I have the latest persistence library jar files in the library classpath.
    client code:
                Phone p1 = new Phone();
                p1.setPnumber("999 999 9999");
                Customer c1 = new Customer();
                c1.setLname("Smith");
                c1.getPhone().add(p1);
                int pk = agent.createCustomer(c1);    // creates the entities
                Customer c2 = agent.findCustomer(pk);     //  this causes the ERROR
    session bean code:
       @PersistenceContext  private EntityManager em;
        public int createCustomer(Customer c) {
            em.persist(c);
            return c.getId();
        public Customer findCustomer(int i) {          // this causes the ERROR
            return em.find(Customer.class, i);
    exception:
    Mar 30, 2007 3:25:00 PM com.sun.corba.ee.impl.encoding.CDRInputStream_1_0 read_value
    WARNING: "IOP00810257: (MARSHAL) Could not find class"
    org.omg.CORBA.MARSHAL: vmcid: SUN minor code: 257 completed: Maybe
    at com.sun.corba.ee.impl.logging.ORBUtilSystemException.couldNotFindClass(ORBUtilSystemException.java:8309)
    at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_value(CDRInputStream_1_0.java:984)
    at com.sun.corba.ee.impl.encoding.CDRInputStream.read_value(CDRInputStream.java:259)
    at com.sun.corba.ee.impl.io.IIOPInputStream.inputObjectField(IIOPInputStream.java:1987)
    at com.sun.corba.ee.impl.io.IIOPInputStream.inputClassFields(IIOPInputStream.java:2211)
    at com.sun.corba.ee.impl.io.IIOPInputStream.inputObject(IIOPInputStream.java:1219)
    at com.sun.corba.ee.impl.io.IIOPInputStream.simpleReadObject(IIOPInputStream.java:398)
    ***exception in Client_1 ***
    at com.sun.corba.ee.impl.io.ValueHandlerImpl.readValueInternal(ValueHandlerImpl.java:329)
    at com.sun.corba.ee.impl.io.ValueHandlerImpl.readValue(ValueHandlerImpl.java:295)
    at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_value(CDRInputStream_1_0.java:1005)
    at com.sun.corba.ee.impl.encoding.CDRInputStream.read_value(CDRInputStream.java:259)
    at com.sun.corba.ee.impl.presentation.rmi.DynamicMethodMarshallerImpl$14.read(DynamicMethodMarshallerImpl.java:333)
    at com.sun.corba.ee.impl.presentation.rmi.DynamicMethodMarshallerImpl.readResult(DynamicMethodMarshallerImpl.java:424)
    at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.privateInvoke(StubInvocationHandlerImpl.java:162)
    at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.invoke(StubInvocationHandlerImpl.java:119)
    at com.sun.corba.ee.impl.presentation.rmi.bcel.BCELStubBase.invoke(BCELStubBase.java:197)
    at com.titan.ejb.__Tester1Remote_Remote_DynamicStub.findCustomer(__Tester1Remote_Remote_DynamicStub.java)
    at com.titan.ejb._Tester1Remote_Wrapper.findCustomer(com.titan.ejb._Tester1Remote_Wrapper.java)
    at com.titan.clients.Client_1.main(Client_1.java:37)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at com.sun.enterprise.util.Utility.invokeApplicationMain(Utility.java:232)
    at com.sun.enterprise.appclient.MainWithModuleSupport.<init>(MainWithModuleSupport.java:329)
    at com.sun.enterprise.appclient.Main.main(Main.java:180)
    Caused by: java.lang.ClassNotFoundException
    ... 25 more
    javax.ejb.EJBException: nested exception is: java.rmi.MarshalException: CORBA MARSHAL 1398079745 Maybe; nested exception is:
    org.omg.CORBA.MARSHAL: vmcid: SUN minor code: 257 completed: Maybe
    java.rmi.MarshalException: CORBA MARSHAL 1398079745 Maybe; nested exception is:
    org.omg.CORBA.MARSHAL: vmcid: SUN minor code: 257 completed: Maybe
    at com.sun.corba.ee.impl.javax.rmi.CORBA.Util.mapSystemException(Util.java:224)
    at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.privateInvoke(StubInvocationHandlerImpl.java:172)
    at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.invoke(StubInvocationHandlerImpl.java:119)
    at com.sun.corba.ee.impl.presentation.rmi.bcel.BCELStubBase.invoke(BCELStubBase.java:197)
    at com.titan.ejb.__Tester1Remote_Remote_DynamicStub.findCustomer(__Tester1Remote_Remote_DynamicStub.java)
    at com.titan.ejb._Tester1Remote_Wrapper.findCustomer(com.titan.ejb._Tester1Remote_Wrapper.java)
    at com.titan.clients.Client_1.main(Client_1.java:37)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at com.sun.enterprise.util.Utility.invokeApplicationMain(Utility.java:232)
    at com.sun.enterprise.appclient.MainWithModuleSupport.<init>(MainWithModuleSupport.java:329)
    at com.sun.enterprise.appclient.Main.main(Main.java:180)
    Caused by: org.omg.CORBA.MARSHAL: vmcid: SUN minor code: 257 completed: Maybe
    at com.sun.corba.ee.impl.logging.ORBUtilSystemException.couldNotFindClass(ORBUtilSystemException.java:8309)
    at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_value(CDRInputStream_1_0.java:984)
    at com.sun.corba.ee.impl.encoding.CDRInputStream.read_value(CDRInputStream.java:259)
    at com.sun.corba.ee.impl.io.IIOPInputStream.inputObjectField(IIOPInputStream.java:1987)
    at com.sun.corba.ee.impl.io.IIOPInputStream.inputClassFields(IIOPInputStream.java:2211)
    at com.sun.corba.ee.impl.io.IIOPInputStream.inputObject(IIOPInputStream.java:1219)
    at com.sun.corba.ee.impl.io.IIOPInputStream.simpleReadObject(IIOPInputStream.java:398)
    at com.sun.corba.ee.impl.io.ValueHandlerImpl.readValueInternal(ValueHandlerImpl.java:329)
    at com.sun.corba.ee.impl.io.ValueHandlerImpl.readValue(ValueHandlerImpl.java:295)
    at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_value(CDRInputStream_1_0.java:1005)
    at com.sun.corba.ee.impl.encoding.CDRInputStream.read_value(CDRInputStream.java:259)
    at com.sun.corba.ee.impl.presentation.rmi.DynamicMethodMarshallerImpl$14.read(DynamicMethodMarshallerImpl.java:333)
    at com.sun.corba.ee.impl.presentation.rmi.DynamicMethodMarshallerImpl.readResult(DynamicMethodMarshallerImpl.java:424)
    at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.privateInvoke(StubInvocationHandlerImpl.java:162)
    ... 12 more
    Caused by: java.lang.ClassNotFoundException
    ... 25 more
    javax.ejb.EJBException: nested exception is: java.rmi.MarshalException: CORBA MARSHAL 1398079745 Maybe; nested exception is:
    org.omg.CORBA.MARSHAL: vmcid: SUN minor code: 257 completed: Maybe
    at com.titan.ejb._Tester1Remote_Wrapper.findCustomer(com.titan.ejb._Tester1Remote_Wrapper.java)
    at com.titan.clients.Client_1.main(Client_1.java:37)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Method.java:585)
    at com.sun.enterprise.util.Utility.invokeApplicationMain(Utility.java:232)
    at com.sun.enterprise.appclient.MainWithModuleSupport.<init>(MainWithModuleSupport.java:329)
    at com.sun.enterprise.appclient.Main.main(Main.java:180)

    It appears to be a bug in Netbeans.
    I have a similar error message with the following settings:
    A session bean remote interface
    be.macharis.toon.pacita.common.OriginFacadeRemoteA session bean implementing the remote interface
    be.macharis.toon.pacita.common.OriginFacadeAt deploying the ejb module, the session bean is loaded in the JNDI registry under the name be.macharis.toon.pacita.common.OriginFacadeRemote (the server log says so).
    I have the following code in a servlet:
    import javax.naming.Context;
    import javax.naming.InitialContext;
    import javax.naming.NamingException;
    try {
        Context ic = new InitialContext();
        OriginFacadeRemote originFacade = (OriginFacadeRemote)ic.lookup(OriginFacadeRemote.class.getName());
        originFacade.setOrigin(componentRegistry, OriginFacadeRemote.ELEMENT_CONTAINER); // <- exception here
    } catch (NamingException e) {
        e.printStackTrace();
    }Yet I get a java.lang.ClassNotFoundException during the EJB method call. The exception does not take place during execution of the method, but before, while the EJB container is still resolving the method. It thus must be a(nother) bug in the implementation of the EJB container.
    And bugs that are outside your control are so much harder to deal with... There was another bug in the EJB container for serialising complex object that I could work around by explicitly serialising the Objects myself to byte arrays. It took me 5 days to do so. I don't know if I will manage to work around this bug. If I do, I will post my solution. For completeness, below my "clarifying" error dump:
    javax.ejb.EJBException: nested exception is: java.rmi.MarshalException: CORBA MARSHAL 1398079745 Maybe; nested exception is:
         org.omg.CORBA.MARSHAL: ----------BEGIN server-side stack trace----------
    org.omg.CORBA.MARSHAL:   vmcid: SUN  minor code: 257 completed: Maybe
         at com.sun.corba.ee.impl.logging.ORBUtilSystemException.couldNotFindClass(ORBUtilSystemException.java:8309)
         at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_value(CDRInputStream_1_0.java:984)
         at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_value(CDRInputStream_1_0.java:850)
         at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_abstract_interface(CDRInputStream_1_0.java:844)
         at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_abstract_interface(CDRInputStream_1_0.java:834)
         at com.sun.corba.ee.impl.encoding.CDRInputStream.read_abstract_interface(CDRInputStream.java:275)
         at com.sun.corba.ee.impl.io.IIOPInputStream.readObjectDelegate(IIOPInputStream.java:361)
         at com.sun.corba.ee.impl.io.IIOPInputStream.readObjectOverride(IIOPInputStream.java:524)
         at java.io.ObjectInputStream.readObject(ObjectInputStream.java:345)
         at java.util.HashMap.readObject(HashMap.java:1029)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:597)
         at com.sun.corba.ee.impl.io.IIOPInputStream.invokeObjectReader(IIOPInputStream.java:1692)
         at com.sun.corba.ee.impl.io.IIOPInputStream.inputObject(IIOPInputStream.java:1210)
         at com.sun.corba.ee.impl.io.IIOPInputStream.simpleReadObject(IIOPInputStream.java:398)
         at com.sun.corba.ee.impl.io.ValueHandlerImpl.readValueInternal(ValueHandlerImpl.java:329)
         at com.sun.corba.ee.impl.io.ValueHandlerImpl.readValue(ValueHandlerImpl.java:295)
         at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_value(CDRInputStream_1_0.java:1005)
         at com.sun.corba.ee.impl.encoding.CDRInputStream.read_value(CDRInputStream.java:259)
         at com.sun.corba.ee.impl.io.IIOPInputStream.inputObjectField(IIOPInputStream.java:1987)
         at com.sun.corba.ee.impl.io.IIOPInputStream.inputClassFields(IIOPInputStream.java:2211)
         at com.sun.corba.ee.impl.io.IIOPInputStream.inputObject(IIOPInputStream.java:1219)
         at com.sun.corba.ee.impl.io.IIOPInputStream.simpleReadObject(IIOPInputStream.java:398)
         at com.sun.corba.ee.impl.io.ValueHandlerImpl.readValueInternal(ValueHandlerImpl.java:329)
         at com.sun.corba.ee.impl.io.ValueHandlerImpl.readValue(ValueHandlerImpl.java:295)
         at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_value(CDRInputStream_1_0.java:1005)
         at com.sun.corba.ee.impl.encoding.CDRInputStream.read_value(CDRInputStream.java:259)
         at com.sun.corba.ee.impl.io.IIOPInputStream.inputObjectField(IIOPInputStream.java:1987)
         at com.sun.corba.ee.impl.io.IIOPInputStream.inputClassFields(IIOPInputStream.java:2211)
         at com.sun.corba.ee.impl.io.IIOPInputStream.inputObject(IIOPInputStream.java:1219)
         at com.sun.corba.ee.impl.io.IIOPInputStream.simpleReadObject(IIOPInputStream.java:398)
         at com.sun.corba.ee.impl.io.ValueHandlerImpl.readValueInternal(ValueHandlerImpl.java:329)
         at com.sun.corba.ee.impl.io.ValueHandlerImpl.readValue(ValueHandlerImpl.java:295)
         at com.sun.corba.ee.impl.encoding.CDRInputStream_1_0.read_value(CDRInputStream_1_0.java:1005)
         at com.sun.corba.ee.impl.encoding.CDRInputStream.read_value(CDRInputStream.java:259)
         at com.sun.corba.ee.impl.presentation.rmi.DynamicMethodMarshallerImpl$14.read(DynamicMethodMarshallerImpl.java:333)
         at com.sun.corba.ee.impl.presentation.rmi.DynamicMethodMarshallerImpl.readArguments(DynamicMethodMarshallerImpl.java:393)
         at com.sun.corba.ee.impl.presentation.rmi.ReflectiveTie._invoke(ReflectiveTie.java:119)
         at com.sun.corba.ee.impl.protocol.CorbaServerRequestDispatcherImpl.dispatchToServant(CorbaServerRequestDispatcherImpl.java:650)
         at com.sun.corba.ee.impl.protocol.CorbaServerRequestDispatcherImpl.dispatch(CorbaServerRequestDispatcherImpl.java:193)
         at com.sun.corba.ee.impl.protocol.CorbaMessageMediatorImpl.handleRequestRequest(CorbaMessageMediatorImpl.java:1705)
         at com.sun.corba.ee.impl.protocol.SharedCDRClientRequestDispatcherImpl.marshalingComplete(SharedCDRClientRequestDispatcherImpl.java:154)
         at com.sun.corba.ee.impl.protocol.CorbaClientDelegateImpl.invoke(CorbaClientDelegateImpl.java:194)
         at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.privateInvoke(StubInvocationHandlerImpl.java:159)
         at com.sun.corba.ee.impl.presentation.rmi.StubInvocationHandlerImpl.invoke(StubInvocationHandlerImpl.java:119)
         at com.sun.corba.ee.impl.presentation.rmi.bcel.BCELStubBase.invoke(BCELStubBase.java:197)
         at be.macharis.toon.pacita.common.__OriginFacadeRemote_Remote_DynamicStub.setOrigin(__OriginFacadeRemote_Remote_DynamicStub.java)
         at be.macharis.toon.pacita.common._OriginFacadeRemote_Wrapper.setOrigin(be.macharis.toon.pacita.common._OriginFacadeRemote_Wrapper.java)
         at pacita.servlets.ContainerRegistry.processRequest(ContainerRegistry.java:64)
         at pacita.servlets.ContainerRegistry.doGet(ContainerRegistry.java:95)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:707)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
         at org.apache.catalina.core.ApplicationFilterChain.servletService(ApplicationFilterChain.java:397)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:278)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:536)
         at org.apache.catalina.core.StandardContextValve.invokeInternal(StandardContextValve.java:240)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:179)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
         at com.sun.enterprise.web.WebPipeline.invoke(WebPipeline.java:73)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:182)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
         at com.sun.enterprise.web.VirtualServerPipeline.invoke(VirtualServerPipeline.java:120)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:939)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:137)
         at org.apache.catalina.core.StandardPipeline.doInvoke(StandardPipeline.java:566)
         at org.apache.catalina.core.StandardPipeline.invoke(StandardPipeline.java:536)
         at org.apache.catalina.core.ContainerBase.invoke(ContainerBase.java:939)
         at org.apache.coyote.tomcat5.CoyoteAdapter.service(CoyoteAdapter.java:239)
         at com.sun.enterprise.web.connector.grizzly.ProcessorTask.invokeAdapter(ProcessorTask.java:667)
         at com.sun.enterprise.web.connector.grizzly.ProcessorTask.processNonBlocked(ProcessorTask.java:574)
         at com.sun.enterprise.web.connector.grizzly.ProcessorTask.process(ProcessorTask.java:844)
         at com.sun.enterprise.web.connector.grizzly.ReadTask.executeProcessorTask(ReadTask.java:287)
         at com.sun.enterprise.web.connector.grizzly.ReadTask.doTask(ReadTask.java:212)
         at com.sun.enterprise.web.connector.grizzly.TaskBase.run(TaskBase.java:252)
         at com.sun.enterprise.web.connector.grizzly.WorkerThread.run(WorkerThread.java:75)
    Caused by: java.lang.ClassNotFoundException
         ... 77 more
    ----------END server-side stack trace----------  vmcid: SUN  minor code: 257 completed: Maybe

  • Could not initialize class sun.awt.X11.XToolkit

    hi all
    String fileName = "c:/test/one.jpg";
    Image imgg = Toolkit.getDefaultToolkit().getImage(fileName);
         ImageIcon img = new ImageIcon(imgg);
         imgDim = ""+img.getIconHeight();
    when i run this code in linux machine am getting the error Could not initialize class sun.awt.X11.XToolkit....but its runnig on windows machine.. is there anything wrong wiht my code........pl help me any1 out of dis

    here http://rapid-i.com/rapidforum/index.php?topic=366.0
    they talk about adding to the JVM options a "-Djava.awt.headless=true"

  • LocalSessionFactoryBean - Could not instantiate bean class

    Hello,
    I am facing a problem with the instantiation of the LocaSessionFactoryBean in a sample Spring 3.0.4 - Hibernate 3.2.6, WebLogic 10.3.3 and Oracle 10g. I am run an web application using JDeveloper 11.1.1.3.0 with the integrated WebLogic Server 11gR1. Trying to make the existing web application that is currently running on Oracle Web Server to run on WebLogic.
    I have gone through other LocalSessionFactoryBean related postings but could not find any solutions for my problem.
    Here's the server.log during web application deployment and startup -
    org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'pocDaoTarget' defined in class path resource [spring-chbs.xml]: Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'sessionFactory' defined in ServletContext resource [WEB-INF/xml/spring/spring-j2eeservices.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationExcepti on: Could not instantiate bean class [org.springframework.orm.hibernate3.LocalSessionFac toryBean]: Constructor threw exception; nested exception is java.lang.NoClassDefFoundError
    at org.springframework.beans.factory.support.BeanDefi nitionValueResolver.resolveReference(BeanDefinitio nValueResolver.java:275)
    Caused by: org.springframework.beans.factory.BeanCreationExce ption: Error creating bean with name 'sessionFactory' defined in ServletContext resource [WEB-INF/xml/spring/spring-j2eeservices.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationExcepti on: Could not instantiate bean class [org.springframework.orm.hibernate3.LocalSessionFac toryBean]: Constructor threw exception; nested exception is java.lang.NoClassDefFoundError
    at org.springframework.beans.factory.support.Abstract AutowireCapableBeanFactory.instantiateBean(Abstrac tAutowireCapableBeanFactory.j
    Caused by: org.springframework.beans.BeanInstantiationExcepti on: Could not instantiate bean class [org.springframework.orm.hibernate3.LocalSessionFac toryBean]: Constructor threw exception; nested exception is java.lang.NoClassDefFoundError
    at org.springframework.beans.BeanUtils.instantiateCla ss(BeanUtils.java:115)
    Caused by: java.lang.NoClassDefFoundError
    at org.springframework.orm.hibernate3.LocalSessionFac toryBean.class$(LocalSessionFactoryBean.java:174)
    (Note : I have verified that org.springframework.orm.hibernate3.LocalSessionFactoryBean.class exists in org.springframework.orm-3.0.4.RELEASE.jar)
    Caused by: java.lang.ClassNotFoundException: org.hibernate.cfg.Configuration
    at java.net.URLClassLoader$1.run(URLClassLoader.java: 202)
    (Note : I have verified that org.hibrnate.cfg.Configuration.class exists in hibernate-3.2.6.ga.jar)
    spring-chbs.xml:
    Code:
    <bean id="pocDaoTarget"
    class="myproj.component.chbs.dao.PocDaoImpl">
    <property name="sessionFactory">
    <ref bean="sessionFactory"/>
    </property>
    </bean>
    spring-j2eeservices.xml :
    Code:
    <!-- JNDI DataSource for J2EE environments -->
    <bean id="dataSource" class="org.springframework.jndi.JndiObjectFactoryBean">
    <property name="jndiName" value="java:comp/env/jdbc/J2EEDS"/>
    </bean>
    <bean id="sessionFactory"
    class="org.springframework.orm.hibernate3.LocalSessionFactoryBean">
    <property name="dataSource">
    <ref bean="dataSource"/>
    </property>
    <property name="mappingJarLocations">
    <list>
    <value>WEB-INF/lib/hibernate-config.jar</value>
    <!--value>classpath:hibernate-config.jar</value-->
    </list>
    </property>
    <property name="hibernateProperties">
    <props>
    <prop key="session_factory_name">HibernateSessionFactory</prop>
    <prop key="jndi.class">weblogic.jndi.WLInitialContextFactory</prop>
    <prop key="hibernate.dialect">org.hibernate.dialect.Oracle10gDialect</prop>
    <prop key="hibernate.show_sql">true</prop>
    </props>
    </property>
    </bean>
    Any help would be greatly appreciated.
    Thanks

    Hi Raphael,
    Thanks for your response.
    The last part of the console log output during run –
    Error creating bean with name 'pocDaoTarget' defined in class path resource [spring-chbs.xml]: Cannot resolve reference to bean 'sessionFactory' while setting bean property 'sessionFactory'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'sessionFactory' defined in ServletContext resource [WEB-INF/xml/spring/spring-j2eeservices.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [org.springframework.orm.hibernate3.LocalSessionFactoryBean]: Constructor threw exception; nested exception is java.lang.NoClassDefFoundError
    Servlet Path: C:\Documents and Settings\tariq.ahsan\Application Data\JDeveloper\system11.1.1.3.37.56.60\o.j2ee\drs\AppServerConversion\MaWebWebApp.warBegin Initialize Spring ApplicationContext for MA
    End Initialize Spring ApplicationContext for MA
    Servlet Path: C:\Documents and Settings\tariq.ahsan\Application Data\JDeveloper\system11.1.1.3.37.56.60\o.j2ee\drs\AppServerConversion\PaWebWebApp.warBegin Initialize Spring ApplicationContext for PA
    End Initialize Spring ApplicationContext for PA
    [10:35:57 AM] Application Redeployed Successfully.
    [10:35:57 AM] The following URL context root(s) were defined and can be used as a starting point to test your application:
    [10:35:57 AM] http://192.168.11.207:7101/MaWeb
    [10:35:57 AM] http://192.168.11.207:7101/paweb
    [10:35:57 AM] http://192.168.11.207:7101/CFMSWeb
    [10:35:57 AM] Elapsed time for deployment: 28 seconds
    [10:35:57 AM] ---- Deployment finished. ----
    Run startup time: 28203 ms.
    [Application AppServerConversion deployed to Server Instance IntegratedWebLogicServer]
    Target URL -- http://127.0.0.1:7101/CFMSWeb/login.jsp
    Is one of the above folder - C:\Documents and Settings\tariq.ahsan\Application Data\JDeveloper\system11.1.1.3.37.56.60\o.j2ee\drs\AppServerConversion\MaWebWebApp.war (MaWebWebApp.war is a folder) part of the IntegratedWebLogicServer deployment? Do you mean the spring and possibly the hibernate jars need to be in the WEB-INF/lib under the above folder path?
    Thanks

  • BeanInstantiationException: Could not instantiate bean class

    Hi,
    I am working on a small part of j2ee app and creating a couple beans. Now I get stuck here:
    This is my bean class:
    public class KomplexniPseudoOsoba extends POsoby{
         public KomplexniPseudoOsoba() {
              super();
         public class KomplexniOsoba extends PAdresy{
              public KomplexniOsoba() {
                   super();
    I want the inner KomplexniOsoba class to be my bean. Now when i add it to webmvc-config.xml (using springframework) like this:
    <bean id="KomplexniOsoba" name="KomplexniOsoba"
         class="cz.edu.mub.pef.ja.xkosteln.model.KomplexniPseudoOsoba$KomplexniOsoba">
    </bean>
    I get
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'KomplexniOsoba' defined in ServletContext resource [WEB-INF/spring/webmvc-config.xml]: Instantiation of bean failed; nested exception is org.springframework.beans.BeanInstantiationException: Could not instantiate bean class [cz.edu.mub.pef.ja.xkosteln.model.KomplexniPseudoOsoba$KomplexniOsoba]: No default constructor found; nested exception is java.lang.NoSuchMethodException: cz.edu.mub.pef.ja.xkosteln.model.KomplexniPseudoOsoba$KomplexniOsoba.<init>()
    What am I doing wrong the constructor is there!

    koszta5 wrote:
    Thanks man :D Such a trivial mistake....
    and BTW I absolutely love Oracle forums... some people were sad when Oracle bought Sun but I HAVE TO say that the support went WAY UP. I love the speed with which people reply here. ... It is incredible compared to e.g. Spring forums...I don't know anything about the spring forums, but most of the people who respond in the oracle java forums are the same people who responded in the sun java forums (and in a similar fashion).
    Thank you :)no problem.

  • Jar file error: could not find main class. program will exit

    I have created a jar file using following command
    jar cfm MyProj.jar Manifest.txt richa\*.class
    and I have included main class header in the Manifest.txt. The executable jar file is created but when I double click on it, it prompts an error Could not find the main class. program will exit.
    Please help. Its urgent..
    Thanks in advance

    This simply state that jvm was unable to fine Main Class file.
    I hope you have configured manifest file including your main file information and class path used by the project with proper package hierarchy,
    as described in article
    [https://java.sun.com/docs/books/tutorial/deployment/jar|https://java.sun.com/docs/books/tutorial/deployment/jar]
    Edited by: Deepesh on Jul 13, 2008 4:58 AM

  • Error: "Could not find the main class: Files\NetBeans"

    I am working on a WorldWind mapping application but I think this issue is more of a straight Java question. I was attempting to add a web service reference by means of the NetBeans IDE. The reference compiled as it should have but then the application would not run. I deleted the reference, commented out all the code that used the web reference, basically restored all the code to how it was before trying to add the web service. The applicaiton still will not run with the message that it can't find the main class. I do, however, get a clean build. What should I do to fix this?
    Here is the error: "Could not find the main class: Files\NetBeans"
    thanks!

    nigel25840 wrote:
    I am working on a WorldWind mapping application but I think this issue is more of a straight Java question. I was attempting to add a web service reference by means of the NetBeans IDE. The reference compiled as it should have but then the application would not run. I deleted the reference, commented out all the code that used the web reference, basically restored all the code to how it was before trying to add the web service. The applicaiton still will not run with the message that it can't find the main class. I do, however, get a clean build. What should I do to fix this?
    Here is the error: "Could not find the main class: Files\NetBeans"
    thanks!Sounds like something (a .cmd file or .bat file, perhaps) is set up to launch NetBeans with a command line like this:
    java -classpath ... c:\Program Files\NetBeans ...
    So since the path has embedded space(s) in it, it thinks you are wanting to run a class named "Files\NetBeans", which does not exist.
    You need someone there who knows what they are doing to look into it for you.

Maybe you are looking for

  • How do I correct a build error while saving "Calculate Color Index Array.vi"?

    I have an application that takes some data and then periodically generates a nifty 3d graph.  When trying to compile this application to run on a stand-alone machine, i get an error message that crashes the build.  This is the information that is gen

  • BT HOME HUB 3

    Can you connect a Netgear DGND3300 to the HH3 in order it can be set up as a connection for SKY ?

  • Captivate Demo Does Not Appear

    I'm using TCS 3.5, have a machine with 8 GB RAM, large hard drive, fast processor.  I am using Captivate to record in Demonstration mode at 1024 x 768.  I am outputting to swf. I have followed the RoboHelp instructions to the letter, but still get th

  • A4311f

    I have HP Pavilion Desktop a4311f.  I want to upgrade the Video Card so I can add an additional monitor for my work from home job.  Not a gamer.  But I facilitate a course from home and need an additional monitor. What would be the best Video Card to

  • DELETING PROGRAMS - how to do so properly?

    Hi - Just wondering if anyone could tell me how to completely remove unwated programs from my mac book - with Windows it was as easy as clicking on Uninstall. I have scraped few programs but lots of files related to it still linger around. Any imput