Exceptions thrown in Thread Constructors

Hi,
Im having a problem with exceptions been thrown during thread constructors... mainly that when it happens, the JVM still seems to track the dud thread as an active thread (See example code below).
As you can see, the thread throws an exception during creation, and hence never gets created as such (mt stays null). Yet Thread.activeCount() reports that its still hanging around somewhere, yet it cant be referenced. Unfortunately this is resulting in me getting a rather large buildup of these duds, as its part of a "retry" phase in my software.
Any thoughts/comments/suggestions?
Thanks,
Roger.
import java.net.Socket;
public class myMain
    public myMain()
        myThread mt=null;
        while (true) try
            System.out.println(Thread.activeCount());
            Thread.sleep(100);
            mt = new myThread();
        catch (Exception ex)
            System.out.println(mt);
            System.err.println(ex);
    public static void main (String[] args)
        new myMain();
public class myThread extends Thread
    public myThread() throws Exception
        throw new Exception();
}

It's not hard to obtain this reference (for instance we can catch exception in the constructor and do something before rethrowing it) - but what can we do with this reference? There's no way to destroy the thread object save starting it. But this is really ugly (but works):
public class NewThreadException {
     public static class myThread extends Thread {
          protected boolean stillborn;
         public myThread() throws Exception
              super(new ThreadGroup("My Group"), "My Thread");
              try {
                  throw new Exception();
              } catch (Exception e) {
                   stillborn=true;
                   start();
                   throw e;
         public void run() {
              if (stillborn) return;
     public static void main(String[] args) {
        myThread mt=null;
        while (true) try
            System.out.println(Thread.activeCount());
            Thread.sleep(100);
            mt = new myThread();
        catch (Exception ex)
            System.out.println(mt);
            System.err.println(ex);
}BTW there's already one private stillborn in Thread class itself.

Similar Messages

  • Exception thrown at the constructor

    Does that mean the class cannot be statically initialized like this:
    class B {
    public static final A a = new A("aaa");
    while
    class A {
    public A(String _a) throws Exception {
    I see no way out. Any idea?
    Thx

    I'm unable to produce the behavior you're talking about. The Exceptions get reported in both static and instance initializer blocks.Whoops. I lie. ExceptionInInitializerError gets thrown on first reference to the class. Only on subsequent references is NoClassDefFoundErrors thrown.
    The scenario where I usually see it is this : some non-critical path in a big system references a class first, fails in the initializer, logs a warning and aborts. Then a critical path tries to use the same class, bombs with a NoClassDefFoundError and leaves everyone scratching their heads ("but I can see it, it is there").
    You could say that better programming discipline would ensure that the problem got reported as fatal earlier on, with an informative ExceptionInInitializerError. In reality this often does not happen. This is the reason I dislike complex static initializers.

  • Catching an exception thrown from another thread

    I have a SocketServer that creates new threads to handle incoming clients. If one of the threads throw a SQLException is it possible to catch that exception in the SocketServer that created that thread.
    I tried implementing this code and I cannot get the server to catch an exception thrown in the thread. Are my assumptions correct?
    I was reading something about Thread Groups and implementing an uncoughtException() method, but this looked like overkill.
    Thanks for your time!
    Some Example code would be the following where the ClientThread will do a database query which could cause an SQLException. I'd like to catch that exception in my Socket Server
          try
                 new ClientThread( socketServer.accept() , host, connection ).start();
          catch( SQLException e )
                 System.out.println( "DataSource Connection Problem" );
                  e.printStackTrace();
          }

    hehe, why?
    The server's job is to listen for an incoming message from a client and pass it off to a thread to handle the client. Otherwise the server will have to block on that incoming port untill it has finished handling the client and usually there are many incoming clients continuously.
    The reason I would want to catch an exception in the server based on the SQLException thrown in the thread is because the SQLException is usually going to be due to the fact the datasource connection has become unavalable, or needs to be refreshed. This datasource connection is a private variable stored in the socket server. The SocketServer now needs to know that it has to refresh that datasource connection. I would normally try to use somesort of flag to set the variable but to throw another wrench into my dilemma, the SocketServer is actually its own thread. So I can't make any of these variables static, which means I can't have the thread call a method on teh socket server to change the status flag. :)
    I guess I need implement some sort of Listener that the thread can notify when a datasource connection goes down?
    Thanks for the help so far, I figured java would not want one thread to catch another thread's exceptions, but I just wanted to make sure.

  • Know Exceptions thrown in Java Finalizer thread...

    Hello,
    I have one question regarding java finalizer thread.
    How can i know about exceptions thrown by finalize method which has been called from the finalizer thread of JVM?.
    Any help would be appreciated?
    Thanks and Regards

    vinodpatel2006 wrote:
    Hello,
    Thanks for reply...
    But why i can't? There must be some mechanisum using i can know thrown exception.No
    >
    Because, in my application, i am writing finalize methods for each and every object to null out the member variable. I want to make sure that each of those methods work perfactly. I mean, does any of them throws exception OR not.What? Why are you doing that? That sounds pretty stupid. The GC will take care of those objects.
    Kaj

  • Handling Exceptions thrown by EDT Thread?

    Hi,
    How to handle exceptions thrown by EDT Thread?. If anybody can give any link or any example, then it really helpful.
    Thanks

    System.setProperty( "sun.awt.exception.handler", EventThreadExceptionHandler.class.getName() );

  • Lots of exceptions thrown

    Hi,
    We are switching to test our codes based on JRockitRealTime 3.0.0, 1.6, linux 64 from Sun HotSpot.
    We notice a quite a few things are significant slower when compared to the results based on HotSpot.
    Turning on the Xverbose:exceptions=debug, we see lots of exceptions thrown, the following is just 1 example of many (with different kinds of stack trace too). And we believe they are the main cause to the slowdown. Can you help explain why we're getting the exceptions and how to resolve them? We did not see the exceptions from running HotSpot JVM, and looks like there is no need/way to turn on the exception traces from HotSpot HVM so we assume there were no exceptions thrown when we ran our applications based on HotSpot JVM. Interestingly, even with the exceptions looks like our applications still function ok, that make me to think is it this something internal to JRockit?
    Regards,
    Jasper
    [DEBUG][excepti][00180] java/lang/NoSuchMethodException: java.lang.String.clone()^M
    at jrockit/vm/Reflect.fillInStackTrace0(Ljava/lang/Throwable;)V(Native Method)^M
    at java/lang/Throwable.fillInStackTrace()Ljava/lang/Throwable;(Native Method)^M
    at java/lang/Throwable.<init>(Throwable.java:196)^M
    at java/lang/Exception.<init>(Exception.java:41)^M
    at java/lang/NoSuchMethodException.<init>(NoSuchMethodException.java:32)^M
    at java/lang/Class.getMethod(Class.java:1605)^M
    at com/tangosol/run/xml/PropertyAdapter.<init>(PropertyAdapter.java:152)^M
    at com/tangosol/run/xml/SimpleAdapter.<init>(SimpleAdapter.java:59)^M
    at com/tangosol/run/xml/SimpleAdapter$StringAdapter.<init>(SimpleAdapter.java:1415)^M
    at jrockit/vm/RNI.c2java(JJJJJ)V(Native Method)^M
    at jrockit/vm/Reflect.invokeMethod(Ljava/lang/Object;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;(Native Method)^M
        at sun/reflect/NativeConstructorAccessorImpl.newInstance0(Ljava/lang/reflect/Constructor;[Ljava/lang/Object;)Ljava/lang/Object;(Native Method)^M
        at sun/reflect/NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)^M
        at sun/reflect/DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)^M
        at java/lang/reflect/Constructor.newInstance(Constructor.java:513)^M
        at com/tangosol/run/xml/XmlBean$BeanInfo.makeAdapter(XmlBean.java:1141)^M
        at com/tangosol/run/xml/XmlBean$BeanInfo.<init>(XmlBean.java:966)^M
        at com/tangosol/run/xml/XmlBean.initBeanInfo(XmlBean.java:874)^M
        at com/tangosol/run/xml/XmlBean.findBeanInfo(XmlBean.java:814)^M
        at com/tangosol/run/xml/XmlBean.getBeanInfo(XmlBean.java:362)^M
        at com/tangosol/util/ExternalizableHelper.writeXmlBean(ExternalizableHelper.java:2009)^M
        at com/tangosol/util/ExternalizableHelper.internalWriteObject(ExternalizableHelper.java:2505)^M
        at com/tangosol/util/ExternalizableHelper.toBinary(ExternalizableHelper.java:169)^M
        at com/tangosol/coherence/component/util/daemon/queueProcessor/service/DistributedCache$ConverterKeyToBinary.convert(DistributedCache.CDB:30)^M
        at com/tangosol/util/ConverterCollections$ConverterMap.put(ConverterCollections.java:1317)^M
        at com/tangosol/coherence/component/util/daemon/queueProcessor/service/DistributedCache$ViewMap.put(DistributedCache.CDB:1)^M
        at com/tangosol/coherence/component/util/SafeNamedCache.put(SafeNamedCache.CDB:1)^M
        at com/oracle/ngc/prototype/platform/CacheHelper.createObject(CacheHelper.java:808)^M
        at com/oracle/ngc/prototype/object/Account.BulkCreate(Account.java:186)^M    at com/oracle/ngc/prototype/loader/PopulateSubscriptionCache$LoadDaemon.run(PopulateSubscriptionCache.java:379)^M
        at com/tangosol/util/Daemon$DaemonWorker.run(Daemon.java:519)^M
        at java/lang/Thread.run(Thread.java:619)^M
        at jrockit/vm/RNI.c2java(JJJJJ)V(Native Method)^M
        --- End of stack trace^M                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

    Turning on exception printouts with -Xverbose:exceptions will print out all exceptions being thrown, whether they are caught or not. It is not unusal for programs to cause execptions as part of their normal execution and to catch them silently. -Xverbose:exceptions is primarily a debugging and supportability tool.
    Thus, it is highly likely that the same number of exceptions are thrown when running with Hotspot, but there are no debugging tools available for Hotspot that will show these exceptions.
    To analyze the slow down you are seeing, I would suggest that you do a JRA profiler recording (part of JRockit Mission Control) and see if there is anything in that data that looks suspicious (such as long GC pauses or method bottlenecks).
    Regards,
    /Staffan

  • Lots of exceptions thrown with JRockit JVM

    Hi,
    We are switching to test our codes based on JRockitRealTime 3.0.0, 1.6, linux 64 from Sun HotSpot.
    Our Coherence version is 3.3.1
    We notice a quite a few things are significant slower when compared to the results based on HotSpot.
    Turning on the Xverbose:exceptions=debug, we see lots of exceptions thrown, the following is just 1 example of many (with different kinds of stack trace too) related to Coherence API calls. And we believe they are the main cause to the slowdown. Has this kind of problem observed and reported to Coherence before? We did not see the exceptions from running HotSpot JVM, and looks like there is no need/way to turn on the exception traces from HotSpot HVM so we assume there were no exceptions thrown when we ran our applications based on HotSpot JVM.
    Regards,
    Jasper
    DEBUGexcepti00180 java/lang/NoSuchMethodException: java.lang.String.clone()^M
    at jrockit/vm/Reflect.fillInStackTrace0(Ljava/lang/Throwable;)V(Native Method)^M
    at java/lang/Throwable.fillInStackTrace()Ljava/lang/Throwable;(Native Method)^M
    at java/lang/Throwable.<init>(Throwable.java:196)^M
    at java/lang/Exception.<init>(Exception.java:41)^M
    at java/lang/NoSuchMethodException.<init>(NoSuchMethodException.java:32)^M
    at java/lang/Class.getMethod(Class.java:1605)^M
    at com/tangosol/run/xml/PropertyAdapter.<init>(PropertyAdapter.java:152)^M
    at com/tangosol/run/xml/SimpleAdapter.<init>(SimpleAdapter.java:59)^M
    at com/tangosol/run/xml/SimpleAdapter$StringAdapter.<init>(SimpleAdapter.java:1415)^M
    at jrockit/vm/RNI.c2java(JJJJJ)V(Native Method)^M
    at jrockit/vm/Reflect.invokeMethod(Ljava/lang/Object;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;(Native Method)^M
    at sun/reflect/NativeConstructorAccessorImpl.newInstance0(Ljava/lang/reflect/Constructor;[Ljava/lang/Object;)Ljava/lang/Object;(Native Method)^M
    at sun/reflect/NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:39)^M
    at sun/reflect/DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:27)^M
    at java/lang/reflect/Constructor.newInstance(Constructor.java:513)^M
    at com/tangosol/run/xml/XmlBean$BeanInfo.makeAdapter(XmlBean.java:1141)^M
    at com/tangosol/run/xml/XmlBean$BeanInfo.<init>(XmlBean.java:966)^M
    at com/tangosol/run/xml/XmlBean.initBeanInfo(XmlBean.java:874)^M
    at com/tangosol/run/xml/XmlBean.findBeanInfo(XmlBean.java:814)^M
    at com/tangosol/run/xml/XmlBean.getBeanInfo(XmlBean.java:362)^M
    at com/tangosol/util/ExternalizableHelper.writeXmlBean(ExternalizableHelper.java:2009)^M
    at com/tangosol/util/ExternalizableHelper.internalWriteObject(ExternalizableHelper.java:2505)^M
    at com/tangosol/util/ExternalizableHelper.toBinary(ExternalizableHelper.java:169)^M
    at com/tangosol/coherence/component/util/daemon/queueProcessor/service/DistributedCache$ConverterKeyToBinary.convert(DistributedCache.CDB:30)^M
    at com/tangosol/util/ConverterCollections$ConverterMap.put(ConverterCollections.java:1317)^M
    at com/tangosol/coherence/component/util/daemon/queueProcessor/service/DistributedCache$ViewMap.put(DistributedCache.CDB:1)^M
    at com/tangosol/coherence/component/util/SafeNamedCache.put(SafeNamedCache.CDB:1)^M
    at com/oracle/ngc/prototype/platform/CacheHelper.createObject(CacheHelper.java:808)^M
    at com/oracle/ngc/prototype/object/Account.BulkCreate(Account.java:186)^M at com/oracle/ngc/prototype/loader/PopulateSubscriptionCache$LoadDaemon.run(PopulateSubscriptionCache.java:379)^M
    at com/tangosol/util/Daemon$DaemonWorker.run(Daemon.java:519)^M
    at java/lang/Thread.run(Thread.java:619)^M
    at jrockit/vm/RNI.c2java(JJJJJ)V(Native Method)^M
    --- End of stack trace^M                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

    Hi Jasper,
    First, I'd like to underscore that what you see are exceptions that are expected and handled gracefully by the standard Java serialization or Coherence classes.
    The reason you don't see those exceptions with Sun's JVM is that it does not have an option (at least to my knowledge) to show them. This is a very nice debugging feature of JRockit that allows you to see what is going on (and always has been!) under the hood.
    The example you gave is a part of the XmlBean introspection logic checking for a public "clone" method. This code runs once per a class initialization as a part of the static initializer and, as a result, does not impact an application performance. However, if you see exceptions that are occurring constantly, it definitely should be of concern.
    Regards,
    Gene

  • Possible to determine exception thrown in a finally block?

    I believe the answer to this is 'no', but I thought I would ask just to confirm.
    If an exception is thrown in a try block, is there a way in the finally block to determine what exception was thrown? I tried using Throwable#fillinStackTrace and Thread#getStackTrace and did not get anywhere. I did see other methods like Thread#getAllStackTraces and perhaps going up to a parent ThreadGroup and inspecting other child Thread instances, but at least in my debugger, I did not see anything useful.
    The basic idea I am trying to achieve is to detect if an exception is thrown in the try, if yes, chain any exception thrown in the finally block to the original exception. I know I can do this on a case-by-case basis by storing the exception caught and then manually chaining it in the finally block. I was looking for something more generic/applicable to all finally blocks.
    Thanks.
    - Saish

    Thanks JSchell, have done that many times in the past.
    I was looking for a more generic (not generics) solution to the problem. So that an error handler could be written to automatically chain exceptions thrown in the finally clause (granted, one still needs to invoke the error handler). My hope was the stack in the finally clause would look different if an exception was thrown in the try block versus none at all.
    - Saish

  • How to handle exceptions thrown by event

    Hi all,
    i have this slight problem, i'm trying to handle accessing a databse from a button click, i'm trying to simulate somebody logging on to a network. the code is as follows;
    *@author James Taylor
    *@version 30-11-2003
    *Logon gui
    import java.awt.*;
    import javax.swing.*;
    import java.awt.event.*;
    import java.sql.*;
    public class LogonUI extends JFrame {
         //instance variables
         private JLabel userNameL;
         private JPasswordField password;
         private JButton logon;
         ButtonHandler handler;
         Connection con;
         Statement stmt;
          *Constructor initialises and creates UI, adds functionality to the button.
         public LogonUI() throws SQLException, ClassNotFoundException, IllegalAccessException, InstantiationException{
              super("Employee Logon");
              Container c = getContentPane();
              c.setLayout(new FlowLayout() );
              //handles what happens when user presses the button
               handler = new ButtonHandler();
              userNameL = new JLabel("Please Enter Password:");
              c.add(userNameL);
              password = new JPasswordField(15);
              c.add(password);
              logon = new JButton( "Logon" );
              //anonymous inner class that is created once the button is pressed.
              //it connects to database to validate user
              logon.addActionListener( handler );
              c.add(logon);
              c.setBackground( Color.pink );
              setDefaultCloseOperation(DISPOSE_ON_CLOSE);
              setSize(250,150);
              setVisible(true);
          *class that opens connection to validate user
         private class ButtonHandler implements ActionListener {
              public void actionPerformed(ActionEvent ae)throws SQLException, ClassNotFoundException, IllegalAccessException, InstantiationException{
                   try{
                        boolean isValidUser = false;
                        //Load mysql driver
                         Class.forName("com.mysql.jdbc.Driver").newInstance();
                         //make a connection
                        String url = "jdbc:mysql://localhost/flight";
                        con = DriverManager.getConnection(url)
                        //Create and instantiate a statement obj
                        stmt = con.createStatement();
                        //get a result set
                        ResultSet rs = stmt.executeQuery("SELECT Password FROM employees");
                        //Iterate through the result set
                        while ( rs.next() ){     
                             String savedPassword = rs.getString("Password");
                             if (password.getText().equals(savedPassword) ){
                                  isValidUser = true;
                                  JOptionPane.showMessageDialog(null,"Yipeeeee");
                        if (isValidUser == false){
                             JOptionPane.showMessageDialog(null,"Invalid Password");     
                        stmt.close();
                        con.close();
                   }catch(Exception e){ e.printStackTrace();}
              public static void main (String[] args) throws SQLException, ClassNotFoundException, IllegalAccessException, InstantiationException{
              LogonUI testAirApp = new LogonUI();
    }When the user presses the button the app tries to validate the user.
    I have not been able to test the code due to SQL Exceptions thrown in the handler class, and when i try and throw them up from here i get;
    LogonUI.java:52: actionPerformed(java.awt.event.ActionEvent) in LogonUI.ButtonHandler cannot implement actionPerformed(java.awt.event.ActionEvent) in java.awt.event.ActionListener; overridden method does not throw java.lang.InstantiationExceptionAny ideas on my code and how to handle these exceptions will be very appreciated. Regards, James

    Turn your checked exceptions into unchecked exceptions and retrieve the cause later:
    RuntimeException unchecked = new RuntimeException(checked);
    Throwable t = unchecked.getCause();Stephen

  • Exception thrown while reading an XML file using Properties

    Exception thrown while reading an XML file using Properties.
    Exception in thread "main" java.util.InvalidPropertiesFormatException: org.xml.sax.SAXParseException:
    The processing instruction target matching "[xX][mM][lL]" is not allowed.
    at java.util.XMLUtils.load(Unknown Source)
    <?xml version="1.0"?>
    <Config>
         <Database>
              <Product>FX.O</Product>
              <URL>jdbc:oracle:thin:@0.0.0.0:ABC</URL>
         </Database>
    </Config>Am I missing anything?

    Thanks a lot for all yr help.I have got the basics of
    the DTD
    However,when I say thus
    <!DOCTYPE Config SYSTEM "c:/PartyConfig">
    ?xml version="1.0"?>
    <Config>
         <Database>
              <Product>FX</Product>
              <URL>jdbc:oracle:thin:@0.0.0.0:ABC</URL>
         </Database>
    </Config>I get the error
    Invalid system identifier: file:///c:/ParyConfig.dtd
    Please advise?for goodness sake, how many times do I have to tell you that you can't just expect the Properties class to accept arbitrary XML in any format? it reads XML in the format I linked to, and nothing else. Properties is not a general purpose XML binding. you can't do what you're trying to do with it. read this and in particular pay attention to the following
    The XML document must have the following DOCTYPE declaration:
    <!DOCTYPE properties SYSTEM "http://java.sun.com/dtd/properties.dtd">
    Furthermore, the document must satisfy the properties DTD described above.
    you are not reading my answers properly, are you? kindly do so

  • ERROR: ProviderCaller.run(): exception thrown from IMChannel

    Not sure whether this is better addressed here or in the Instant Messaging forum.
    Basically we're having a problem with the presence service in Portal Server, and it throws a huge exception stack when you do anything except have a blank contact list with noone logged in.
    Portal Server, Access Manager, and IM Server are all installed on the same server in this configuration, and I've tried applying patches to the IM Server APIs to fix the problems to no avail.
    JES 2005Q1
    IM Server patched: 118787-01 118790-01
    Portal server unpatched
    Basically all of this is still a default install, with only minimal customization so customers don't have to configure anything.
    tail -f /var/opt/SUNWam/debug/desktop.debug says:
    07:34:25,192 INFO xmppd [com.sun.im.service.util.Worker 4] Authenticating using Identity Server SSO
    06/20/2005 07:34:25:310 AM PDT: Thread[Thread-677,5,main]
    ERROR: ProviderCaller.run(): exception thrown from IMChannel
    com.sun.portal.providers.ProviderException: JSPProvider.processJSPFile(): jsp=IMContent.jsp, java.lang.NoSuchMethodError: org.jaxen.BaseXPath.<init>(Ljava/lang/String;Lorg/jaxen/Navigator;)V
    at com.sun.portal.providers.jsp.JSPProvider.processJspFile(JSPProvider.java:916)
    at com.sun.portal.providers.jsp.JSPProvider.processJspFile(JSPProvider.java:810)
    at com.sun.portal.providers.jsp.JSPProvider.getContent(JSPProvider.java:579)
    at com.sun.im.portal.provider.IMProvider.getContent(IMProvider.java:94)
    at com.sun.portal.desktop.context.ReusableProviderCaller.run(ReusableProviderCaller.java:160)
    java.lang.NoSuchMethodError: org.jaxen.BaseXPath.<init>(Ljava/lang/String;Lorg/jaxen/Navigator;)V
    at net.outer_planes.jso.xpath.JSOXPath.<init>(JSOXPath.java:81)
    at net.outer_planes.jso.xpath.JSOXPath.<init>(JSOXPath.java:78)
    at net.outer_planes.jso.DataFactory.createXPath(DataFactory.java:128)
    at net.outer_planes.jso.DataFactory.createXPath(DataFactory.java:117)
    at net.outer_planes.jso.AbstractElement.getLocaleXPath(AbstractElement.java:175)
    at net.outer_planes.jso.AbstractElement.findElementsForLocale(AbstractElement.java:629)
    at net.outer_planes.jso.AbstractElement.findElementsForLocale(AbstractElement.java:626)
    at net.outer_planes.jso.PresencePacket.getStatus(PresencePacket.java:155)
    at net.outer_planes.jso.PresencePacket.getStatus(PresencePacket.java:152)
    at com.sun.im.service.xmpp.XMPPPresenceService.getPresence(XMPPPresenceService.java:374)
    at com.sun.im.service.xmpp.XMPPPresenceService.fetchPresence(XMPPPresenceService.java:164)
    at com.sun.im.service.xmpp.XMPPPresenceSession.fetch(XMPPPresenceSession.java:47)
    at com.sun.im.service.xmpp.XMPPPresenceSession.fetch(XMPPPresenceSession.java:55)
    at com.sun.im.portal.taglib.GetContactGroupTag.doStartTag(GetContactGroupTag.java:51)
    at jsps.etc._opt._SUNWps._desktop._sampleportal_en_US._IMChannel._html._IMContent_jsp._jspService(_IMContent_jsp.java:799)
    at com.sun.portal.providers.jsp.jasper3.jasper.runtime.HttpJspBase.service(HttpJspBase.java:119)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:860)
    at com.sun.portal.providers.jsp.JspServletWrapper.service(JspServletWrapper.java:182)
    at com.sun.portal.providers.jsp.JSPProvider.processJspFile(JSPProvider.java:896)
    at com.sun.portal.providers.jsp.JSPProvider.processJspFile(JSPProvider.java:810)
    at com.sun.portal.providers.jsp.JSPProvider.getContent(JSPProvider.java:579)
    at com.sun.im.portal.provider.IMProvider.getContent(IMProvider.java:94)
    at com.sun.portal.desktop.context.ReusableProviderCaller.run(ReusableProviderCaller.java:160)
    We're looking to implement JES in the next month or so. I've seen mention of this error with other jaxen flavors, but none mentioning the JES Instant Messaging or Portal Servers

    Does every checkbox have the same name, i.e. "sel".
    In this case you're dealing with a checkbox group. Similar to a select-style dropdown or radio button group.
    I know I've had problems with dropdowns in Netscape where the select parameter was not being passed at all, so I'd get null values. I got around this by having the form submission re-assign the value from the select list to a hidden variable and then getting the value from the request.getParameter("hiddenFieldName") instead of the "dropdownFieldName".
    You could try to name each checkbox individually using an appended ID, such as sel1, sel2, etc. and then have these parameters picked up using a loop construct, request.getParameter("sel" + i) -- you may want to pass some value back that would also indicate how many total checkboxes you had so you could determine how many iterations of the loop to go through.
    On the form side, you could probably set the checkboxes up using a similar looping mechanism so that you wouldn't have to explicitly write each checkbox name.
    If this is in fact similar to the Netscape issue I was having with dropdowns, I'd be interested to hear if it'll work in IE.
    I got a bit off-topic, but hope it helps.

  • Catching exception of a super constructor

    Is it possible to catch the exception thrown by a super class
    constructor in a sub clas constructor?
    public class A
         public A() throws Exception
              throw new Exception("Exception from A");
    class B extends A
         public B()
              try
                   super();
              catch(Exception e)
    }I get an error saying,
    A.java:16: call to super must be first statement in constructor
    super();
    ^
    Any thoughts?

    More on this here,
    http://archive.devx.com/free/tips/tipview.asp?content_i
    =2384&Java=ONThanks for that link. I completely agree to what it says.
    In other words, not being able to successfully construct our super class implies that we cannot create our derived class.
    But I feel this must be mentioned clearly somewhere in JLS. And the error message that we get must be "You cannot catch exceptions thrown by a super class constructor".

  • LiveConnect crashes browser????  External exception thrown.

    Hey,
    Im using an applet that sometimes calls liveconnect, specifically when the applet JFrame is closed, it has the browser navigate to another page.
    This part works great. Then maybe 5 minutes later, and sporadically, IE will crash and put a file on my desktop (winXP).
    Please let me know if you have any ideas, here's some code and the error file from the desktop:
    try {           
    //gets the applet reference
    JSObject win = JSObject.getWindow(
    (Applet)MainMenu.getCurrentMenu().getParent());
    //calls a javascript function, this part works great
    Object answer = win.eval("appletGlue('" + theFunction
    + "', " + questionID + ",'" + param3 + "');");
    //even checks the javascript return value...
    if (answer.toString().equals(ResourceFactory.JAVASCRIPT_SUCCESS)) {
    //done, this works fine too
    return;
    //response = "Success";
    } else {
    response = "ERROR: could not " + errorMessage + " , "
    + answer.toString();
    } catch (Exception e) {
    response = "ERROR: could not properly access the \n" +
    "browser to " + errorMessage + " , exception thrown";
    e.printStackTrace();
    JSObject is the liveconnect class
    com.ar.testbank are my classes
    =======================================================================
    An unexpected exception has been detected in native code outside the VM.
    Unexpected Signal : unknown exception code occurred at PC=0x77E6D756
    Function=RaiseException+0x50
    Library=F:\WINDOWS\system32\kernel32.dll
    Current Java thread:
         at sun.plugin.javascript.ocx.JSObject.nativeInvoke(Native Method)
         at sun.plugin.javascript.ocx.JSObject.invoke(JSObject.java:93)
         - locked <10F00B48> (a sun.plugin.javascript.ocx.JSObject)
         at sun.plugin.javascript.ocx.JSObject.getMember(JSObject.java:201)
         at sun.plugin.javascript.ocx.JSObject.eval(JSObject.java:183)
         at com.ar.testbank.ui.resources.RemoteResourceFactory.doJavascriptCall(Unknown Source)
         at com.ar.testbank.ui.resources.RemoteResourceFactory.doMainMenu(Unknown Source)
         at com.ar.testbank.ui.gui.StatusBottomPanel$5.actionPerformed(Unknown Source)
         at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1767)
         at javax.swing.AbstractButton$ForwardActionEvents.actionPerformed(AbstractButton.java:1820)
         at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:419)
         at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:257)
         at javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:258)
         at java.awt.AWTEventMulticaster.mouseReleased(AWTEventMulticaster.java:227)
         at java.awt.Component.processMouseEvent(Component.java:5021)
         at java.awt.Component.processEvent(Component.java:4818)
         at java.awt.Container.processEvent(Container.java:1525)
         at java.awt.Component.dispatchEventImpl(Component.java:3526)
         at java.awt.Container.dispatchEventImpl(Container.java:1582)
         at java.awt.Component.dispatchEvent(Component.java:3367)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:3359)
         at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3074)
         at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3004)
         at java.awt.Container.dispatchEventImpl(Container.java:1568)
         at java.awt.Window.dispatchEventImpl(Window.java:1581)
         at java.awt.Component.dispatchEvent(Component.java:3367)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:445)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:191)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:144)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:138)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:130)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:98)
    Dynamic libraries:
    0x00400000 - 0x00419000      F:\Program Files\Internet Explorer\IEXPLORE.EXE
    0x77F50000 - 0x77FF9000      F:\WINDOWS\System32\ntdll.dll
    0x77E60000 - 0x77F45000      F:\WINDOWS\system32\kernel32.dll
    0x77C10000 - 0x77C63000      F:\WINDOWS\system32\msvcrt.dll
    0x77D40000 - 0x77DCD000      F:\WINDOWS\system32\USER32.dll
    0x77C70000 - 0x77CB0000      F:\WINDOWS\system32\GDI32.dll
    0x77DD0000 - 0x77E5B000      F:\WINDOWS\system32\ADVAPI32.dll
    0x77CC0000 - 0x77D35000      F:\WINDOWS\system32\RPCRT4.dll
    0x772D0000 - 0x77333000      F:\WINDOWS\system32\SHLWAPI.dll
    0x769C0000 - 0x76B09000      F:\WINDOWS\System32\SHDOCVW.dll
    0x71950000 - 0x71A34000      F:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.0.0_x-ww_1382d70a\comctl32.dll
    0x773D0000 - 0x77BC4000      F:\WINDOWS\system32\SHELL32.dll
    0x77340000 - 0x773CB000      F:\WINDOWS\system32\comctl32.dll
    0x771B0000 - 0x772CA000      F:\WINDOWS\system32\ole32.dll
    0x5AD70000 - 0x5ADA4000      F:\WINDOWS\system32\uxtheme.dll
    0x74720000 - 0x7476B000      F:\WINDOWS\System32\MSCTF.dll
    0x75F80000 - 0x7607C000      F:\WINDOWS\System32\BROWSEUI.dll
    0x72430000 - 0x72442000      F:\WINDOWS\System32\browselc.dll
    0x75F40000 - 0x75F5D000      F:\WINDOWS\system32\appHelp.dll
    0x76FD0000 - 0x77048000      F:\WINDOWS\System32\CLBCATQ.DLL
    0x77120000 - 0x771AB000      F:\WINDOWS\system32\OLEAUT32.dll
    0x77050000 - 0x77115000      F:\WINDOWS\System32\COMRes.dll
    0x77C00000 - 0x77C07000      F:\WINDOWS\system32\VERSION.dll
    0x76200000 - 0x76297000      F:\WINDOWS\system32\WININET.dll
    0x762C0000 - 0x7634A000      F:\WINDOWS\system32\CRYPT32.dll
    0x762A0000 - 0x762AF000      F:\WINDOWS\system32\MSASN1.dll
    0x76F90000 - 0x76FA0000      F:\WINDOWS\System32\Secur32.dll
    0x76620000 - 0x7666E000      F:\WINDOWS\System32\cscui.dll
    0x76600000 - 0x7661B000      F:\WINDOWS\System32\CSCDLL.dll
    0x76670000 - 0x76754000      F:\WINDOWS\System32\SETUPAPI.dll
    0x760F0000 - 0x76168000      F:\WINDOWS\system32\urlmon.dll
    0x76170000 - 0x761F8000      F:\WINDOWS\System32\shdoclc.dll
    0x74770000 - 0x747FF000      F:\WINDOWS\System32\mlang.dll
    0x71AD0000 - 0x71AD8000      F:\WINDOWS\System32\wsock32.dll
    0x71AB0000 - 0x71AC5000      F:\WINDOWS\System32\WS2_32.dll
    0x71AA0000 - 0x71AA8000      F:\WINDOWS\System32\WS2HELP.dll
    0x71A50000 - 0x71A8B000      F:\WINDOWS\system32\mswsock.dll
    0x71A90000 - 0x71A98000      F:\WINDOWS\System32\wshtcpip.dll
    0x76EE0000 - 0x76F17000      F:\WINDOWS\System32\RASAPI32.DLL
    0x76E90000 - 0x76EA1000      F:\WINDOWS\System32\rasman.dll
    0x71C20000 - 0x71C6F000      F:\WINDOWS\System32\NETAPI32.dll
    0x76EB0000 - 0x76EDA000      F:\WINDOWS\System32\TAPI32.dll
    0x76E80000 - 0x76E8D000      F:\WINDOWS\System32\rtutils.dll
    0x76B40000 - 0x76B6C000      F:\WINDOWS\System32\WINMM.dll
    0x5CD70000 - 0x5CD77000      F:\WINDOWS\System32\serwvdrv.dll
    0x5B0A0000 - 0x5B0A7000      F:\WINDOWS\System32\umdmxfrm.dll
    0x722B0000 - 0x722B5000      F:\WINDOWS\System32\sensapi.dll
    0x75A70000 - 0x75B13000      F:\WINDOWS\system32\USERENV.dll
    0x75E90000 - 0x75F31000      F:\WINDOWS\System32\SXS.DLL
    0x76F20000 - 0x76F45000      F:\WINDOWS\System32\DNSAPI.dll
    0x76FB0000 - 0x76FB7000      F:\WINDOWS\System32\winrnr.dll
    0x76F60000 - 0x76F8C000      F:\WINDOWS\system32\WLDAP32.dll
    0x605D0000 - 0x605DF000      F:\WINDOWS\System32\mslbui.dll
    0x76FC0000 - 0x76FC5000      F:\WINDOWS\System32\rasadhlp.dll
    0x76D60000 - 0x76D75000      F:\WINDOWS\System32\iphlpapi.dll
    0x76DE0000 - 0x76E06000      F:\WINDOWS\System32\netman.dll
    0x76D40000 - 0x76D56000      F:\WINDOWS\System32\MPRAPI.dll
    0x76E40000 - 0x76E6F000      F:\WINDOWS\System32\ACTIVEDS.dll
    0x76E10000 - 0x76E34000      F:\WINDOWS\System32\adsldpc.dll
    0x76B20000 - 0x76B35000      F:\WINDOWS\System32\ATL.DLL
    0x71BF0000 - 0x71C01000      F:\WINDOWS\System32\SAMLIB.dll
    0x76DA0000 - 0x76DD0000      F:\WINDOWS\System32\WZCSvc.DLL
    0x76D30000 - 0x76D34000      F:\WINDOWS\System32\WMI.dll
    0x76D80000 - 0x76D9A000      F:\WINDOWS\System32\DHCPCSVC.DLL
    0x76F50000 - 0x76F58000      F:\WINDOWS\System32\WTSAPI32.dll
    0x76360000 - 0x7636F000      F:\WINDOWS\System32\WINSTA.dll
    0x74810000 - 0x74ABD000      F:\WINDOWS\System32\mshtml.dll
    0x513E0000 - 0x5140D000      F:\Program Files\Common Files\Microsoft Shared\VS7Debug\pdm.dll
    0x51300000 - 0x51328000      F:\Program Files\Common Files\Microsoft Shared\VS7Debug\msdbg2.dll
    0x746F0000 - 0x74719000      F:\WINDOWS\System32\msimtf.dll
    0x5C2C0000 - 0x5C303000      F:\WINDOWS\ime\sptip.dll
    0x76400000 - 0x765FB000      F:\WINDOWS\System32\msi.dll
    0x10000000 - 0x1005B000      F:\Program Files\Common Files\Microsoft Shared\Ink\SKCHUI.DLL
    0x32520000 - 0x32532000      F:\Program Files\Microsoft Office\Office10\msohev.dll
    0x75C50000 - 0x75CE1000      F:\WINDOWS\System32\jscript.dll
    0x746C0000 - 0x746E7000      F:\WINDOWS\System32\MSLS31.DLL
    0x74CB0000 - 0x74D1F000      F:\WINDOWS\System32\mshtmled.dll
    0x72D20000 - 0x72D29000      F:\WINDOWS\System32\wdmaud.drv
    0x72D10000 - 0x72D18000      F:\WINDOWS\System32\msacm32.drv
    0x77BE0000 - 0x77BF4000      F:\WINDOWS\System32\MSACM32.dll
    0x77BD0000 - 0x77BD7000      F:\WINDOWS\System32\midimap.dll
    0x73300000 - 0x73375000      F:\WINDOWS\System32\vbscript.dll
    0x58510000 - 0x58575000      F:\WINDOWS\System32\macromed\flash\swflash.ocx
    0x763B0000 - 0x763F5000      F:\WINDOWS\system32\comdlg32.dll
    0x6D430000 - 0x6D439000      F:\WINDOWS\System32\ddrawex.dll
    0x73760000 - 0x737A5000      F:\WINDOWS\System32\DDRAW.dll
    0x73BC0000 - 0x73BC6000      F:\WINDOWS\System32\DCIMAN32.dll
    0x71D40000 - 0x71D5B000      F:\WINDOWS\System32\actxprxy.dll
    0x6CC60000 - 0x6CC6B000      F:\WINDOWS\System32\dispex.dll
    0x72B20000 - 0x72B38000      F:\WINDOWS\System32\plugin.ocx
    0x72E00000 - 0x72F14000      F:\WINDOWS\System32\msxml3.dll
    0x5FE20000 - 0x5FE9E000      F:\WINDOWS\System32\mstime.dll
    0x66880000 - 0x6688A000      F:\WINDOWS\System32\imgutil.dll
    0x66E50000 - 0x66E8B000      F:\WINDOWS\System32\iepeers.dll
    0x73000000 - 0x73023000      F:\WINDOWS\System32\WINSPOOL.DRV
    0x05B50000 - 0x05B65000      F:\Program Files\Java\j2re1.4.0_01\bin\npjpi140_01.dll
    0x05B70000 - 0x05B8C000      F:\Program Files\Java\j2re1.4.0_01\bin\beans.ocx
    0x05B90000 - 0x05BA5000      F:\Program Files\Java\j2re1.4.0_01\bin\jpishare.dll
    0x07B00000 - 0x07C15000      F:\PROGRA~1\Java\J2RE14~1.0_0\bin\client\jvm.dll
    0x6D1D0000 - 0x6D1D7000      F:\PROGRA~1\Java\J2RE14~1.0_0\bin\hpi.dll
    0x6D300000 - 0x6D30D000      F:\PROGRA~1\Java\J2RE14~1.0_0\bin\verify.dll
    0x6D210000 - 0x6D228000      F:\PROGRA~1\Java\J2RE14~1.0_0\bin\java.dll
    0x6D320000 - 0x6D32D000      F:\PROGRA~1\Java\J2RE14~1.0_0\bin\zip.dll
    0x6D000000 - 0x6D0F6000      F:\Program Files\Java\j2re1.4.0_01\bin\awt.dll
    0x76390000 - 0x763AA000      F:\WINDOWS\System32\IMM32.dll
    0x6D180000 - 0x6D1D0000      F:\Program Files\Java\j2re1.4.0_01\bin\fontmanager.dll
    0x6D2D0000 - 0x6D2DD000      F:\Program Files\Java\j2re1.4.0_01\bin\net.dll
    0x6D130000 - 0x6D152000      F:\Program Files\Java\j2re1.4.0_01\bin\dcpr.dll
    0x05BB0000 - 0x05BBA000      F:\Program Files\Java\j2re1.4.0_01\bin\packager.dll
    0x5FF50000 - 0x5FF61000      F:\WINDOWS\System32\msratelc.dll
    0x0EE30000 - 0x0EE63000      F:\WINDOWS\System32\spool\DRIVERS\W32X86\3\UNIDRVUI.DLL
    0x07450000 - 0x0747B000      F:\WINDOWS\System32\spool\DRIVERS\W32X86\3\UNIDRV.DLL
    0x71B20000 - 0x71B31000      F:\WINDOWS\system32\MPR.dll
    0x75F60000 - 0x75F66000      F:\WINDOWS\System32\drprov.dll
    0x71C10000 - 0x71C1D000      F:\WINDOWS\System32\ntlanman.dll
    0x71CD0000 - 0x71CE6000      F:\WINDOWS\System32\NETUI0.dll
    0x71C90000 - 0x71CCC000      F:\WINDOWS\System32\NETUI1.dll
    0x71C80000 - 0x71C86000      F:\WINDOWS\System32\NETRAP.dll
    0x75F70000 - 0x75F79000      F:\WINDOWS\System32\davclnt.dll
    0x75970000 - 0x75A61000      F:\WINDOWS\System32\MSGINA.dll
    0x1F7B0000 - 0x1F7E1000      F:\WINDOWS\System32\ODBC32.dll
    0x1F850000 - 0x1F866000      F:\WINDOWS\System32\odbcint.dll
    0x76C30000 - 0x76C5B000      F:\WINDOWS\System32\wintrust.dll
    0x76C90000 - 0x76CB2000      F:\WINDOWS\system32\IMAGEHLP.dll
    0x767F0000 - 0x76814000      F:\WINDOWS\System32\schannel.dll
    0x0FFD0000 - 0x0FFF2000      F:\WINDOWS\System32\rsaenh.dll
    0x0FFA0000 - 0x0FFC1000      F:\WINDOWS\System32\dssenh.dll
    0x73D50000 - 0x73D60000      F:\WINDOWS\System32\cryptnet.dll
    0x75150000 - 0x75163000      F:\WINDOWS\System32\Cabinet.dll
    0x76C00000 - 0x76C2D000      F:\WINDOWS\System32\credui.dll
    0x5E0C0000 - 0x5E0CC000      F:\WINDOWS\System32\pstorec.dll
    0x76990000 - 0x769B4000      F:\WINDOWS\System32\ntshrui.dll
    0x61580000 - 0x615B0000      F:\WINDOWS\System32\rmoc3260.dll
    0x78000000 - 0x78048000      F:\WINDOWS\System32\PNCRT.dll
    0x5FF20000 - 0x5FF43000      F:\WINDOWS\System32\MSRATING.DLL
    0x60850000 - 0x6088D000      F:\WINDOWS\System32\msieftp.dll
    0x6BDD0000 - 0x6BE03000      F:\WINDOWS\System32\dxtrans.dll
    0x732E0000 - 0x732E5000      F:\WINDOWS\System32\RICHED32.DLL
    0x74E30000 - 0x74E9B000      F:\WINDOWS\System32\RICHED20.dll
    0x6D510000 - 0x6D58C000      F:\WINDOWS\system32\DBGHELP.dll
    0x76BF0000 - 0x76BFB000      F:\WINDOWS\System32\PSAPI.DLL
    Local Time = Tue Jul 30 03:00:10 2002
    Elapsed Time = 16075
    # The exception above was detected in native code outside the VM
    # Java VM: Java HotSpot(TM) Client VM (1.4.0_01-b03 mixed mode)

    im getting similar:
    An unexpected exception has been detected in native code outside the VM.
    Unexpected Signal : unknown exception code occurred at PC=0x77E6D756
    Function=RaiseException+0x50
    Library=C:\WINDOWS\system32\kernel32.dll
    Current Java thread:
         at sun.plugin.javascript.ocx.JSObject.nativeInvoke(Native Method)
         at sun.plugin.javascript.ocx.JSObject.invoke(Unknown Source)
         - locked <072CC118> (a sun.plugin.javascript.ocx.JSObject)
         at sun.plugin.javascript.ocx.JSObject.getMember(Unknown Source)
         at sun.plugin.javascript.ocx.JSObject.eval(Unknown Source)
         at ServerConnectionTimer.jsCall(ServerConnectionTimer.java:61)
         at ServerConnectionTimer.run(ServerConnectionTimer.java:46)
         at java.lang.Thread.run(Unknown Source)
    Dynamic libraries:
    0x00400000 - 0x00419000      C:\Program Files\Internet Explorer\IEXPLORE.EXE
    0x77F50000 - 0x77FF9000      C:\WINDOWS\System32\ntdll.dll
    0x77E60000 - 0x77F45000      C:\WINDOWS\system32\kernel32.dll
    0x77C10000 - 0x77C63000      C:\WINDOWS\system32\msvcrt.dll
    0x77D40000 - 0x77DCD000      C:\WINDOWS\system32\USER32.dll
    0x77C70000 - 0x77CB0000      C:\WINDOWS\system32\GDI32.dll
    0x77DD0000 - 0x77E5B000      C:\WINDOWS\system32\ADVAPI32.dll
    0x77CC0000 - 0x77D35000      C:\WINDOWS\system32\RPCRT4.dll
    0x772D0000 - 0x77333000      C:\WINDOWS\system32\SHLWAPI.dll
    0x71700000 - 0x71848000      C:\WINDOWS\System32\SHDOCVW.dll
    0x629C0000 - 0x629C8000      C:\WINDOWS\System32\LPK.DLL
    0x72FA0000 - 0x72FFA000      C:\WINDOWS\System32\USP10.dll
    0x71950000 - 0x71A34000      C:\WINDOWS\WinSxS\x86_Microsoft.Windows.Common-Controls_6595b64144ccf1df_6.0.0.0_x-ww_1382d70a\comctl32.dll
    0x773D0000 - 0x77BC4000      C:\WINDOWS\system32\SHELL32.dll
    0x77340000 - 0x773CB000      C:\WINDOWS\system32\comctl32.dll
    0x771B0000 - 0x772CA000      C:\WINDOWS\system32\ole32.dll
    0x5AD70000 - 0x5ADA4000      C:\WINDOWS\system32\uxtheme.dll
    0x10000000 - 0x10006000      C:\DOCUME~1\MONTED~1\LOCALS~1\Temp\IadHide3.dll
    0x75F80000 - 0x7607C000      C:\WINDOWS\System32\BROWSEUI.dll
    0x72430000 - 0x72442000      C:\WINDOWS\System32\browselc.dll
    0x75F40000 - 0x75F5D000      C:\WINDOWS\system32\appHelp.dll
    0x76FD0000 - 0x77048000      C:\WINDOWS\System32\CLBCATQ.DLL
    0x77120000 - 0x771AB000      C:\WINDOWS\system32\OLEAUT32.dll
    0x77050000 - 0x77115000      C:\WINDOWS\System32\COMRes.dll
    0x77C00000 - 0x77C07000      C:\WINDOWS\system32\VERSION.dll
    0x63000000 - 0x63094000      C:\WINDOWS\system32\WININET.dll
    0x762C0000 - 0x7634A000      C:\WINDOWS\system32\CRYPT32.dll
    0x762A0000 - 0x762AF000      C:\WINDOWS\system32\MSASN1.dll
    0x76F90000 - 0x76FA0000      C:\WINDOWS\System32\Secur32.dll
    0x76620000 - 0x7666E000      C:\WINDOWS\System32\cscui.dll
    0x76600000 - 0x7661B000      C:\WINDOWS\System32\CSCDLL.dll
    0x76670000 - 0x76754000      C:\WINDOWS\System32\SETUPAPI.dll
    0x1A400000 - 0x1A479000      C:\WINDOWS\system32\urlmon.dll
    0x00E50000 - 0x00ED8000      C:\WINDOWS\System32\shdoclc.dll
    0x74770000 - 0x747FF000      C:\WINDOWS\System32\mlang.dll
    0x71AD0000 - 0x71AD8000      C:\WINDOWS\System32\wsock32.dll
    0x71AB0000 - 0x71AC5000      C:\WINDOWS\System32\WS2_32.dll
    0x71AA0000 - 0x71AA8000      C:\WINDOWS\System32\WS2HELP.dll
    0x71A50000 - 0x71A8B000      C:\WINDOWS\system32\mswsock.dll
    0x71A90000 - 0x71A98000      C:\WINDOWS\System32\wshtcpip.dll
    0x00DE0000 - 0x00E19000      C:\WINDOWS\System32\RASAPI32.DLL
    0x76E90000 - 0x76EA1000      C:\WINDOWS\System32\rasman.dll
    0x71C20000 - 0x71C6F000      C:\WINDOWS\System32\NETAPI32.dll
    0x76EB0000 - 0x76EDA000      C:\WINDOWS\System32\TAPI32.dll
    0x76E80000 - 0x76E8D000      C:\WINDOWS\System32\rtutils.dll
    0x76B40000 - 0x76B6C000      C:\WINDOWS\System32\WINMM.dll
    0x76400000 - 0x765FB000      C:\WINDOWS\System32\msi.dll
    0x75A70000 - 0x75B13000      C:\WINDOWS\system32\USERENV.dll
    0x75E90000 - 0x75F31000      C:\WINDOWS\System32\SXS.DLL
    0x0FFD0000 - 0x0FFF2000      C:\WINDOWS\System32\rsaenh.dll
    0x76F20000 - 0x76F45000      C:\WINDOWS\System32\DNSAPI.dll
    0x76FB0000 - 0x76FB7000      C:\WINDOWS\System32\winrnr.dll
    0x76F60000 - 0x76F8C000      C:\WINDOWS\system32\WLDAP32.dll
    0x722B0000 - 0x722B5000      C:\WINDOWS\System32\sensapi.dll
    0x76FC0000 - 0x76FC5000      C:\WINDOWS\System32\rasadhlp.dll
    0x63580000 - 0x63825000      C:\WINDOWS\System32\mshtml.dll
    0x746F0000 - 0x74719000      C:\WINDOWS\System32\msimtf.dll
    0x60000000 - 0x6004C000      C:\WINDOWS\System32\MSCTF.dll
    0x76390000 - 0x763AA000      C:\WINDOWS\System32\IMM32.DLL
    0x75C50000 - 0x75CE1000      C:\WINDOWS\System32\jscript.dll
    0x66E50000 - 0x66E8B000      C:\WINDOWS\System32\iepeers.dll
    0x73000000 - 0x73023000      C:\WINDOWS\System32\WINSPOOL.DRV
    0x746C0000 - 0x746E7000      C:\WINDOWS\System32\MSLS31.DLL
    0x74CB0000 - 0x74D1F000      C:\WINDOWS\System32\mshtmled.dll
    0x72D20000 - 0x72D29000      C:\WINDOWS\System32\wdmaud.drv
    0x72D10000 - 0x72D18000      C:\WINDOWS\System32\msacm32.drv
    0x77BE0000 - 0x77BF4000      C:\WINDOWS\System32\MSACM32.dll
    0x77BD0000 - 0x77BD7000      C:\WINDOWS\System32\midimap.dll
    0x71D40000 - 0x71D5B000      C:\WINDOWS\System32\ACTXPRXY.DLL
    0x66880000 - 0x6688A000      C:\WINDOWS\System32\imgutil.dll
    0x6B600000 - 0x6B671000      C:\WINDOWS\System32\vbscript.dll
    0x58510000 - 0x58575000      C:\WINDOWS\System32\macromed\flash\swflash.ocx
    0x763B0000 - 0x763F5000      C:\WINDOWS\system32\comdlg32.dll
    0x6D430000 - 0x6D439000      C:\WINDOWS\System32\ddrawex.dll
    0x73760000 - 0x737A5000      C:\WINDOWS\System32\DDRAW.dll
    0x73BC0000 - 0x73BC6000      C:\WINDOWS\System32\DCIMAN32.dll
    0x01E90000 - 0x01EA5000      C:\Program Files\Java\j2re1.4.0\bin\npjpi140.dll
    0x033E0000 - 0x033FC000      C:\Program Files\Java\j2re1.4.0\bin\beans.ocx
    0x036D0000 - 0x036E5000      C:\Program Files\Java\j2re1.4.0\bin\jpishare.dll
    0x03CD0000 - 0x03DE2000      C:\PROGRA~1\Java\J2RE14~1.0\bin\client\jvm.dll
    0x6D1D0000 - 0x6D1D7000      C:\PROGRA~1\Java\J2RE14~1.0\bin\hpi.dll
    0x6D300000 - 0x6D30D000      C:\PROGRA~1\Java\J2RE14~1.0\bin\verify.dll
    0x6D210000 - 0x6D228000      C:\PROGRA~1\Java\J2RE14~1.0\bin\java.dll
    0x6D320000 - 0x6D32D000      C:\PROGRA~1\Java\J2RE14~1.0\bin\zip.dll
    0x6D000000 - 0x6D0F6000      C:\Program Files\Java\j2re1.4.0\bin\awt.dll
    0x6D180000 - 0x6D1D0000      C:\Program Files\Java\j2re1.4.0\bin\fontmanager.dll
    0x69500000 - 0x6981E000      C:\WINDOWS\System32\nvoglnt.dll
    0x6D2D0000 - 0x6D2DD000      C:\Program Files\Java\j2re1.4.0\bin\net.dll
    0x6D130000 - 0x6D152000      C:\Program Files\Java\j2re1.4.0\bin\dcpr.dll
    0x03F60000 - 0x03F6A000      C:\Program Files\Java\j2re1.4.0\bin\packager.dll
    0x6D280000 - 0x6D29E000      C:\Program Files\Java\j2re1.4.0\bin\jpeg.dll
    0x732E0000 - 0x732E5000      C:\WINDOWS\System32\RICHED32.DLL
    0x74E30000 - 0x74E9B000      C:\WINDOWS\System32\RICHED20.dll
    0x6D2A0000 - 0x6D2C1000      C:\Program Files\Java\j2re1.4.0\bin\jsound.dll
    0x76C90000 - 0x76CB2000      C:\WINDOWS\system32\imagehlp.dll
    0x6D510000 - 0x6D58C000      C:\WINDOWS\system32\DBGHELP.dll
    0x76BF0000 - 0x76BFB000      C:\WINDOWS\System32\PSAPI.DLL
    Local Time = Thu Aug 29 22:41:50 2002
    Elapsed Time = 727
    # The exception above was detected in native code outside the VM
    # Java VM: Java HotSpot(TM) Client VM (1.4.0-b92 mixed mode)

  • Catching all possible exceptions in gui thread

    Hi,
    I have such a problem: I am developing Swing app and sometimes it crashes by throwing an Exception which I don't catch. The effect is that this exception prints stack trace on System.err but user is not notified and wonders what is happening... I would prefer to show custom ErrorDialog with stacktrace.
    I am searching for simple and effective way to catch every possible exception thrown from within any library. I think of a few ways from which everyone has some disadvantages.
    The ideal way would be replacing AWT event queue dispatcher so I could process every GUI event inside try { } catch (Exception e) {} block. That would be a good place to catch all exceptions. Unfortunately I don't know if it is possible.
    For now I am trying such a solution:
    I start background thread together with main app. Then I redirect System.err and System.out streams to PipedStream connected to this background thread. This thread can analyze anything that is going to System.err and maybe recognize potential exception stacktraces. Then it can notify main thread of an exception. But it is not ideal as I have to parse the stream and it can always be not ideal in exception recognition. And the code is quite costly.
    Do you have any ideas, had similar problems?

    But how can I cause GUI thread to run in my thread
    group? As I suppose GUI thread is started by JVM and
    is something separate from my code - I can get a
    reference to GUI thread but don't know how to
    manipulate or replace it...One alternative is to completely separate the GUI code from your code.
    Your code, which is wrapped in appropriate try/catch blocks, runs on its own thread and does its own processing. When it's done with that processing, it queues the results on the event thread for display. If an exception occurs during your processing, then you queue something that notifies the GUI.
    The simplest way to implement this is to spawn a new thread for each operation. The Runnable that you give to that thread looks like the following:
    public MyOperationClass implements Runnable
        public void run()
            try
                // do your exception-generating code here
                SwingUtilities.invokeLater( new MyGUIUpdateClass(param1, param2));
            catch (Exception e)
                SwingUtilities.invokeLater(new MyExceptionReporter(e));
    }This is only a bare-bones solution (and hasn't been compiled). Since it separates the GUI from actual processing, you'll probably want to display a wait cursor while the processing thread is doing its thing. You'll probably end up implementing a class that implements this pattern. You may also want to create a producer-consumer thread, so that the user won't invoke, say, a dozen different operations at once.
    However, this sort of code is absolutely essential to Swing programming. Most apps do extensive non-GUI processing, such as database queries. If you run such queries in the GUI thread, your GUI will freeze.
    Sun has named this pattern "SwingWorker", although I don't think they've fleshed it out very fully: http://java.sun.com/products/jfc/tsc/articles/threads/threads2.html

  • Uncaught exceptions thrown in overridden ThreadGroup.uncaughtException

    Hi,
    To process uncaught exceptions in threads I spawn, I have created a ThreadGroup and overridden the uncaughtException method. This works flawlessly, but it brought up the following question:
    What happens to an exception that is thrown in an overridden uncaughtException method that is not caught?
    I assumed that an uncaught exception in an uncaughtException method would call the uncaughtException method in the parent thread group, but this does not seem to be the case. The uncaught exception just seems to disappear.
    Can somebody please confirm my finding that an uncaught exception thrown there just disappears and does not get handled anywhere else? Can somebody point me to the right sections of the Java Language Specs or the JVM Specs that deal with this issue?
    Below is a test program that I wrote to investigate. It throws an exception in an "outer thread", part of an "outer group" thread group; an exception in an "inner thread", part of an "inner group" thread group; and an exception in the uncaughtException method of the "inner group" thread group. I expected that the first two invoke the uncaughtException of the "outer group", while the last one invokes the method of the "inner group". Contrary to my expectations, the exception thrown in the uncaughtException method of the "inner group" does not seem to invoke anything.
    Thanks in advance.
    Yours,
    --Mathias
    public class ThrowInUncaughtExceptionHandler {
    public static void main(String[] args) {
    (new ThrowInUncaughtExceptionHandler()).run();
    public void run() {
    ThreadGroup outerGroup = new ThreadGroup("outer") {
    public void uncaughtException(Thread t, Throwable e) {
    System.out.println("in outerGroup.uncaughtException: "+e);
    final Thread outerThread = new Thread(outerGroup, new Runnable() {
    public void run() {
    System.out.println("in outerThread.run");
    System.out.println("\tthread group: "+Thread.currentThread().getThreadGroup());
    System.out.flush();
    ThreadGroup innerGroup = new ThreadGroup("inner") {
    public void uncaughtException(Thread t, Throwable e) {
    System.out.println("in innerGroup.uncaughtException: "+e);
    System.out.println("\tthrowing another exception...");
    throw new RuntimeException("thrown in innerGroup.uncaughtException");
    final Thread innerThread = new Thread(innerGroup, new Runnable() {
    public void run() {
    System.out.println("in innerThread.run");
    System.out.println("\tthread group: "+Thread.currentThread().getThreadGroup());
    System.out.flush();
    throw new RuntimeException("thrown in innerThread");
    innerThread.start();
    try { innerThread.join(); }
    catch(InterruptedException ioe) { /* ignore */ }
    throw new RuntimeException("thrown in outerThread");
    outerThread.start();
    }

    Hi tigerxx:
    Thank you for your reply. Unfortunately, your suggestion does not help. I had tried it already, even though according to the Java API Javadocs, this is not necessary anyway: If no thread group is specified as parent of a thread group, then the current thread's thread group is used. Since innerGroup is created by a thread in outerGroup, innerGroup's parent is outerGroup.
    Thanks again, though, for taking the time to read and reply.
    --Mathias                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                   

Maybe you are looking for

  • How can I create a Lion recovery disk when the original machine is down?

    Any rapid help with this would be very appreciated - I have university work I need to complete tomorrow. Machine is a 13" MacBook Pro with Bootcamp and windows 7 installed but the problem is on the Mac partition sequence of events:- I was using MS Wo

  • Why can't I backup my catalog in PSE6?

    Every time I try to backup my catalog in PSE6 I get the message"The exception unknown software exception (0xc000000d) occurred in the application at location 0x78138aa0." And the programme shuts down. There was some suggestion that deleting preferenc

  • Moved folder, now missing

    I was copying files over from a network drive to my desktop. During the copy, I dragged a folder already into my desktop into the new copied folder. However, the folder seems to have disappeared. It was 3.6gb in size, and it doesn't show up on the de

  • Solaris Volume Manager packages installation fails

    During the OS installation phase while jumpstarting, the output is as follows for Solaris Volume Manager (see below). To begin with, why are SUNWmdr and SUNWmdu packages trying to install? They are not mentioned in my Profile file, neither are they i

  • ITunes sync issue

    I'm making a playlist just for the iPhone, and it's only taking some of the songs and putting them on the phone, not all. I'm not even close to using all 8G of memory, so it's not that. I've tried a hard reset, and that didn't work. It'll say it's sy