Sending a java.lang.reflect.Constructor through RMI

Hi all,
java.lang.reflect.Constructor is not serializable and therefore cannot be sent through RMI.
The API documentation for java.lang.reflect.AccessibleObject says:
"Setting the accessible flag in a reflected object permits sophisticated applications with sufficient privilege, such as Java Object *Serialization* or other persistence mechanisms, to manipulate objects in a manner that would normally be prohibited."
I cannot fully understand that. Would this help provide a workaround for sending a Constructor throup RMI ? if so, how ?
Thank you

Gen.Java wrote:
Hi all,
java.lang.reflect.Constructor is not serializable and therefore cannot be sent through RMI.It wouldn't make any sense for it to be. I suspect you're imagining some magical scenario that is actually impossible, such as simply sending a constructor to a remote object, and having it somehow instantiate a class it knows nothing about. Whatever it is you're trying to achieve, this isn't the way to do it. So how about you tell us what that is
The API documentation for java.lang.reflect.AccessibleObject says:
"Setting the accessible flag in a reflected object permits sophisticated applications with sufficient privilege, such as Java Object *Serialization* or other persistence mechanisms, to manipulate objects in a manner that would normally be prohibited."
I cannot fully understand that. Would this help provide a workaround for sending a Constructor throup RMI ? if so, how ?No. Sending constructors by RMI makes no sense. See above. As is usual in these cases, you've asked a question on some hacky solution to a problem, rather than the problem itself. Let's talk about that: the problem itself. What are you trying to achieve?

Similar Messages

  • Java.lang.reflect.Constructor thread safe ?

    When you have a Constructor object in Java.
    Is calling the newInstance method on the same Constructor object from multiple threads safe.
    Or is this not thread safe leading to wrongly constructed objects?

    ejp wrote:
    And as Constructors are immutable, it's hard to see how it's going to get altered.Constructors are basically immutable, but they have at least one state which can make the difference between newInstance working or failing.
    As you can see in the following example, setAccessible() is not something you would want to set to different values in different threads.
    import java.lang.reflect.Constructor;
    public class Main {
        public static void main(String... args) throws Exception {
            Constructor cons = Private.class.getDeclaredConstructor();
            cons.setAccessible(false);
            try {
                System.out.println("cons.isAccessible()= " + cons.isAccessible());
                cons.newInstance();
                throw new AssertionError("IllegalAccessException expected");
            } catch (IllegalAccessException expected) {
                // ignored
            cons.setAccessible(true);
            System.out.println("cons.isAccessible()= " + cons.isAccessible());
            cons.newInstance();
    class Private {
        private Private() {
    }

  • Java.lang.reflect.InvocationTargetException while executing xjc.bat.

    Hi , After installing the latest Webservice pack ,
    i'am trying to run the Sample application in examples directory .
    ( JAXB ).while running the XJC command i am getting follwing exception .
    I tried to run the same command by pointing the Classpath to JDK 1.3 as well as Jsdk 1.4 but no luck .
    Can any one tell me what's wrong with my setup any help is appriciated .
    Thanks in advance,
    Abhijit Choudhary .
    X:\Abhijit\JAXB\jaxb-1.0\examples\users-guide\SampleApp1>xjc po.xsd -p primer.po
    parsing a schema...
    compiling a schema...
    java.lang.reflect.InvocationTargetException
    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:324)
    at org.apache.commons.launcher.ChildMain.run(ChildMain.java:269)
    Caused by: java.lang.InternalError: internal error: SHA-1 not available.
    at sun.security.provider.SecureRandom.init(SecureRandom.java:86)
    at sun.security.provider.SecureRandom.<init>(SecureRandom.java:65)
    at java.security.SecureRandom.<init>(SecureRandom.java:131)
    at com.sun.crypto.provider.SunJCE.<clinit>(DashoA6275)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)
    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)
    at java.lang.reflect.Constructor.newInstance(Constructor.java:274)
    at java.lang.Class.newInstance0(Class.java:306)
    at java.lang.Class.newInstance(Class.java:259)
    at java.security.Provider.loadProvider(Provider.java:153)
    at java.security.Security$3.run(Security.java:349)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.security.Security.loadOneMoreProvider(Security.java:346)
    at java.security.Security.getEngineClassName(Security.java:557)
    at java.security.Security.getEngineClassName(Security.java:594)
    at java.security.Security.getImpl(Security.java:1043)
    at java.security.MessageDigest.getInstance(MessageDigest.java:120)
    at java.io.ObjectStreamClass.computeDefaultSUID(ObjectStreamClass.java:1568)
    at java.io.ObjectStreamClass.access$100(ObjectStreamClass.java:45)
    at java.io.ObjectStreamClass$1.run(ObjectStreamClass.java:169)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.io.ObjectStreamClass.getSerialVersionUID(ObjectStreamClass.java:166)
    at java.io.ObjectStreamClass.writeNonProxy(ObjectStreamClass.java:553)
    at java.io.ObjectOutputStream.writeClassDescriptor(ObjectOutputStream.java:591)
    at java.io.ObjectOutputStream.writeNonProxyDesc(ObjectOutputStream.java:1142)
    at java.io.ObjectOutputStream.writeClassDesc(ObjectOutputStream.java:1100)
    at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1179)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1050)
    at java.io.ObjectOutputStream.defaultWriteFields(ObjectOutputStream.java:1330)
    at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1302)
    at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1245)
    at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1052)
    at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:278)
    at com.sun.codemodel.fmt.JSerializedObject.<init>(JSerializedObject.java:27)
    at com.sun.tools.xjc.generator.ObjectFactoryGenerator.generate(ObjectFactoryGenerator.java:290)
    at com.sun.tools.xjc.generator.ObjectFactoryGenerator.<init>(ObjectFactoryGenerator.java:111)
    at com.sun.tools.xjc.generator.SkeletonGenerator.<init>(SkeletonGenerator.java:114)
    at com.sun.tools.xjc.generator.SkeletonGenerator.generate(SkeletonGenerator.java:92)
    at com.sun.tools.xjc.Driver.generateCode(Driver.java:728)
    at com.sun.tools.xjc.Driver.run(Driver.java:423)
    at com.sun.tools.xjc.Driver._main(Driver.java:113)
    at com.sun.tools.xjc.Driver.access$000(Driver.java:77)
    at com.sun.tools.xjc.Driver$1.run(Driver.java:93)

    HI,
    I also got the same problem. It were throwing the java.lang.reflect.InvocationTargetException while the running xjc.bat from <jaxb installed dir>\bin\ and refering the schema through full path.
    I am current running with j2sdk1.4.1_01 and jwsdp1.1.
    The solution which worked out for me was
    Just go to directory where you saved the xml schema file(.xsd file).just modify the System path to refer xjc.bat and taht's it.
    Run the xjc with XmlSchema file name with output package name and target directory like follows:
    xjc "XmlSchema.xsd" -d <targetdirectory> -p <packagename>
    Hope this will help
    Regards,
    Atul

  • Problem with  java.lang.reflect in Eclipse

    I'm just reading java tutorial about that library, but when i'm trying to execute those example program's e.g
    import java.lang.reflect.Constructor;
    import java.lang.reflect.Type;
    import static java.lang.System.out;
    public class ConstructorSift {
        public static void main(String... args) {
         try {
             Class<?> cArg = Class.forName(args[1]);
             Class<?> c = Class.forName(args[0]);
             Constructor[] allConstructors = c.getDeclaredConstructors();
             for (Constructor ctor : allConstructors) {
              Class<?>[] pType  = ctor.getParameterTypes();
              for (int i = 0; i < pType.length; i++) {
                  if (pType.equals(cArg)) {
                   out.format("%s%n", ctor.toGenericString());
                   Type[] gpType = ctor.getGenericParameterTypes();
                   for (int j = 0; j < gpType.length; j++) {
                   char ch = (pType[j].equals(cArg) ? '*' : ' ');
                   out.format("%7c%s[%d]: %s%n", ch,
                        "GenericParameterType", j, gpType[j]);
                   break;
    // production code should handle this exception more gracefully
         } catch (ClassNotFoundException x) {
         x.printStackTrace();
    in Eclipse i've got nothing in my output console :/
    no errors, no warnings, no text ..... (it was terminated correctly)
    Can somebody tell me what should I do to make it work properly ?                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

    Hi,
    In program arguments, you should not have ConstructorSift but only java.util.Formatter and java.util.Locale.
    (Eclipse : run dialog | arguments tab | program arguments)
    This is the output you should get:
    $ java ConstructorSift java.util.Formatter java.util.Locale
    public java.util.Formatter(java.util.Locale)
    *GenericParameterType[0]: class java.util.Locale
    public java.util.Formatter(java.lang.Appendable,java.util.Locale)
    GenericParameterType[0]: interface java.lang.Appendable
    *GenericParameterType[1]: class java.util.Locale
    public java.util.Formatter(java.lang.String,java.lang.String,java.util.Locale) throws java.io.FileNotFoundException,java.io.UnsupportedEncodingException
    GenericParameterType[0]: class java.lang.String
    GenericParameterType[1]: class java.lang.String
    *GenericParameterType[2]: class java.util.Locale
    public java.util.Formatter(java.io.File,java.lang.String,java.util.Locale) throws java.io.FileNotFoundException,java.io.UnsupportedEncodingException
    GenericParameterType[0]: class java.io.File
    GenericParameterType[1]: class java.lang.String
    *GenericParameterType[2]: class java.util.Locale
    public java.util.Formatter(java.io.OutputStream,java.lang.String,java.util.Locale) throws java.io.UnsupportedEncodingException
    GenericParameterType[0]: class java.io.OutputStream
    GenericParameterType[1]: class java.lang.String
    *GenericParameterType[2]: class java.util.Locale
    Hope that help,
    Jack

  • Calling a web service from a servlet via stub: java.lang.reflect.Invocation

    Hi all, I'm developping my first web application using Apache Tomcat and Axis, using servlets, jsp and web services.
    My problem is that I cannot make any call to my web service (a very simple one) because I get the following exception:
    <code>
    java.lang.reflect.InvocationTargetException CAUSA: null
    AxisFault
    faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
    faultSubcode:
    faultString: java.lang.reflect.InvocationTargetException
    faultActor:
    faultNode:
    faultDetail:
    {http://xml.apache.org/axis/}hostname:lexis02
    java.lang.reflect.InvocationTargetException
    at org.apache.axis.message.SOAPFaultBuilder.createFault(SOAPFaultBuilder.java:222)
    at org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:129)
    at org.apache.axis.encoding.DeserializationContext.endElement(DeserializationContext.java:1087)
    </code>
    The stack trace is longer than that, but I didn't find any hints to solve the problem.
    The exception is thrown for every method of the web service:

    public java.lang.String[] getMessage(java.lang.String , int) throws java.rmi.RemoteException
    public boolean addMessage(java.lang.String, java.lang.String, int)
    throws java.rmi.RemoteException
    I'm using stub to call the web service, as generated by wsdl tool.
    Can someone help me?
    Thanx
    PS: sorry for the double message but I pressed the wronk key at the wrong time :)

  • Exceptions details : java.lang.reflect.InvocationTargetException

    I have set up a web service.
    Development environment:
    1 java 5.0
    2 jwsdp 2.0
    3 Java system application server 9.0
    I set up the web service by following these steps:
    1 write endpoint application source code
    2 write build file and build properties.
    3 use asant command compile the source code (successfully)
    4 use "asant generate-runtime-artifacts" generate web service artifacts(successfully)
    5 use "asant pkg-war" to package war file. (successfully)
    6 use "asant deploy-app " to deploy the web service. (successfully)
    So, I can find my webservice in administration console. I click the test button, it pop up a webpage, in which I can input parameters for my web method.
    After inputting all the parameters, I clicked the button to invock my web method. But some exceptions occured.
    Exceptions details : java.lang.reflect.InvocationTargetException
    javax.servlet.ServletException: java.lang.reflect.InvocationTargetException at com.sun.enterprise.webservice.monitoring.WebServiceTesterServlet.doPost(WebServiceTesterServlet.java:311) at com.sun.enterprise.webservice.monitoring.WebServiceTesterServlet.invoke(WebServiceTesterServlet.java:106) at com.sun.enterprise.webservice.JAXWSServlet.doPost(JAXWSServlet.java:135) at javax.servlet.http.HttpServlet.service(HttpServlet.java:727) 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.reflect.InvocationTargetException 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.webservice.monitoring.WebServiceTesterServlet.doPost(WebServiceTesterServlet.java:284) ... 28 more Caused by: javax.xml.ws.soap.SOAPFaultException: Unknown fault type:class java.lang.NoClassDefFoundError at com.sun.xml.ws.encoding.soap.ClientEncoderDecoder.toMessageInfo(ClientEncoderDecoder.java:86) at com.sun.xml.ws.encoding.soap.client.SOAPXMLDecoder.toMessageInfo(SOAPXMLDecoder.java:211) at com.sun.xml.ws.protocol.soap.client.SOAPMessageDispatcher.receive(SOAPMessageDispatcher.java:540) at com.sun.xml.ws.protocol.soap.client.SOAPMessageDispatcher.doSend(SOAPMessageDispatcher.java:260) at com.sun.xml.ws.protocol.soap.client.SOAPMessageDispatcher.send(SOAPMessageDispatcher.java:139) at com.sun.xml.ws.encoding.soap.internal.DelegateBase.send(DelegateBase.java:86) at com.sun.xml.ws.client.EndpointIFInvocationHandler.implementSEIMethod(EndpointIFInvocationHandler.java:174) at com.sun.xml.ws.client.EndpointIFInvocationHandler.invoke(EndpointIFInvocationHandler.java:108) at $Proxy76.getAdslPortStatus(Unknown Source) ... 33 more
    Anybody can give me a clue? Thank you very much.
    Message was edited by:
    Flashget
    Message was edited by:
    Flashget

    i to have the same errors which u got sir, if u find any answer please send it to me
    [email protected]
    regards
    hari krishna

  • Java.lang.reflect.InvocationTargetException

    Hi,
    I am new to EJB. i've developed my first EJB Program using Netbeans.
    Here are my classes :
    package ejb;
    import javax.ejb.Stateless;
    @Stateless(mappedName="Bean30")
    public class Bean30Bean implements Bean30Remote
    public String getResult()
    return "This is EJB 3.0 Bean";
    Remote Interface :
    package ejb;
    import javax.ejb.Remote;
    @Remote
    public interface Bean30Remote {
    String getResult();
    Calling EJB :
    InitialContext ctx = new InitialContext();
    Bean30Remote br = (Bean30Remote) ctx.lookup("Bean30#ejb.Bean30Remote");
    System.err.println("EJB message is: " + br.getResult());
    While lookup, it is throwing me an exception :
    java.lang.reflect.InvocationTargetException
    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 org.glassfish.appclient.client.acc.AppClientContainer.launch(AppClientContainer.java:438)
    at org.glassfish.appclient.client.AppClientFacade.main(AppClientFacade.java:165)
    Caused by: javax.naming.NamingException: Lookup failed for 'Bean30#ejb.Bean30Remote2' in SerialContext[myEnv={java.naming.factory.initial=com.sun.enterprise.naming.impl.SerialInitContextFactory, java.naming.factory.url.pkgs=com.sun.enterprise.naming, java.naming.factory.state=com.sun.corba.ee.impl.presentation.rmi.JNDIStateFactoryImpl} [Root exception is javax.naming.NamingException: ejb ref resolution error for remote business interfaceejb.Bean30Remote2 [Root exception is java.lang.ClassNotFoundException: ejb.Bean30Remote2]]
    at com.sun.enterprise.naming.impl.SerialContext.lookup(SerialContext.java:518)
    at com.sun.enterprise.naming.impl.SerialContext.lookup(SerialContext.java:455)
    at javax.naming.InitialContext.lookup(InitialContext.java:392)
    at applicationclientfortest.Main.main(Main.java:27)
    ... 6 more
    Caused by: javax.naming.NamingException: ejb ref resolution error for remote business interfaceejb.Bean30Remote2 [Root exception is java.lang.ClassNotFoundException: ejb.Bean30Remote2]
    at com.sun.ejb.EJBUtils.lookupRemote30BusinessObject(EJBUtils.java:433)
    at com.sun.ejb.containers.RemoteBusinessObjectFactory.getObjectInstance(RemoteBusinessObjectFactory.java:75)
    at javax.naming.spi.NamingManager.getObjectInstance(NamingManager.java:304)
    at com.sun.enterprise.naming.impl.SerialContext.getObjectInstance(SerialContext.java:556)
    at com.sun.enterprise.naming.impl.SerialContext.lookup(SerialContext.java:514)
    ... 9 more
    Caused by: java.lang.ClassNotFoundException: ejb.Bean30Remote2
    at java.net.URLClassLoader$1.run(URLClassLoader.java:202)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:190)
    at org.glassfish.appclient.client.acc.ACCClassLoader.findClass(ACCClassLoader.java:212)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:248)
    at com.sun.ejb.EJBUtils.getBusinessIntfClassLoader(EJBUtils.java:687)
    at com.sun.ejb.EJBUtils.loadGeneratedRemoteBusinessClasses(EJBUtils.java:462)
    at com.sun.ejb.EJBUtils.lookupRemote30BusinessObject(EJBUtils.java:413)
    ... 13 more
    I've checked on the GlassFish. It has been deployed successfully with name "EJBModule30".
    Any comments will be greatly appreciated. Please let me know if i'm doing something wrong.

    r035198x wrote:
    >
    That shouldn't be necessary in a JEE environment. Proper packaging is all you need to do and the container takes care of the rest.The remote client may not be in a container....
    **puts on a brown paper bag**
    In any case the name inconsistency is a nice catch, but when I check the logging:
    ejb ref resolution error for remote business interfaceejb.Bean30Remote2 [Root exception is java.lang.ClassNotFoundException: ejb.Bean30Remote2]]I wonder if Glassfish actually contains a logging mistake where it doesn't print a space between the log text and the interface, or that someone has been doing some manual editing before posting it...

  • Java.lang.reflect.InvocationTargetException.... Please Help!!

    I am reading a .dbf file and then...parse it and insert the parsed data into MYSQL Database.After inserting 50 records..iam calling the sleep method on the class...to give time for the jrun to release the ports for further..inserts.The code inserts the first 50 records and when it comes back after the sleep method..this null pointer exception is being thrown..when i check the Jrun Server log file.
    This is the final stage of my project...where iam having to transfer live data from DBase to MYSQL.Any help...is highly appreciated guys..
    This is the error that it is throwing (Scroll down to see the code as well):
    07/28 10:59:58 error null; nested exception is:
         java.lang.reflect.InvocationTargetException
    [2]java.lang.NullPointerException
         at jrun.sql.JRunResultSet.clearUpdates(JRunResultSet.java:1873)
         at jrun.sql.JRunResultSet.next(JRunResultSet.java:1100)
         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:324)
         at jrunx.comp.sql.SQLInvokerBean.invokeResultSet(SQLInvokerBean.java:217)
         at sun.reflect.GeneratedMethodAccessor112.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at jrun.ejb.interceptors.InvokerInterceptor.invokeObjectMethod(InvokerInterceptor.java:153)
         at jrun.ejb.interceptors.ContainerManagedTransactionInterceptor.invokeTransactedMethod(ContainerManagedTransactionInterceptor.java:148)
         at jrun.ejb.interceptors.TransactionInterceptor.invokeObjectMethod(TransactionInterceptor.java:130)
         at jrun.ejb.interceptors.StatefulSessionInstanceInterceptor.invokeObjectMethod(StatefulSessionInstanceInterceptor.java:242)
         at jrun.ejb.interceptors.EJBSecurityInterceptor.invokeObjectMethod(EJBSecurityInterceptor.java:81)
         at jrun.ejb.EJBContainer.invokeObjectMethod(EJBContainer.java:193)
         at jrun.ejb.invocation.RemoteInvocationProxyImpl.invoke(RemoteInvocationProxyImpl.java:111)
         at jrunx.rmi.RMIBroker.invokeEJB(RMIBroker.java:235)
         at jrunx.rmi.RMIBroker.invoke(RMIBroker.java:142)
         at sun.reflect.GeneratedMethodAccessor31.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
         at sun.rmi.transport.Transport$1.run(Transport.java:148)
         at java.security.AccessController.doPrivileged(Native Method)
         at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
         at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
         at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
         at java.lang.Thread.run(Thread.java:536)
    [1]java.lang.reflect.InvocationTargetException
         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:324)
         at jrunx.comp.sql.SQLInvokerBean.invokeResultSet(SQLInvokerBean.java:217)
         at sun.reflect.GeneratedMethodAccessor112.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at jrun.ejb.interceptors.InvokerInterceptor.invokeObjectMethod(InvokerInterceptor.java:153)
         at jrun.ejb.interceptors.ContainerManagedTransactionInterceptor.invokeTransactedMethod(ContainerManagedTransactionInterceptor.java:148)
         at jrun.ejb.interceptors.TransactionInterceptor.invokeObjectMethod(TransactionInterceptor.java:130)
         at jrun.ejb.interceptors.StatefulSessionInstanceInterceptor.invokeObjectMethod(StatefulSessionInstanceInterceptor.java:242)
         at jrun.ejb.interceptors.EJBSecurityInterceptor.invokeObjectMethod(EJBSecurityInterceptor.java:81)
         at jrun.ejb.EJBContainer.invokeObjectMethod(EJBContainer.java:193)
         at jrun.ejb.invocation.RemoteInvocationProxyImpl.invoke(RemoteInvocationProxyImpl.java:111)
         at jrunx.rmi.RMIBroker.invokeEJB(RMIBroker.java:235)
         at jrunx.rmi.RMIBroker.invoke(RMIBroker.java:142)
         at sun.reflect.GeneratedMethodAccessor31.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
         at sun.rmi.transport.Transport$1.run(Transport.java:148)
         at java.security.AccessController.doPrivileged(Native Method)
         at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
         at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
         at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
         at java.lang.Thread.run(Thread.java:536)
    Caused by: java.lang.NullPointerException
         at jrun.sql.JRunResultSet.clearUpdates(JRunResultSet.java:1873)
         at jrun.sql.JRunResultSet.next(JRunResultSet.java:1100)
         ... 27 more
    [0]java.rmi.RemoteException: null; nested exception is:
         java.lang.reflect.InvocationTargetException
         at jrunx.comp.sql.SQLInvokerBean.handleException(SQLInvokerBean.java:340)
         at jrunx.comp.sql.SQLInvokerBean.invokeResultSet(SQLInvokerBean.java:225)
         at sun.reflect.GeneratedMethodAccessor112.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at jrun.ejb.interceptors.InvokerInterceptor.invokeObjectMethod(InvokerInterceptor.java:153)
         at jrun.ejb.interceptors.ContainerManagedTransactionInterceptor.invokeTransactedMethod(ContainerManagedTransactionInterceptor.java:148)
         at jrun.ejb.interceptors.TransactionInterceptor.invokeObjectMethod(TransactionInterceptor.java:130)
         at jrun.ejb.interceptors.StatefulSessionInstanceInterceptor.invokeObjectMethod(StatefulSessionInstanceInterceptor.java:242)
         at jrun.ejb.interceptors.EJBSecurityInterceptor.invokeObjectMethod(EJBSecurityInterceptor.java:81)
         at jrun.ejb.EJBContainer.invokeObjectMethod(EJBContainer.java:193)
         at jrun.ejb.invocation.RemoteInvocationProxyImpl.invoke(RemoteInvocationProxyImpl.java:111)
         at jrunx.rmi.RMIBroker.invokeEJB(RMIBroker.java:235)
         at jrunx.rmi.RMIBroker.invoke(RMIBroker.java:142)
         at sun.reflect.GeneratedMethodAccessor31.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
         at sun.rmi.transport.Transport$1.run(Transport.java:148)
         at java.security.AccessController.doPrivileged(Native Method)
         at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
         at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
         at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
         at java.lang.Thread.run(Thread.java:536)
    Caused by: java.lang.reflect.InvocationTargetException
         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:324)
         at jrunx.comp.sql.SQLInvokerBean.invokeResultSet(SQLInvokerBean.java:217)
         ... 22 more
    Caused by: java.lang.NullPointerException
         at jrun.sql.JRunResultSet.clearUpdates(JRunResultSet.java:1873)
         at jrun.sql.JRunResultSet.next(JRunResultSet.java:1100)
         ... 27 more
    Here is the code how iam doing it:
    public class MainTable extends Thread implements Runnable
         private static MyBeans.ConnectionBean cb = new MyBeans.ConnectionBean();
         private static Connection connection = cb.getConnection();
         private static PreparedStatement ps=null;
         private static PreparedStatement pst=null;
         private static ResultSet rs=null;
         public static void main(String[] args){
              MainTable mt = new MainTable();
              int empId=0;
              String supervisor ="";
              String startTime="";
              String endTime="";
              String sdate="";
              double hours = 0.0;
              String stype="";
              String empType="";
              try {
                   String sql = "SELECT eg.EmployeeId, sg.Supervisor, sg.StartTime, sg.EndTime, sg.SupervisionDate, sg.SupervisionHours, sg.SupervisionType FROM EmployeeGoldmine AS eg, SupervisionGoldmine AS sg WHERE eg.AccountNo=sg.AccountNo ORDER BY eg.EmployeeId";
                   ps=connection.prepareStatement(sql);
                   rs = ps.executeQuery();
                   int count =0;
                   while (rs.next()){
                        count++;
                        empId=rs.getInt("EmployeeId");
                        empType = mt.getEmployeeType(empId);
                        supervisor = rs.getString("Supervisor");
                        startTime = rs.getString("StartTime");
                        endTime = rs.getString("EndTime");
                        sdate = rs.getString("SupervisionDate");
                        hours = rs.getDouble("SupervisionHours");
                        stype = rs.getString("SupervisionType");
                        System.out.println(empId + "=>" + supervisor + "=>" + startTime + "=>" + endTime + "=>" + sdate + "=>" + hours + "=>" + stype + "=>" + empType );
                        try {
                             String mysql = "INSERT INTO Supervision(Supervisor,StartTime,EndTime,SupervisionDate,SupervisionHours,EmployeeId,Type,supervisionType) VALUES(?,?,?,?,?,?,?,?)";
                                  pst=connection.prepareStatement(mysql);
                                  pst.setString(1, supervisor);
                                  pst.setString(2, startTime);
                                  pst.setString(3, endTime);
                                  pst.setString(4, sdate);
                                  pst.setDouble(5, hours);
                                  pst.setInt(6, empId);
                                  pst.setString(7, empType);
                                  pst.setString(8, stype);
                                  pst.executeUpdate();
                             } catch (Exception      exp) {
                                       System.out.println(exp);
                                  if (count==50){
                                  mt.sleep(120000);
                                  connection = cb.getConnection();
                                  count=0;
                   }//end of while
                   System.out.println(count);
                   try {
                             rs.close();
                             ps.close();
                             pst.close();
                             connection.close();
                             } catch (Exception e) {
                                  System.out.println(e);
                        } catch (Exception      ex) {
                             System.out.println(ex.getMessage());
         }

    Well i sorted out the things..i had to change the way i was accessing the datasource object..so no more problems of "running out of ports " and stuff.

  • Java.lang.reflect.InvocationTargetException Caused by: java.lang.UnsatisfiedLinkError

    Hi all,
    I'm using jdic web browser (windows version) and customizing it for a project. I want to make an executable jar file. Since I'm using NetBeans 6.7.1, I'm getting a jar file in dist folder. Bt when I run it it does not open the jdic browser.
    Then I tried java web start and make a jnlp file. When it tries to run I get the below error..
    java.lang.reflect.InvocationTargetException
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at com.sun.javaws.Launcher.executeApplication(Launcher.java:1293)
    at com.sun.javaws.Launcher.executeMainClass(Launcher.java:1239)
    at com.sun.javaws.Launcher.doLaunchApp(Launcher.java:1086)
    at com.sun.javaws.Launcher.run(Launcher.java:105)
    at java.lang.Thread.run(Unknown Source)
    Caused by: java.lang.UnsatisfiedLinkError: no jdic in java.library.path
    at java.lang.ClassLoader.loadLibrary(Unknown Source)
    at java.lang.Runtime.loadLibrary0(Unknown Source)
    at java.lang.System.loadLibrary(Unknown Source)
    at org.jdesktop.jdic.browser.internal.WebBrowserUtil$1.run(Unknown Source)
    at java.security.AccessController.doPrivileged(Native Method)
    at org.jdesktop.jdic.browser.internal.WebBrowserUtil.loadLibrary(Unknown Source)
    at org.jdesktop.jdic.browser.internal.WebBrowserUtil.getDefaultBrowserPath(Unknown Source)
    at org.jdesktop.jdic.browser.BrowserEngineManager.selectEngine(Unknown Source)
    at org.jdesktop.jdic.browser.BrowserEngineManager.getActiveEngine(Unknown Source)
    at AgentBrowser.Browser.jbInit(Browser.java:362)
    at AgentBrowser.Browser.<init>(Browser.java:99)
    at AgentBrowser.Browser.main(Browser.java:117)
    ... 9 more
    http://java.ittoolbox.com/groups/technical-functio...ocationtargetexception-1710507
    A person shared his view on "java.lang.reflect.InvocationTargetException" but I'm not quite sure about that since the browser works nicely if I run through NetBeans. (running the project through NetBeans).
    I dnt know how does this library path problem occurs
    please help me..!!
    thanks in advance

    Yeah..! it's working :)
    I just copied jdic files (jdic.jar,jdic.dll, IeEmbed.exe etc) into dict/lib/ folder and now it is working.

  • Java.lang.reflect.InvocationTargetException: java.security.AccessControlException: access denied (java.lang.RuntimePermission setContextClassLoader ) exception at startup

    Hi Everybody
    I downloaded and installed weblogic as per the installation document
    but I am getting the following exception and finally the server
    is started. Can somebody help me to resolve this problem
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.jts.internal.TransactionManagerImpl.<init>(TransactionManagerImpl.java:24)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:35 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.jts.internal.CoordinatorFactoryImpl.start(CoordinatorFactoryImpl.java:52)
         at weblogic.jts.internal.TransactionManagerImpl.<init>(TransactionManagerImpl.java:33)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:35 EST 2001:<I> <WebLogicServer> Invoking main-style
    startup weblogic.jdbc.common.internal.JdbcStartup weblogic.jdbc.common.internal.JdbcStartup
    Wed Feb 28 12:55:35 EST 2001:<E> <JDBC Init> ERROR: Could not get
    JNDI context: javax.naming.NoInitialContextException: Cannot instantiate
    class: weblogic.jndi.WLInitialContextFactory [Root exception is
    java.security.AccessControlException: access denied (java.lang.RuntimePermission
    getClassLoader )]
    Wed Feb 28 12:55:35 EST 2001:<I> <JMS> Beginning startup process
    Wed Feb 28 12:55:35 EST 2001:<I> <JMS> Init JMS Security
    Wed Feb 28 12:55:35 EST 2001:<I> <JMS> Initializing from weblogic.properties
    Wed Feb 28 12:55:35 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.jms.server.JMSManager.getContext(JMSManager.java:851)
         at weblogic.jms.server.JMSManager.getContext(JMSManager.java:835)
         at weblogic.jms.server.JMSManager.doInitFromProperties(JMSManager.java:483)
         at weblogic.jms.server.JMSManager.initFromProperties(JMSManager.java:472)
         at weblogic.jms.server.JMSManager.init(JMSManager.java:299)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:35 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.jms.server.JMSManager.getContext(JMSManager.java:851)
         at weblogic.jms.server.JMSManager.doInitFromProperties(JMSManager.java:488)
         at weblogic.jms.server.JMSManager.initFromProperties(JMSManager.java:472)
         at weblogic.jms.server.JMSManager.init(JMSManager.java:299)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<I> <JMS> Startup process complete.
    JMS is active
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.jms.server.JMSManager.getContext(JMSManager.java:851)
         at weblogic.jms.server.JMSManager.initSessionPoolManager(JMSManager.java:317)
         at weblogic.jms.server.JMSManager.init(JMSManager.java:308)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<I> <JMS> Bound SessionPoolManager
    as weblogic.jms.SessionPoolManager
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.jms.server.JMSManager.getContext(JMSManager.java:851)
         at weblogic.jms.server.JMSManager.initConnectionConsumerManager(JMSManager.java:333)
         at weblogic.jms.server.JMSManager.init(JMSManager.java:310)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<I> <JMS> Bound ConnectionConsumerManager
    as weblogic.jms.ConnectionConsumerManager
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.t3.srvr.T3Srvr.bindServer(T3Srvr.java:1476)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(Compiled
    Code)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.t3.srvr.T3Srvr.bindServer(T3Srvr.java:1495)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<I> <WebLogicServer> Invoking main-style
    startup RMI Registry weblogic.rmi.internal.RegistryImpl
    Wed Feb 28 12:55:36 EST 2001:<I> <RMI> Registry started
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(Compiled
    Code)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.common.internal.T3BindableServices.initialize(T3BindableServices.java:114)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(Compiled
    Code)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.ejb.internal.EJBManagerImpl.bindToJNDI(EJBManagerImpl.java:580)
         at weblogic.ejb.internal.EJBManagerImpl.<init>(EJBManagerImpl.java:226)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<E> <EJB> Cannot intialize Mail Session
    resources because could not get JNDI context: javax.naming.NoInitialContextException:
    Cannot instantiate class: weblogic.jndi.WLInitialContextFactory
    [Root exception is java.security.AccessControlException: access
    denied (java.lang.RuntimePermission getClassLoader )]
    Wed Feb 28 12:55:36 EST 2001:<I> <EJB> 0 EJB jar files loaded,
    containing 0 EJBs
    Wed Feb 28 12:55:36 EST 2001:<I> <EJB> 0 deployed, 0 failed to
    deploy.
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
         at java.lang.Throwable.fillInStackTrace(Native Method)
         at java.lang.Throwable.fillInStackTrace(Compiled Code)
         at java.lang.Throwable.<init>(Compiled Code)
         at java.lang.Exception.<init>(Compiled Code)
         at java.lang.RuntimeException.<init>(Compiled Code)
         at java.lang.SecurityException.<init>(Compiled Code)
         at java.security.AccessControlException.<init>(Compiled Code)
         at java.security.AccessControlContext.checkPermission(Compiled
    Code)
         at java.security.AccessController.checkPermission(Compiled Code)
         at java.lang.SecurityManager.checkPermission(Compiled Code)
         at java.lang.Thread.setContextClassLoader(Compiled Code)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(Compiled
    Code)
         at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(Compiled
    Code)
         at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
         at weblogic.jndi.Environment.getContext(Environment.java:122)
         at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
         at weblogic.io.common.internal.T3FileSystemProxyImpl.installFileSystems(Compiled
    Code)
         at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
         at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
         at java.lang.reflect.Method.invoke(Native Method)
         at weblogic.Server.startServerDynamically(Server.java:99)
         at weblogic.Server.main(Server.java:65)
         at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<E> <ServletContext-General> cannot
    make temp directory '/opt/weblogic/myserver/public_html/_tmp_war',
    will not be able to compile JSPs
    Wed Feb 28 12:55:36 EST 2001:<E> <HTTP> Cannot intialize httpd
    URL resources because could not get JNDI context: javax.naming.NoInitialContextException:
    Cannot instantiate class: weblogic.jndi.WLInitialContextFactory
    [Root exception is java.security.AccessControlException: access
    denied (java.lang.RuntimePermission getClassLoader )]
    Lot of thanks for your help.

    Check the weblogic.policy file to make sure that it is giving permissions to the right directories. If you have
    installed a Service Pack, make sure that both service pack jar files are at the front of their corresponding
    classpaths...
    vj wrote:
    Hi Everybody
    I downloaded and installed weblogic as per the installation document
    but I am getting the following exception and finally the server
    is started. Can somebody help me to resolve this problem
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.jts.internal.TransactionManagerImpl.<init>(TransactionManagerImpl.java:24)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:35 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.jts.internal.CoordinatorFactoryImpl.start(CoordinatorFactoryImpl.java:52)
    at weblogic.jts.internal.TransactionManagerImpl.<init>(TransactionManagerImpl.java:33)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:35 EST 2001:<I> <WebLogicServer> Invoking main-style
    startup weblogic.jdbc.common.internal.JdbcStartup weblogic.jdbc.common.internal.JdbcStartup
    Wed Feb 28 12:55:35 EST 2001:<E> <JDBC Init> ERROR: Could not get
    JNDI context: javax.naming.NoInitialContextException: Cannot instantiate
    class: weblogic.jndi.WLInitialContextFactory [Root exception is
    java.security.AccessControlException: access denied (java.lang.RuntimePermission
    getClassLoader )]
    Wed Feb 28 12:55:35 EST 2001:<I> <JMS> Beginning startup process
    Wed Feb 28 12:55:35 EST 2001:<I> <JMS> Init JMS Security
    Wed Feb 28 12:55:35 EST 2001:<I> <JMS> Initializing from weblogic.properties
    Wed Feb 28 12:55:35 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.jms.server.JMSManager.getContext(JMSManager.java:851)
    at weblogic.jms.server.JMSManager.getContext(JMSManager.java:835)
    at weblogic.jms.server.JMSManager.doInitFromProperties(JMSManager.java:483)
    at weblogic.jms.server.JMSManager.initFromProperties(JMSManager.java:472)
    at weblogic.jms.server.JMSManager.init(JMSManager.java:299)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:35 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.jms.server.JMSManager.getContext(JMSManager.java:851)
    at weblogic.jms.server.JMSManager.doInitFromProperties(JMSManager.java:488)
    at weblogic.jms.server.JMSManager.initFromProperties(JMSManager.java:472)
    at weblogic.jms.server.JMSManager.init(JMSManager.java:299)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<I> <JMS> Startup process complete.
    JMS is active
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.jms.server.JMSManager.getContext(JMSManager.java:851)
    at weblogic.jms.server.JMSManager.initSessionPoolManager(JMSManager.java:317)
    at weblogic.jms.server.JMSManager.init(JMSManager.java:308)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<I> <JMS> Bound SessionPoolManager
    as weblogic.jms.SessionPoolManager
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.jms.server.JMSManager.getContext(JMSManager.java:851)
    at weblogic.jms.server.JMSManager.initConnectionConsumerManager(JMSManager.java:333)
    at weblogic.jms.server.JMSManager.init(JMSManager.java:310)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<I> <JMS> Bound ConnectionConsumerManager
    as weblogic.jms.ConnectionConsumerManager
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(WLInitialContextFactoryDelegate.java:240)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.t3.srvr.T3Srvr.bindServer(T3Srvr.java:1476)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(Compiled
    Code)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.t3.srvr.T3Srvr.bindServer(T3Srvr.java:1495)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<I> <WebLogicServer> Invoking main-style
    startup RMI Registry weblogic.rmi.internal.RegistryImpl
    Wed Feb 28 12:55:36 EST 2001:<I> <RMI> Registry started
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(Compiled
    Code)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.common.internal.T3BindableServices.initialize(T3BindableServices.java:114)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(WLInitialContextFactoryDelegate.java:279)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(Compiled
    Code)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.ejb.internal.EJBManagerImpl.bindToJNDI(EJBManagerImpl.java:580)
    at weblogic.ejb.internal.EJBManagerImpl.<init>(EJBManagerImpl.java:226)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<E> <EJB> Cannot intialize Mail Session
    resources because could not get JNDI context: javax.naming.NoInitialContextException:
    Cannot instantiate class: weblogic.jndi.WLInitialContextFactory
    [Root exception is java.security.AccessControlException: access
    denied (java.lang.RuntimePermission getClassLoader )]
    Wed Feb 28 12:55:36 EST 2001:<I> <EJB> 0 EJB jar files loaded,
    containing 0 EJBs
    Wed Feb 28 12:55:36 EST 2001:<I> <EJB> 0 deployed, 0 failed to
    deploy.
    Wed Feb 28 12:55:36 EST 2001:<E> <Service>
    java.lang.reflect.InvocationTargetException: java.security.AccessControlException:
    access denied (java.lang.RuntimePermission setContextClassLoader
    at java.lang.Throwable.fillInStackTrace(Native Method)
    at java.lang.Throwable.fillInStackTrace(Compiled Code)
    at java.lang.Throwable.<init>(Compiled Code)
    at java.lang.Exception.<init>(Compiled Code)
    at java.lang.RuntimeException.<init>(Compiled Code)
    at java.lang.SecurityException.<init>(Compiled Code)
    at java.security.AccessControlException.<init>(Compiled Code)
    at java.security.AccessControlContext.checkPermission(Compiled
    Code)
    at java.security.AccessController.checkPermission(Compiled Code)
    at java.lang.SecurityManager.checkPermission(Compiled Code)
    at java.lang.Thread.setContextClassLoader(Compiled Code)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.jndi.internal.Utils.setContextClassLoader(Utils.java:73)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newLocalContext(Compiled
    Code)
    at weblogic.jndi.WLInitialContextFactoryDelegate.newContext(Compiled
    Code)
    at weblogic.jndi.WLInitialContextFactoryDelegate.getInitialContext(Compiled
    Code)
    at weblogic.jndi.Environment.getContext(Environment.java:122)
    at weblogic.jndi.Environment.getInitialContext(Environment.java:105)
    at weblogic.io.common.internal.T3FileSystemProxyImpl.installFileSystems(Compiled
    Code)
    at weblogic.t3.srvr.T3Srvr.start(Compiled Code)
    at weblogic.t3.srvr.T3Srvr.main(T3Srvr.java:825)
    at java.lang.reflect.Method.invoke(Native Method)
    at weblogic.Server.startServerDynamically(Server.java:99)
    at weblogic.Server.main(Server.java:65)
    at weblogic.Server.main(Server.java:55)
    Wed Feb 28 12:55:36 EST 2001:<E> <ServletContext-General> cannot
    make temp directory '/opt/weblogic/myserver/public_html/_tmp_war',
    will not be able to compile JSPs
    Wed Feb 28 12:55:36 EST 2001:<E> <HTTP> Cannot intialize httpd
    URL resources because could not get JNDI context: javax.naming.NoInitialContextException:
    Cannot instantiate class: weblogic.jndi.WLInitialContextFactory
    [Root exception is java.security.AccessControlException: access
    denied (java.lang.RuntimePermission getClassLoader )]
    Lot of thanks for your help.

  • AxisFault: java.lang.reflect.InvocationTargetException

    Hi all,
    this is really really weird.
    I am having a service, where I send files and an own datatype to.
    Well, this all works very fine (after lots of "trial/error" ;-) ).
    But now, I want to use jacksum to compare the checksum of the transferred file and before and after the transfer.
    The strange thing is, the code works when I run the service as a java application.
    But when I call it from my client I get an error in a row which definetly is not wrong!
    The error is (well, this error message really didn't help me at all!):
    AxisFault
    faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
    faultSubcode:
    faultString: java.lang.reflect.InvocationTargetException
    faultActor:
    faultNode:
    faultDetail:
         {http://xml.apache.org/axis/}hostname: r27300
    java.lang.reflect.InvocationTargetException
         at org.apache.axis.message.SOAPFaultBuilder.createFault(SOAPFaultBuilder.java:260)
         at org.apache.axis.message.SOAPFaultBuilder.endElement(SOAPFaultBuilder.java:169)
         at org.apache.axis.encoding.DeserializationContextImpl.endElement(DeserializationContextImpl.java:1015)
         at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
         at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown Source)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
         at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
         at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
         at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
         at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
         at javax.xml.parsers.SAXParser.parse(Unknown Source)
         at org.apache.axis.encoding.DeserializationContextImpl.parse(DeserializationContextImpl.java:242)
         at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:538)
         at org.apache.axis.Message.getSOAPEnvelope(Message.java:376)
         at org.apache.axis.client.Call.invokeEngine(Call.java:2583)
         at org.apache.axis.client.Call.invoke(Call.java:2553)
         at org.apache.axis.client.Call.invoke(Call.java:2248)
         at org.apache.axis.client.Call.invoke(Call.java:2171)
         at org.apache.axis.client.Call.invoke(Call.java:1691)
         at com.libs.serveradmin.util.FileSaving.saveFile(FileSaving.java:75)
         at com.libs.serveradmin.model.UploadFileBean.upload(UploadFileBean.java:508)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
         at java.lang.reflect.Method.invoke(Unknown Source)
         at com.sun.faces.el.MethodBindingImpl.invoke(MethodBindingImpl.java:126)
         at com.sun.faces.application.ActionListenerImpl.processAction(ActionListenerImpl.java:72)
         at javax.faces.component.UICommand.broadcast(UICommand.java:312)
         at javax.faces.component.UIViewRoot.broadcastEvents(UIViewRoot.java:267)
         at javax.faces.component.UIViewRoot.processApplication(UIViewRoot.java:381)
         at com.sun.faces.lifecycle.InvokeApplicationPhase.execute(InvokeApplicationPhase.java:75)
         at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:200)
         at com.sun.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:90)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:197)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
         at com.libs.serveradmin.filter.MultiPartFilter.doFilter(MultiPartFilter.java:50)
         at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
         at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
         at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:214)
         at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
         at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:482)
         at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
         at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
         at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
         at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
         at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:825)
         at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:738)
         at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:526)
         at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
         at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
         at java.lang.Thread.run(Unknown Source)Did anyone have the same problem before and did solve it?
    I can tell you, that all the jars needed are there, because without calculating the checksum the service is called without an error.
    And on the other hand, trying to run my web service as a java application, this works fine aswell.
    Hope, anyone can help me, because I'm really stuck in that problem
    Thanks a lot in advance!
    Steffi

    Yeah I have to agree, it was pretty simple and if you dont understand the concept of a build path within an IDE you probably should be reading some more basic tutorials than those centered around web services.
    That wasnt meant as an insult either, but I doubt you would really understand what it is that you are doing.
    Lots of things could cause an invocation target exception, not just a missing jar file so if you are getting this exception the solution on this page could well be wrong in your situation.
    You should look for the actual cause of this exception on your application server where the web service in exposed from, and\or read the javadoc below.
    [Invocation Target Exception|http://java.sun.com/j2se/1.4.2/docs/api/java/lang/reflect/InvocationTargetException.html]

  • Java.lang.reflect.UndeclaredThrowableException while running client

    Hi
    All I did is that I created and deployed a very simple Stateless session EJB having
    one remote method as follows
    String getProducerName(String)
    Deployment seems to be okay as I can see the deployed EJB, access the client.jar,
    But when I am calling above mentioned method, I receive following errors.
    Please help
    Thanks
    Ratan...
    Scanner has tokens:
    [OPENTAGBEGIN]
    [NAME] (META)
    [NAME] (NAME)
    [CHARDATA] (GENERATOR)
    [NAME] (CONTENT)
    [CHARDATA] (WebLogic htmlKona WebLogic Server 6.1 SP2 12/18/2001
    11:13:46 #
    154529 )
    [TAGEND]
    [SPACE] (
    [CLOSETAGBEGIN]
    [NAME] (HEAD)
    [TAGEND]
    [SPACE] (
    [OPENTAGBEGIN]
    [NAME] (BODY)
    [NAME] (bgcolor)
    [CHARDATA] (white)
    [NAME] (alink)
    [CHARDATA] (#397F70)
    [NAME] (link)
    [CHARDATA] (#640078)
    [NAME] (vlink)
    [CHARDATA] (#DE7E00)
    [TAGEND]
    [SPACE] (
    [OPENTAGBEGIN]
    [NAME] (FONT)
    [NAME] (FACE)
    E7E00">
    <FONT FACE=e <-- bad character
    Exception in thread "main" java.lang.reflect.UndeclaredThrowableException: Error
    at line:
    8 col:13 Line:8 ''' expected, got char[72]
    at weblogic.xml.babel.baseparser.SAXElementFactory.createSAXParseException(SAXEle
    mentFactory.java:60)
    at weblogic.xml.babel.parsers.StreamParser.streamParseSome(StreamParser.java:130)
    at weblogic.xml.babel.parsers.BabelXMLEventStream.parseSome(BabelXMLEventStream.j
    ava:46)
    at weblogicx.xml.stream.XMLEventStreamBase.hasNext(XMLEventStreamBase.java:135)
    at weblogicx.xml.stream.XMLEventStreamBase.hasStartElement(XMLEventStreamBase.jav
    a:258)
    at weblogicx.xml.stream.XMLEventStreamBase.hasStartElement(XMLEventStreamBase.jav
    a:171)
    at weblogicx.xml.stream.XMLEventStreamBase.startElement(XMLEventStreamBase.java:1
    64)
    at weblogic.soap.codec.SoapMessage.read(SoapMessage.java:86)
    at weblogic.soap.WebServiceProxy.receive(WebServiceProxy.java:464)
    at weblogic.soap.WebServiceProxy.invoke(WebServiceProxy.java:430)
    at weblogic.soap.SoapMethod.invoke(SoapMethod.java:186)
    at weblogic.soap.wsdl.WebServiceInvocationHandler.invoke(WebServiceInvocationHand
    ler.java:31)
    at $Proxy0.getProducerName(Unknown Source)
    at WSClient.main(WSClient.java:27)
    [WSClient.java]

    Hi
    Please ignore earlier message.
    I could figure out the problem, it was due to miss match/Typo in URI and message
    was not revealing it. until I scanned through and compared with Examples.
    Thanks
    N'Joy
    Ratan...
    "Ratan" <[email protected]> wrote:
    >
    >
    >
    Hi
    All I did is that I created and deployed a very simple Stateless session
    EJB having
    one remote method as follows
    String getProducerName(String)
    Deployment seems to be okay as I can see the deployed EJB, access the
    client.jar,
    But when I am calling above mentioned method, I receive following errors.
    Please help
    Thanks
    Ratan...
    Scanner has tokens:
    [OPENTAGBEGIN]
    [NAME] (META)
    [NAME] (NAME)
    [CHARDATA] (GENERATOR)
    [NAME] (CONTENT)
    [CHARDATA] (WebLogic htmlKona WebLogic Server 6.1 SP2 12/18/2001
    11:13:46 #
    154529 )
    [TAGEND]
    [SPACE] (
    [CLOSETAGBEGIN]
    [NAME] (HEAD)
    [TAGEND]
    [SPACE] (
    [OPENTAGBEGIN]
    [NAME] (BODY)
    [NAME] (bgcolor)
    [CHARDATA] (white)
    [NAME] (alink)
    [CHARDATA] (#397F70)
    [NAME] (link)
    [CHARDATA] (#640078)
    [NAME] (vlink)
    [CHARDATA] (#DE7E00)
    [TAGEND]
    [SPACE] (
    [OPENTAGBEGIN]
    [NAME] (FONT)
    [NAME] (FACE)
    E7E00">
    <FONT FACE=e <-- bad character
    Exception in thread "main" java.lang.reflect.UndeclaredThrowableException:
    Error
    at line:
    8 col:13 Line:8 ''' expected, got char[72]
    at weblogic.xml.babel.baseparser.SAXElementFactory.createSAXParseException(SAXEle
    mentFactory.java:60)
    at weblogic.xml.babel.parsers.StreamParser.streamParseSome(StreamParser.java:130)
    at weblogic.xml.babel.parsers.BabelXMLEventStream.parseSome(BabelXMLEventStream.j
    ava:46)
    at weblogicx.xml.stream.XMLEventStreamBase.hasNext(XMLEventStreamBase.java:135)
    at weblogicx.xml.stream.XMLEventStreamBase.hasStartElement(XMLEventStreamBase.jav
    a:258)
    at weblogicx.xml.stream.XMLEventStreamBase.hasStartElement(XMLEventStreamBase.jav
    a:171)
    at weblogicx.xml.stream.XMLEventStreamBase.startElement(XMLEventStreamBase.java:1
    64)
    at weblogic.soap.codec.SoapMessage.read(SoapMessage.java:86)
    at weblogic.soap.WebServiceProxy.receive(WebServiceProxy.java:464)
    at weblogic.soap.WebServiceProxy.invoke(WebServiceProxy.java:430)
    at weblogic.soap.SoapMethod.invoke(SoapMethod.java:186)
    at weblogic.soap.wsdl.WebServiceInvocationHandler.invoke(WebServiceInvocationHand
    ler.java:31)
    at $Proxy0.getProducerName(Unknown Source)
    at WSClient.main(WSClient.java:27)

  • Java.lang.reflect.InnvokationTargetException

    Hello everybody,
    I am getting following error logs while executing my swing application.
    java.lang.reflect.InnvokationTargetException
    at sun.reflect.delegatingMethodAccessorImpl.invoke
    (DelegatingMethodAccessorImpl.java:25)
    at java.lang.reflect.Method.invoke(Mehod:java:324)
    I am trying to call some class's method using reflection principle.
    All values of acces modifier, return type, method name, args are correct at run time. I don't understand why i am getting this error.
    Can anybody please help me.
    Thanks and regards
    Girish Varde

    I would say that this sentence is rather confusing since you get the exception nonetheless.The sentence means when I am in debug mode and check value of the actual class whose method is called, the class value is correct. It's not that the class whose method I am calling does not exist.
    First I give the reference error log which you can use to locate at what point the exception is thrown.
    java.lang.reflect.InvocationTargetException
         at sun.reflect.GeneratedMethodAccessor74.invoke(Unknown Source)
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
         at java.lang.reflect.Method.invoke(Method.java:324)
         at com.apsiva.commframework.server.Communicator.processRequest(Communicator.java:45)
         at com.apsiva.commframework.server.CommunicationServlet.processRequest(CommunicationServlet.java:92)
         at com.apsiva.commframework.server.CommunicationServlet.doPost(CommunicationServlet.java:30)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:763)
    public class Communicator implements java.io.Serializable{
         public static final String DECENTRALIZED_MODE = "decentralizedMode";
         //applicationMode could be localMode or distributedMode or decentralizedMode
         public static final String DISTRIBUTED_MODE = "distributedMode";
         public static final String LOCAL_MODE = "localMode";
          * Communicator constructor comment.
         public Communicator() {
              super();
    public Object processRequest(Request request) throws java.lang.Exception {
         Object obj = null;
         try
              String str = request.getActionCode();
              System.out.println("Printing str : " + str);
              if (str == null)
                   return null;
              Class cls = ActionCodes.class;
              Field f = cls.getField(str);
              String actionClassName = (String)f.get(null);
              if (actionClassName == null)
                   return null;
              cls = Class.forName(actionClassName);
              Object actionObj = cls.newInstance();
              System.out.println("Printing  actionClassName : " + actionClassName);
              Method mthd = cls.getMethod("processRequest", new Class[]{Request.class}); 
              System.out.println("Printing  mthd : " + mthd);
              obj = mthd.invoke(actionObj, new Object[]{request});   // line 45
              return obj;     
         } catch (Exception e)
              e.printStackTrace();
              throw e;
    public class CommunicationServlet extends HttpServlet{
         private Communicator communicator = null;
    public void doGet(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException {
         doPost(req,res);
         }//end of doGet
    public void doPost(HttpServletRequest req, HttpServletResponse res) throws ServletException, IOException {
         res.setContentType("text/html");
         Response response = null;
         OutputStream o = null;
         try{
              Request request = getSerializedRequest(req);
              //logString("The seriliazed object is: " + request.toString());
              response = (Response)processRequest(request);
              o = res.getOutputStream();
              sendSerializedResponse(o, response);
         }catch(Exception e){
              e.printStackTrace();
              try{
                   if(o != null)sendSerializedResponse(o, e);
                   else {
                        o = res.getOutputStream();
                        sendSerializedResponse(o, e);
              }catch(Exception ignor){
                   ignor.printStackTrace();
         }//end of doPost
    public Communicator getCommunicator() {
         return new Communicator();
    private HashMap getParams(HttpServletRequest req){
         Enumeration enu = req.getParameterNames();     
         HashMap map = new HashMap();
         while(enu.hasMoreElements()){
              String name = (String)enu.nextElement();
              String value = req.getParameter(name);
              if(name != null && !name.equals("") && value != null){
                   map.put(name, value);
              }//end of if
         }//end while
         return map;
         }//end of getParams
    private Request getSerializedRequest(HttpServletRequest req) throws Exception{
         log("start getSerializedRequest()");
         Request request = null;
         try{
              ObjectInputStream oIn = new ObjectInputStream(req.getInputStream());
              Object o = oIn.readObject();
              oIn.close();
              request = (Request)o;
              return request;     
         }catch(Exception e){
              logString("CommunicationServlet cannot receive serialized object.");     
              e.printStackTrace();
              throw e;
    }//end of getRequest
    private void logString(Object s){
         if(s != null) System.out.println(s);
         else System.out.println("Received null object.");
    public Object processRequest(Request request) throws Exception {
         return  this.getCommunicator().processRequest(request);        // line 92
    private void sendSerializedResponse(OutputStream o, Object resp) throws Exception{
         if(o != null){
              ObjectOutputStream oOut = new ObjectOutputStream(o);
              oOut.writeObject(resp);
              oOut.flush();
              oOut.close();
    public void setCommunicator(Communicator newCommunicator) {
         communicator = newCommunicator;
    }

  • JSWDP 1.1 - wsdeploy error: java.lang.reflect.InvocationTargetException

    Ok - All help is really appreciated!
    I'll get the configuration questions out of the way first...I'm using:
    JWSDP 1.1
    JDK 1.3.1_08
    J2EE 1.3.1
    I've been able to successfully run the "Hello World" example provided by the JWSDP 1.1 tutorial. I'm now trying to generate a WSDL using an interface that had worked with JWSDP 1.0 EA, but I'm getting the following error:
    process-war:
    [echo] Running wsdeploy....
    [echo] CLASSPATH=C:\ATG\DAS6.2.0\DAS\lib\classes.jar:D:\j2sdkee1.3.1\lib\j2ee.jar:C:\ATG\ATG6.2.0\CIWS\lib\cacjdbc.jar:C:\ATG\ATG6.2.0\CIWS\lib\CIWS_JAXB.jar:C:\ATG\ATG6.2.0\CIWS\lib\oromatcher.jar:C:\ATG\ATG6.2.0\CIWS\lib\classes12.zip:C:\ATG\ATG6.2.0\CIWS\j2ee-apps\ciws\java-code:C:\ATG\ATG6.2.0\CIWS\j2ee-apps\ciws\web-app\WEB-INF\classes
    [exec] info: created temporary directory: D:\ciws-ws\ciws\build\wsdeploy-generated\jaxrpc-deploy-615014
    [exec] java.lang.reflect.InvocationTargetException: java.lang.NoClassDefFoundError: javax/ejb/CreateException
    [exec] at java.lang.Class.getMethods0(Native Method)
    [exec] info: processing endpoint: ciws
    [exec] at java.lang.Class.getMethods(Class.java:737)
    [exec] at com.sun.xml.rpc.processor.modeler.rmi.RmiModeler.processInterface(RmiModeler.java:270)
    [exec] at com.sun.xml.rpc.processor.modeler.rmi.RmiModeler.modelPort(RmiModeler.java:232)
    [exec] at com.sun.xml.rpc.processor.modeler.rmi.RmiModeler.buildModel(RmiModeler.java:195)
    [exec] at com.sun.xml.rpc.processor.config.ModelInfo.buildModel(ModelInfo.java:85)
    [exec] at com.sun.xml.rpc.processor.Processor.runModeler(Processor.java:61)
    [exec] at com.sun.xml.rpc.tools.wscompile.CompileTool.run(CompileTool.java:368)
    [exec] at com.sun.xml.rpc.tools.wsdeploy.DeployTool.process(DeployTool.java:259)
    [exec] at com.sun.xml.rpc.tools.wsdeploy.DeployTool.process(DeployTool.java:229)
    [exec] at com.sun.xml.rpc.tools.wsdeploy.DeployTool.run(DeployTool.java:182)
    [exec] at com.sun.xml.rpc.util.ToolBase.run(ToolBase.java:41)
    [exec] at com.sun.xml.rpc.tools.wsdeploy.Main.main(Main.java:24)
    [exec] at java.lang.reflect.Method.invoke(Native Method)
    [exec] at org.apache.commons.launcher.ChildMain.run(ChildMain.java:269)
    [exec] Result: 1
    Here are my configuration files:
    common/build.properties
    #  This file contains properties common to the tutorial examples
    #  for JAX-RPC.
    jwsdp.home=D:\\jwsdp-1.1
    tut-root=${jwsdp.home}/docs
    # tut-root=D:\\wspack-docs
    build=build
    url=http://localhost:8080/manager
    jaxrpc.home=${jwsdp.home}/jaxrpc-1.0.3
    jaxp.holme=${jwsdp.home}/jaxp-1.2.2
    saaj.home=${jwsdp.home}/saaj-1.1.1
    wscompile-path=${jaxrpc.home}/bin
    rlib=${jaxrpc.home}/lib
    plib=${jaxp.home}/lib
    pelib=${jaxp.home}/lib/endorsed
    slib=${saaj.home}/lib
    wlib=${jwsdp.home}/jwsdp-shared/lib
    rjars=${rlib}/jaxrpc-api.jar:${rlib}/jaxrpc-ri.jar
    pjars=${plib}/jaxp-api.jar
    pejars=${pelib}/xercesImpl.jar:${pelib}/xalan.jar:${pelib}/xsltc.jar:${pelib}/dom.jar:${pelib}/sax.jar
    sjars=${slib}/saaj-api.jar:${slib}/saaj-ri.jar:${slib}/dom4j.jar
    wjars=${wlib}/jax-qname.jar:${wlib}/commons-logging.jar:${wlib}/mail.jar:${wlib}/activation.jar
    jwsdp-jars=${rjars}:${pjars}:${pejars}:${sjars}:${wjars}
    build.properties
    # This file is referenced by the build.xml file.
    atg-home=C:\\ATG
    ciws-home=${atg-home}\\ATG6.2.0\\CIWS
    example=ciws
    context-path=ciws
    package-name=/com/enc/ciws/wrapper
    client-class=com.enc.ciws.client.CiwsClient
    client-jar=${example}-client.jar
    portable-war=${example}-portable.war
    deployable-war=${context-path}.war
    # ORIGINAL --> war-path=${tut-root}/tutorial/examples/jaxrpc/${example}/dist/${deployable-war}
    war-path=D:\\ciws-ws\\ciws\\dist\\${deployable-war}
    atg-das-jar=${atg-home}\\DAS6.2.0\\DAS\\lib\\classes.jar
    j2ee-jar=D:\\j2sdkee1.3.1\\lib\\j2ee.jar
    ciws-jars=${ciws-home}\\lib\\cacjdbc.jar:${ciws-home}\\lib\\CIWS_JAXB.jar:${ciws-home}\\lib\\oromatcher.jar:${ciws-home}\\lib\\classes12.zip
    ciws-classes=${ciws-home}\\j2ee-apps\\ciws\\java-code:${ciws-home}\\j2ee-apps\\ciws\\web-app\\WEB-INF\\classes
    custom-classpath=${atg-das-jar}:${j2ee-jar}:${ciws-jars}:${ciws-classes}
    build.xml
    <!DOCTYPE project [
      <!ENTITY commonTargets SYSTEM "./ciws-targets.xml">
    ]>
    <project name="JAX-RPC Tutorial" default="build" basedir=".">
      <property file="${user.home}/build.properties"/>
      <property file="../common/build.properties"/>
      <property file="build.properties"/>
      &commonTargets; <!-- The ant targets are in ../common/targets.xml -->
      <target name="build" depends="build-service"
         description="Executes the targets needed to build the service.">
      </target>
    </project>
    config.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <configuration
         xmlns="http://java.sun.com/xml/ns/jax-rpc/ri/config">
         <wsdl location="http://localhost:8080/ciws/ciws?WSDL" packageName="com.enc.ciws.wrapper"/>
    </configuration>
    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/j2ee/dtds/web-app_2_3.dtd">
    <web-app>
      <display-name>CIWS</display-name>
      <description>A web application containing a JAX-RPC endpoint for CIWS</description>
      <session-config>
        <session-timeout>60</session-timeout>
      </session-config>
    </web-app>
    jaxrpc-ri.xml
    <?xml version="1.0" encoding="UTF-8"?>
    <webServices
        xmlns="http://java.sun.com/xml/ns/jax-rpc/ri/dd"
        version="1.0"
        targetNamespaceBase="http://com.test/wsdl"
        typeNamespaceBase="http://com.test/types"
        urlPatternBase="/ws">
        <endpoint
            name="ciws"
            displayName="CIWS"
            description="A web service to inquiry about claims"
            interface="com.enc.ciws.wrapper.CIWSWrapper" 
            implementation="com.enc.ciws.wrapper.CIWSWrapperImpl"/>
        <endpointMapping endpointName="ciws" urlPattern="/ciws"/>
    </webServices>
    Snippets of ant script (ciws-targets.xml)
      <target name="process-war" depends="set-ws-scripts"
          description="Runs wsdeploy to generate the ties and create a deployable WAR file">
          <echo message="Running wsdeploy...."/>
          <echo message="CLASSPATH=${custom-classpath}"/>
          <delete file="dist/${deployable-war}" />
       <exec executable="${wsdeploy}">
          <arg line="-verbose"/>
          <arg line="-keep"/>
          <arg line="-tmpdir"/>
          <arg line="${build}/wsdeploy-generated"/>
          <arg line="-classpath"/>
          <arg line="${custom-classpath}"/>
          <arg line="-o"/>
          <arg line="dist/${deployable-war}"/>
          <arg line="dist/${portable-war}"/>
        </exec>
      </target>
    And finally the code!! (I know, I know...probably not good with all the exceptions)
    package com.enc.ciws.wrapper;
    import java.rmi.Remote;
    import java.rmi.RemoteException;
    public interface CIWSWrapper extends java.rmi.Remote {
        String getAdjusterInfo(String claimInquiryRS) throws java.rmi.RemoteException;
        String getClaimDetail(String requestString)
            throws
                java.rmi.RemoteException,
                java.io.IOException,
                javax.xml.bind.ValidationException,
                javax.xml.bind.UnmarshalException,
                javax.ejb.CreateException,
                javax.naming.NamingException,
                com.enc.ciws.utils.exception.InvalidRequestException;
        String getClaimHistory(String requestString) throws java.rmi.RemoteException;
        String getClaimSummaryByPolicyHolderInfo(String claimInquiryRS)
            throws
                java.rmi.RemoteException,
                java.io.IOException,
                java.text.ParseException,
                javax.xml.bind.ValidationException,
                javax.xml.bind.UnmarshalException,
                javax.ejb.CreateException,
                javax.naming.NamingException,
                com.enc.ciws.utils.exception.InvalidRequestException;
        String getClaimSummaryByPolicyNumber(String claimInquiryRS)
            throws
                java.rmi.RemoteException,
                java.io.IOException,
                javax.xml.bind.ValidationException,
                javax.xml.bind.UnmarshalException,
                javax.ejb.CreateException,
                javax.naming.NamingException,
                com.enc.ciws.utils.exception.InvalidRequestException;
        String getClaimSummaryByStatus(String claimInquiryRS)
            throws
                java.rmi.RemoteException,
                java.io.IOException,
                java.text.ParseException,
                javax.xml.bind.ValidationException,
                javax.xml.bind.UnmarshalException,
                javax.ejb.CreateException,
                javax.naming.NamingException,
                com.enc.ciws.utils.exception.InvalidRequestException;
        public String getPaymentDetail(String requestString)
            throws java.rmi.RemoteException;
        String getSubroDetail(String requestString)
            throws
                java.rmi.RemoteException,
                java.io.IOException,
                javax.xml.bind.ValidationException,
                javax.xml.bind.UnmarshalException,
                javax.ejb.CreateException,
                javax.naming.NamingException,
                com.enc.ciws.utils.exception.InvalidRequestException;
    }

    try just using the wscompile.bat/.sh commandline tool first. It will automatically setup the classes used
    by wscompile and jaxrpc, you will only then need to specify the classpath to your classes on the
    commandline. This might help you isolate the problem so you can fix the ant tasks.

  • Webapp wont start - java.lang.reflect.InvocationTargetException

    Hi
    I'm having a problem getting my own web applications to start (the tomcat one's run fine). It fails when reading my web.xml file. First off here is my environment:
    OS: Linux
    SDK: 1.4.1_02
    Container: Tomcat 4.1.18
    I created a small HelloWorld application to see if it will give me the same result, unfortunately it did. Below is the error msg from the log as well as the content of my web.xml file. Please see my additional comment below the error ...
    The web.xml file:<?xml version="1.0" encoding="ISO-8859-1"?>
    <!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>
         <servlet>
              <servlet-name>HelloWorld</servlet-name>
              <servlet-class>HelloWorld</servlet-class>
         </servlet>
         <servlet-mapping>
              <servlet-name>HelloWorld</servlet-name>
              <url-pattern>HelloWorld</url-pattern>
         </servlet-mapping>
    </web-app>
    Error msg in log file:
    2003-04-01 19:13:54 ContextConfig[test] Parse error in application web.xml
    java.lang.reflect.InvocationTargetException
         at org.apache.commons.digester.Digester.createSAXException(Digester.java:2312)
         at org.apache.commons.digester.Digester.createSAXException(Digester.java:2332)
         at org.apache.commons.digester.Digester.endElement(Digester.java:1039)
         at org.apache.xerces.parsers.AbstractSAXParser.endElement(AbstractSAXParser.java:585)
         at org.apache.xerces.impl.XMLNamespaceBinder.endElement(XMLNamespaceBinder.java:647)
         at org.apache.xerces.impl.dtd.XMLDTDValidator.handleEndElement(XMLDTDValidator.java:1937)
         at org.apache.xerces.impl.dtd.XMLDTDValidator.endElement(XMLDTDValidator.java:851)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanEndElement(XMLDocumentFragmentScannerImpl.java:1008)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1469)
         at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:329)
         at org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:525)
         at org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:581)
         at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:152)
         at org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1175)
         at org.apache.commons.digester.Digester.parse(Digester.java:1495)
         at org.apache.catalina.startup.ContextConfig.applicationConfig(ContextConfig.java:282)
         at org.apache.catalina.startup.ContextConfig.start(ContextConfig.java:639)
         at org.apache.catalina.startup.ContextConfig.lifecycleEvent(ContextConfig.java:243)
         at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:166)
         at org.apache.catalina.core.StandardContext.start(StandardContext.java:3567)
         at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:821)
         at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:807)
         at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:579)
         at org.apache.catalina.core.StandardHostDeployer.install(StandardHostDeployer.java:257)
         at org.apache.catalina.core.StandardHost.install(StandardHost.java:772)
         at org.apache.catalina.startup.HostConfig.deployDirectories(HostConfig.java:569)
         at org.apache.catalina.startup.HostConfig.deployApps(HostConfig.java:411)
         at org.apache.catalina.startup.HostConfig.start(HostConfig.java:879)
         at org.apache.catalina.startup.HostConfig.lifecycleEvent(HostConfig.java:368)
         at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent(LifecycleSupport.java:166)
         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1196)
         at org.apache.catalina.core.StandardHost.start(StandardHost.java:738)
         at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1188)
         at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:347)
         at org.apache.catalina.core.StandardService.start(StandardService.java:497)
         at org.apache.catalina.core.StandardServer.start(StandardServer.java:2189)
         at org.apache.catalina.startup.Catalina.start(Catalina.java:512)
         at org.apache.catalina.startup.Catalina.execute(Catalina.java:400)
         at org.apache.catalina.startup.Catalina.process(Catalina.java:180)
         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:324)
         at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:203)
    2003-04-01 19:13:54 ContextConfig[test]: Occurred at line 16 column 20
    2003-04-01 19:35:59 ContextConfig[test]: Marking this application unavailable due to previous error(s)
    Line 16 column 20 is the character after the </servlet-mapping> tag. Why is it doing this? I've recreated web.xml a couple of times from scratch, thinking that it might be some weird character in the file that is not visible. I've also set the encoding to UTF-8, but it just keeps on failing when it gets to the first closing servlet-mapping tag. Am I missing something or is this some weird bug?
    Any help would be greatly appreciated!

    Hmmm....I don't see anything wrong with the web.xml file. Perhaps Tomcat can't find your, "HelloWorld" class?
    1. Did you set the classpath correctly?
    2. Did you declare the name of the class correctly in the web.xml file's servlet-class element (i.e. full package naming)?

Maybe you are looking for

  • Error in saving and Project Siena close/crash

    I am new to Project Siena and when I try to save my work, I receive an error: "Error: test.siena cannot be saved. The file may be in use by another application" Another problem is when I load a WADL, the Project Sienna closes or crashes. The WADL I a

  • Images are not displayed in Outlook 2010, Win 7 64 bit

    Dear Sirs, I ask for help! I can not manage to set the display of images in Outlook 2010. I tried everything suggested on this forum, but nothing helped me to solve the problem. It seems to me that the problem is in software. Any advice is welcome. T

  • Db tables

    hi experts we have an ztable(zvcustomer),in that ztable there are 2 fileds customer id and transaction time",one customer may have multiple  "transaction time",based on customer id i have to pick the  maximum or minimum  "transaction time". plse help

  • Flash CS5.5: Loading XML-file causes a "Security Sandbox Violation"

    Hi, after upgrading from CS3 to CS5.5, i get a "Security Sandbox Violation" when loading a XML-file. With CS3 everything was fine, but now my file is not working any more. The XML-file and my SWF-file are stored in the same directory and it nether wo

  • PLEASE FAST TELL ME STUFFS!

    WHAT AND HOW DO I USE BEANS TO WRITE REUSABLE COMPONENTS?! because i read somewhere that you can write gui components using beans and they will "plug in" to your app. but how does your app know how they plug in and what methods to call?! please reply