EXCEPTION_ACCESS_VIOLATION in native zipping code on Class Load

Afternoon gents:
So I'm kind've excited by this since I'm an undergrad, and I'm hoping this is actually a bug, such that I've actually found a bug in the JVM!
So, the scary message that showed up in standard error:
# A fatal error has been detected by the Java Runtime Environment:
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000000005ec13ae1, pid=328, tid=68
# JRE version: 7.0_25-b17
# Java VM: Java HotSpot(TM) 64-Bit Server VM (23.25-b01 mixed mode windows-amd64 compressed oops)
# Problematic frame:
# C  [zip.dll+0x3ae1]  Java_java_util_zip_ZipFile_getZipMessage+0x1749
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
# If you would like to submit a bug report, please visit:
#   http://bugreport.sun.com/bugreport/crash.jsp
# The crash happened outside the Java Virtual Machine in native code.
# See problematic frame for where to report the b
I've got 6 or 7 of those log files generated, I've uploaded the most recent one as a gist here:
https://gist.github.com/Groostav/6446505
I can reliably create this crash (though the stack frame would change slightly every time, though it is always caused either by OptimizerNode.run() or one of its spawned threads). Our application flow is one in which that you as a user navigate around our program through various dialogs and popups setting up variables and configuring our program for a run. When you hit the button to start the run, a huge chunk of memory is allocated, a bunch of threads are spawned and delegates are run. Our program consumes an order of magnitude more system resources, both in CPU time and in memory, when you hit our "run" button.
Shortly after hitting the run button, you'd get our spinner, sometimes you'd get a peek at the processing PApplet doing some UI work, and then the program would hard-crash with the above message in std:err.
the good news is that I've found at least a work around for our dev team, and possibly for your (reader who also has this error) production:
increasing the default heap size (by passing -Xms128m to the JVM at runtime, --I believe the default is 64m) results in the program running just fine.
This is a work-around for us, because we wrote this program with the expectation of being able to scale nicely from reasonably small problems (order 200 megs) up to huge problems (order dozens of gigs) of memory. We don't have the hardware or the problems in our development environment to test our code on multi-gig data sets, but I suspect it'll fail in the same way there, even with 128m or even up to 1024m as the default size. There is no realistic flow we can have the user go through to know ahead of time how big his data will balloon to when he hits the run button before we start the JVM. (ie, for us, this is not a production-ready workaround).
This leads me to believe there's a bug in memory allocation code in and around the the class loaders.
Thoughts? Can (or should) I post this to the Java Community Process page as a bug?
cheers,
-Geoff

if don't know if this is the case but it is not a good idea to
have a table open in Access and then insert a row into that table from
a java application. this is really more of an Access and ODBC locking
problem. i think you would have the same problem if you were inserting
the row from a VB application using just ODBC.

Similar Messages

  • Help! My form which requires email and zip code is arriving without data. How is that possible?

    An HTML form design with Dreamweaver CS5 requires the zip code and email to be entered prior to Submitting the form. We tested the form prior to going live and it worked great. The Zip Code and Email are required entries. Today, we received our first completed form from a customer and it worked and looked great. The problem is ... we have also received two forms that are blank. No data results at all; no email or zip code either. I don't know how this can be. The form cannot Submit unless the email and zip code are present.
    Suggestions?
    This is the webpage that has the form (scroll toward the bottom to view it).
    http://www.catchaghostparanormalequipment.com/paranormaltriggerprops.html

    The PHP code is:
    <?php
    //--------------------------Set these paramaters--------------------------
    // Subject of email sent to you.
    $subject = 'Trigger Prop Contact Form';
    // Your email address. This is where the form information will be sent.
    $emailadd = '[email protected]';
    // Where to redirect after form is processed.
    $url = 'http://www.catchaghostparanormalequipment.com/confirmation.html';
    // Makes all fields required. If set to '1' no field can not be empty. If set to '0' any or all fields can be empty.
    $req = '0';
    // --------------------------Do not edit below this line--------------------------
    $text = "Results from form:\n\n";
    $space = ' ';
    $line = '';
    foreach ($_POST as $key => $value)
    if ($req == '1')
    if ($value == '')
    {echo "$key is empty";die;}
    $j = strlen($key);
    if ($j >= 40)
    {echo "Name of form element $key cannot be longer than 40 characters";die;}
    $j = 40 - $j;
    for ($i = 1; $i <= $j; $i++)
    {$space .= ' ';}
    $value = str_replace('\n', "$line", $value);
    $conc = "{$key}:$space{$value}$line";
    $text .= $conc;
    $space = ' ';
    mail($emailadd, $subject, $text, 'From: '.$emailadd.'');
    echo '<META HTTP-EQUIV=Refresh CONTENT="0; URL='.$url.'">';
    ?>
    The form code is:
    <form action="result.php" method="post" name="Trigger Prop Form" id="Trigger Prop Form">
          <p><strong>Trigger Prop Quote/Information Request Form</strong></p>
      <p><span class="welcomesmaller">Trigger props can be sold with or without accessories. You can select more than one item. </span></p>
      <p><span class="props" id="sprycheckbox13">
        <input type="checkbox" name="Antique Style Tin Train Engine" id="Antique Style Tin Train Engine" />
        <label for="Antique Style Tin Train Engine">Antique Style Tin Train Engine</label>
    </span></p>
      <p><span class="props" id="sprycheckbox14">
        <input type="checkbox" name="Tin Merry-Go-Round" id="Tin Merry-Go-Round" />
        <label for="Tin Merry-Go-Round">Antique Style Tin Merry-Go-Round</label>
    </span></p>
      <p><span class="props" id="sprycheckbox15">
        <input type="checkbox" name="Period Lantern" id="Period Lantern" />
        <label for="Period Lantern">Period Lantern</label>
    </span></p>
      <p><span class="props" id="sprycheckbox16">
        <input type="checkbox" name="Bisque Head China Dolls" id="Bisque Head China Dolls" />
        <label for="Bisque Head China Dolls">Bisque Head China Dolls (Variety Similar to Photos)</label>
    </span></p>
      <p><span class="props" id="sprycheckbox17">
        <input type="checkbox" name="Grungy Primitive Rag Doll" id="Grungy Primitive Rag Doll" />
        <label for="Grungy Primitive Rag Doll">Grungy Primitive Rag Doll</label>
    </span></p>
      <p><span class="props" id="sprycheckbox18">
        <input type="checkbox" name="Pocket Watch" id="Pocket Watch" />
        <label for="Pocket Watch">Pocket Watch with Chain</label>
    </span></p>
      <p><span id="sprycheckbox1">
        <input type="checkbox" name="Pirate Gold Coins" id="Pirate Gold Coins" />
        <label for="Pirate Gold Coins" class="props">Pirate Gold Coins</label>
    </span>  </p>
      <p><span class="props" id="sprycheckbox2">
        <input type="checkbox" name="Indian Artifacts with Rabbit Hide" id="Indian Artifacts with Rabbit Hide" />
        <label for="Indian Artifacts with Rabbit Hide">Indian Artifacts with Rabbit Hide</label>
      </span></p>
      <p><span class="props" id="sprycheckbox7">
        <input type="checkbox" name="Prop Pirate Gun" id="Prop Pirate Gun" />
        <label for="Prop Pirate Gun">Prop Pirate Gun</label>
    </span></p>
      <p class="props"><span class="props" id="sprycheckbox4">
        <input type="checkbox" name="Prop Pirate Sword" id="Prop Pirate Sword" />
        <label for="Prop Pirate Sword">Prop Pirate Sword</label>
    </span></p>
      <p class="props"><span class="props" id="sprycheckbox5">
        <input type="checkbox" name="Civil War Medals" id="Civil War Medals" />
        <label for="Civil War Medals">Civil War Medals</label>
    </span></p>
      <p class="props"><span id="sprycheckbox3">
        <input type="checkbox" name="West Lantern" id="West Lantern" />
        <label for="Western Style Lantern">Western Style Lantern</label>
    </span></p>
      <p class="props"><span class="props" id="sprycheckbox8">
        <input type="checkbox" name="Small Teddy Bear in Basket" id="Small Teddy Bear in Basket" />
        <label for="Small Teddy Bear in Basket">6" Small Teddy Bear in Basket</label>
    </span></p>
      <p class="props"><span class="props" id="sprycheckbox9">
        <input type="checkbox" name="Small Rag Doll in Basket" id="Small Rag Doll in Basket" />
        <label for="Small Rag Doll in Basket">6" Small Rag Doll in Basket</label>
    </span></p>
      <p class="props"><span class="props" id="sprycheckbox10">
        <input type="checkbox" name="Large Primitive Rag Doll in Basket" id="Large Primitive Rag Doll in Basket" />
        <label for="Large Primitive Rag Doll in Basket">Large Primitive Rag Doll in Basket</label>
    </span></p>
      <p class="props"><span class="props" id="sprycheckbox11">
        <input type="checkbox" name="Knitting Basket with Needles" id="Knitting Basket with Needles" />
        <label for="Knitting Basket with Needles">Knitting Basket with Knitting Needles</label>
    </span></p>
      <p class="props"><span class="props" id="sprycheckbox12">
        <input type="checkbox" name="Metal Needle Point Loom Doile" id="Metal Needle Point Loom Doile" />
        <label for="Metal Needle Point Loom Doile">Metal Needle Point Loom with Antique Doile</label>
    </span></p>
      <p class="props"><span class="props" id="sprycheckbox19">
        <input type="checkbox" name="Accessories" id="Accessories" />
        <label for="Accessories">Accessories (Chairs, Wagons, Buggy, Sleds, etc.)</label>
    </span></p>
      <p class="props"><span id="sprytextarea1">
        <label for="Custom Request">Custom Request, Questions, and/or Comments</label>
        <textarea name="Custom Request" id="Custom Request" cols="45" rows="5"></textarea>
    </span></p>
      <p class="props"><span id="sprytextfield2">
      <label for="Email Contact">Email Contact</label>
      <input type="text" name="Email Contact" id="Email Contact" />
      <span class="textfieldRequiredMsg">A value is required.</span><span class="textfieldInvalidFormatMsg">Invalid format.</span></span></p>
      <p class="props"><span id="sprytextfield3">
      <label for="Shipping Zip Code">Shipping Zip Code for Quote</label>
      <input type="text" name="Shipping Zip Code" id="Shipping Zip Code" />
      <span class="textfieldInvalidFormatMsg">Invalid format.</span><span class="textfieldRequiredMsg">A value is required.</span></span></p>
      <p>
        <input name="submit2" type="submit" id="submit" value="Submit" />
          <input type="reset" name="Reset" id="Reset" value="Reset Form" />
      </p>
      <p>  </p>
        </form>

  • "Open-code" statements / dynamic class-loading

    Hi!
    I am using reflection to dynamically load classes in an application where the classes are read dynamically from a text-box (or a file) in a running Java-session. When a class is loaded, instances can be made. All this works fine.
    Now consider the following example:
    1. First a class Sample1 is loaded:
    public class Sample1 {
    public int i;
    Sample1() {
    i=5;
    2. I want to make an instance of Sample1 like:
    Sample1 s1=new Sample1();
    To use dynamic load, this "open-code" statement needs (?) to be put in a class Sample2. This works fine, and the method()-method can be invoked (using reflection):
    public class Sample2 {
    public Sample1 s1;
    public void method(String args[]) { 
    s1=new Sample1();
    System.out.println(s1.i);
    3. At last I want to refer (print) to s1.i (and again the code is wrapped in a class), but this doesn't work:
    public class Sample3 {
    public void method(String args[]) { 
    System.out.println(s1.i);
    The problem is how the statement:
    Sample1 s1=new Sample1();
    can be executed so that s1 can be referenced in the running Java-session.
    Any suggestions how to solve this design-problem? What I want to do is make "open-code" statements that can be referenced in the running Java-session.
    Regards,
    Jesper

    Typically, your 'open code statements' would be wrapped in a class that implements a suitable interface. If you wish to have state shared between your generated classes, then some form of common store (such as a Map) needs to be used to hold the state, and this made accessible to the implementations.
    eg:interface PluginMethod { void apply (Map state) ;}
    public class Sample2 implements PluginMethod {
      public void apply (Map state) {
         state.put("s1", new Sample1());
    public class Sample3 implements PluginMethod {
      public void apply (Map state) {
         System.out.println(((Sample1)state.get("s1")).i);
    }Alternatively, any of the normal methods of sharing state between objects can be used if closer coupling is desired. Dynamic class loading doen't really come into it- you use the same techniques as you normally do.
    Pete

  • Problem loading metadata from ODI to HFM ( Error code: 0x80040154 [Class...

    Hi Experts
    I have an issue when I load metadata via ODI to HFM. I get this message:
    Error code: 0x80040154 [Class not registered
    com.hyperion.odi.common.ODIHAppException: Metadata load failed. Error code: 0x80040154 [Class not registered
    After some search on the net I see that this is due to a patch which is already been installed(ODI 10.1.3.5.5). The HFMDriver.dll is renamed as HFMDriver32.dll and HFMDriver64.dll rename as HFMDriver.dll.
    Patch 9377717: ORACLE DATA INTEGRATOR 10.1.3.6.0 PATCH
    1. I have reversed the HFM application TestApp into target for ODI and everything seems fine in the operator
    2. I have created a simple source flat file for the Account dimension
    3. I have created an interface to the Account dim. and verified the mapping with no errors
    4. The process stops when trying to Load the Metadata to HFM(Step 5 / of 7)
    5. When I search the log I see the Error code: 0x80040154 [Class not registered]
    Does anyone have any idea why the interface does not load the metadata?
    Brs
    Inge Andre
    Edited by: 819836 on Apr 14, 2011 12:49 PM

    This instructions given us by the support have fixed the problem on the first topic.
    1. Unregister the adapter by opening the command prompt and changing the path to
    C:\WINDOWS\Microsoft.NET\Framework\v2.0.50727\ RegSvcs.exe /u C:\Hyperion\products\FinancialDataQuality\SharedComponents\AdapterComponents\fdmAdapterCOMadmin\fdmAdapterCOMadmin.dll
    and:
    RegSvcs.exe /u C:\Hyperion\products\FinancialDataQuality\SharedComponents\AdapterComponents\fdmFM11xG5C\fdmFM11xG5C.dll
    Please verify the correct path to the dll's before proceeding
    2. Re-register the adapter using the 64 bit version of RegSvcs, C:\WINDOWS\Microsoft.NET\Framework64\v2.0.50727\RegSvcs.exe <PathToDLL> i.e. ..\Hyperion\products\FinancialDataQuality\SharedComponents\AdapterComponents\fdmFM11xG5C\fdmFM11xG5C.dll
    N.B. Do not re-register the ComAdmin.dll because that is not a 64 bit component.
    4. Open the FDM workbench and configure the adapter by right clicking the adapter -> Configure and re-entering the username and password.
    Regards.

  • Using AJAX to load city, state, metro area based on zip code

    I'm new to getting APEX to work with AJAX properly. I've been reading some tutorials and trying to apply what they do to my situation, but I'm running into a problem. I have a text field item for zip code. What I want to happen is that when someone enters in a zip code, I want to use AJAX to populate 3 different select lists (1 each for state, city, and metro area) and to populate a checkbox (of neighborhoods based on the zip code as well). I'm looking at the examples in:
    http://www.oraclealchemist.com/wp-content/uploads/2006/11/s281946.pdf
    and
    http://apex.oracle.com/pls/otn/f?p=11933:63
    But they all use examples where the value of a text field item is used to populate 1 select list. I can't figure out how to apply that methodology to populate 3 select lists and 1 checkbox item. I've got all my SELECT statements written to populate these fields based on the value of the zip code text field item, but don't know how to convert what I already have to use AJAX.
    Here are my SELECT statements:
    P2805_STATE lov:
    ===========================================================================================
    SELECT INITCAP(GEO_DATA_STATE.STATEFULLNAME) d,GEO_DATA_STATE.STATE v
    FROM GEO_DATA_STATE, GEO_DATA_ZIP
    WHERE isPrimary = 'P' and
    trim(upper(GEO_DATA_ZIP.STATE)) = trim(upper(GEO_DATA_STATE.STATE)) and
    GEO_DATA_ZIP.ZIPCODE = :P2805_ZIPCODE
    ORDER BY STATEFULLNAME
    P2805_CITY lov:
    ===========================================================================================
    SELECT UNIQUE (INITCAP(GEO_DATA_CITY.CITY)) d,GEO_DATA_CITY.CITY v
    FROM GEO_DATA_STATE, GEO_DATA_ZIP, GEO_DATA_CITY
    WHERE
    trim(upper(GEO_DATA_ZIP.STATE)) = trim(upper(GEO_DATA_STATE.STATE)) and
    trim(upper(GEO_DATA_ZIP.CITY)) = trim(upper(GEO_DATA_CITY.CITY)) and
    GEO_DATA_ZIP.ZIPCODE = :P2805_ZIPCODE
    ORDER BY GEO_DATA_CITY.CITY
    P2805_METRO_AREA lov:
    ===========================================================================================
    SELECT UNIQUE (INITCAP(GEO_DATA_METRO.METRO_AREA)) d,GEO_DATA_METRO.CODE v
    FROM GEO_DATA_STATE, GEO_DATA_ZIP, GEO_DATA_METRO
    WHERE
    trim(upper(GEO_DATA_ZIP.STATE)) = trim(upper(GEO_DATA_STATE.STATE)) and
    trim(upper(GEO_DATA_ZIP.METROCODE)) = trim(upper(GEO_DATA_METRO.CODE)) and
    GEO_DATA_ZIP.ZIPCODE = :P2805_ZIPCODE
    ORDER BY 1
    P2805_NEIGHBORHOOD lov:
    ===========================================================================================
    SELECT UNIQUE (INITCAP(GEO_DATA_HOOD.HOOD)) d,GEO_DATA_HOOD.HOOD v
    FROM GEO_DATA_STATE, GEO_DATA_ZIP, GEO_DATA_METRO, GEO_DATA_HOOD
    WHERE
    trim(upper(GEO_DATA_ZIP.STATE)) = trim(upper(GEO_DATA_STATE.STATE)) and
    trim(upper(GEO_DATA_ZIP.METROCODE)) = trim(upper(GEO_DATA_METRO.CODE)) and
    GEO_DATA_HOOD.METRO_CODE = GEO_DATA_METRO.CODE and
    GEO_DATA_ZIP.ZIPCODE = :P2805_ZIPCODE
    ORDER BY 1Do all these statements need to go in 1 on-demand process? Where do I go from here?

    Andy, cool. This is starting to make more sense. THANKS A BUNCH! OK. I've gone ahead and modified the on demand process to suit my needs, so I have:
    begin
      owa_util.mime_header('text/xml', FALSE );
      htp.p('Cache-Control: no-cache');
      htp.p('Pragma: no-cache');
      owa_util.http_header_close;
      -- Building States list
      htp.prn('&lt;SELECT&gt;');
      FOR i in (
        SELECT INITCAP(GEO_DATA_STATE.STATEFULLNAME) d, GEO_DATA_STATE.STATE v
        FROM GEO_DATA_STATE, GEO_DATA_ZIP
        WHERE isPrimary = 'P' and
        trim(upper(GEO_DATA_ZIP.STATE)) = trim(upper(GEO_DATA_STATE.STATE)) and
        GEO_DATA_ZIP.ZIPCODE = :P2805_ZIPCODE
        ORDER BY STATEFULLNAME
      LOOP
        htp.prn('&lt;OPTION VALUE=''' || i.v || '''&gt;' || i.d || '&lt;/OPTION&gt;');
      END LOOP;
      htp.prn('&lt;/SELECT&gt;');
      -- Building Cities list
      htp.prn('&lt;SELECT&gt;');
      FOR i in (
        SELECT UNIQUE (INITCAP(GEO_DATA_CITY.CITY)) d, GEO_DATA_CITY.CITY v
        FROM GEO_DATA_STATE, GEO_DATA_ZIP, GEO_DATA_CITY
        WHERE
        trim(upper(GEO_DATA_ZIP.STATE)) = trim(upper(GEO_DATA_STATE.STATE)) and
        trim(upper(GEO_DATA_ZIP.CITY)) = trim(upper(GEO_DATA_CITY.CITY)) and
        GEO_DATA_ZIP.ZIPCODE = :P2805_ZIPCODE
        ORDER BY GEO_DATA_CITY.CITY
      LOOP
        htp.prn('&lt;OPTION VALUE=''' || i.v || '''&gt;' || i.d || '&lt;/OPTION&gt;');
      END LOOP;
      htp.prn('&lt;/SELECT&gt;');
      -- Building Metro Area list
      htp.prn('&lt;SELECT&gt;');
      FOR i in (
        SELECT UNIQUE (INITCAP(GEO_DATA_METRO.METRO_AREA)) d, GEO_DATA_METRO.CODE v
        FROM GEO_DATA_STATE, GEO_DATA_ZIP, GEO_DATA_METRO
        WHERE
        trim(upper(GEO_DATA_ZIP.STATE)) = trim(upper(GEO_DATA_STATE.STATE)) and
        trim(upper(GEO_DATA_ZIP.METROCODE)) = trim(upper(GEO_DATA_METRO.CODE)) and
        GEO_DATA_ZIP.ZIPCODE = :P2805_ZIPCODE
        ORDER BY 1
      LOOP
        htp.prn('&lt;OPTION VALUE=''' || i.v || '''&gt;' || i.d || '&lt;/OPTION&gt;');
      END LOOP;
      htp.prn('&lt;/SELECT&gt;');
      -- Building Neighborhood list
      htp.prn('&lt;SELECT&gt;');
      FOR i in (
        SELECT UNIQUE (INITCAP(GEO_DATA_HOOD.HOOD)) d, GEO_DATA_HOOD.HOOD v
        FROM GEO_DATA_STATE, GEO_DATA_ZIP, GEO_DATA_METRO, GEO_DATA_HOOD
        WHERE
        trim(upper(GEO_DATA_ZIP.STATE)) = trim(upper(GEO_DATA_STATE.STATE)) and
        trim(upper(GEO_DATA_ZIP.METROCODE)) = trim(upper(GEO_DATA_METRO.CODE)) and
        GEO_DATA_HOOD.METRO_CODE = GEO_DATA_METRO.CODE and
        GEO_DATA_ZIP.ZIPCODE = :P2805_ZIPCODE
        ORDER BY 1
      LOOP
        htp.prn('&lt;OPTION VALUE=''' || i.v || '''&gt;' || i.d || '&lt;/OPTION&gt;');
      END LOOP;
      htp.prn('&lt;/SELECT&gt;');
    end;It doesn't look like I would have to modify the appendToSelect function at all, correct? Is the checkbox that I need to populate handled the same way as these select lists? And it seems like I only need to make the 2 changes that you mentioned to get_AJAX_SELECT_XML function, right? So my javascript function should be like:
    &lt;script language="JavaScript1.1" type="text/javascript"&gt;
    function get_AJAX_SELECT_XML(pThis,pSelect1,pSelect2,pSelect3,pSelect4){
    if  (document.getElementById('P2805_ZIPCODE').value.length == 5)
         var l_Return = null;
         var l_Select1 = $x(pSelect1);
         var l_Select2 = $x(pSelect2);
         var l_Select3 = $x(pSelect3);
         var l_Select4 = $x(pSelect4);
         var get = new htmldb_Get(null,$x('pFlowId').value,'APPLICATION_PROCESS=otn_Select_XML',0);
         get.add('TEMPORARY_ITEM',pThis.value);
         gReturn = get.get('XML');
         var sels = gReturn.getElementsByTagName("select");
         if(gReturn && l_Select1){
              var l_Count = sels[0].getElementsByTagName("option").length;
              l_Select1.length = 0;
              for(var i=0;i<l_Count;i++){
                   var l_Opt_Xml = sels[0].getElementsByTagName("option");
                   appendToSelect(l_Select1, l_Opt_Xml.getAttribute('value'), l_Opt_Xml.firstChild.nodeValue)
         if(gReturn && l_Select2){
              var l_Count = sels[1].getElementsByTagName("option").length;
              l_Select2.length = 0;
              for(var i=0;i<l_Count;i++){
                   var l_Opt_Xml = sels[1].getElementsByTagName("option")[i];
                   appendToSelect(l_Select2, l_Opt_Xml.getAttribute('value'), l_Opt_Xml.firstChild.nodeValue)
         if(gReturn && l_Select3){
              var l_Count = sels[2].getElementsByTagName("option").length;
              l_Select3.length = 0;
              for(var i=0;i<l_Count;i++){
                   var l_Opt_Xml = sels[2].getElementsByTagName("option")[i];
                   appendToSelect(l_Select3, l_Opt_Xml.getAttribute('value'), l_Opt_Xml.firstChild.nodeValue)
         if(gReturn && l_Select4){
              var l_Count = sels[3].getElementsByTagName("option").length;
              l_Select4.length = 0;
              for(var i=0;i<l_Count;i++){
                   var l_Opt_Xml = sels[3].getElementsByTagName("option")[i];
                   appendToSelect(l_Select4, l_Opt_Xml.getAttribute('value'), l_Opt_Xml.firstChild.nodeValue)
         get = null;
    &lt;/script&gt;
    And then since all 4 items (3 select lists and 1 checkbox item) are populated based on the value inputted in the text field item, I would only need to add the following to the html form element attribute of my text field item, right?
    onKeyUp="javascript:get_AJAX_SELECT_XML(this,'P2805_STATE','P2805_CITY','P2805_METRO_AREA','P2805_NEIGHBORHOOD');"Denes, thanks for the example. It seems like what I need to do is somewhere inbetween what you have and what's in the example on http://apex.oracle.com/pls/otn/f?p=11933:37. I have 3 select lists and 1 checkbox item that should all be populate depending on the value entered for the text item. Do I still need to split everything up then into a function and an on demand process for each select list and checkbox?

  • Dinamyc class loading and jar files

    I'm new to java. I would like to load some plugins in my application (it's going to be packaged as a jar at the end). I managed to find some dinamyc class loading examples but they search for the classes to load in a directory.
    This is the code:
        public static void main(String[] args) {
            File pluginDirectory = new File("src/pluginsreloaded/plugins");
            if (!pluginDirectory.exists()) {            // the plugin directory does not exist
                System.out.println("The plugins directory does not exist!");           
                return;
            FilenameFilter filter = new FilenameFilter() {
                public boolean accept(File dir, String name) {
                    return name.endsWith(".class");
            String[] pluginFiles = pluginDirectory.list(filter);
            for (int i = 0; i < pluginFiles.length; i++) {
                if (pluginFiles.indexOf("$") == -1) {
    System.out.println("Loading: " + pluginFiles[i].substring(0, pluginFiles[i].length() - 6));
    IPlugin plugin = pm.loadPlugin(pluginFiles[i].substring(0, pluginFiles[i].length() - 6));
    System.out.println(plugin.description());
    protected static IPlugin loadPlugin(String name) {
            // Query the plugin list for the plugin
            PluginFactory _plugin = (PluginFactory) pluginList.get(name);
            if (_plugin == null) {          // the plugin is not loaded
                try {
                    Class.forName("pluginsReloaded.plugins." + name);
                    // The plugin makes an entry in the plugin list
                    // when loaded
                    _plugin = (PluginFactory) pluginList.get(name);
                    if (_plugin == null) {
                        return null;
                } catch (ClassNotFoundException e) {
                    System.out.println("Plugin " + name + " not found!");
            return _plugin.create();
        }IPlugin is an interface. I am using netbeans 5.0. The error I get is this:
    Exception in thread "main" java.lang.NoClassDefFoundError: pluginsReloaded/plugins/plugin1 (wrong name: pluginsreloaded/plugins/plugin1)
            at java.lang.ClassLoader.defineClass1(Native Method)
            at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
            at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
            at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
            at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
            at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
            at java.security.AccessController.doPrivileged(Native Method)
            at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
            at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:268)
            at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
            at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
            at java.lang.Class.forName0(Native Method)
            at java.lang.Class.forName(Class.java:164)
            at pluginsreloaded.PluginManager.loadPlugin(PluginManager.java:30)
            at pluginsreloaded.Main.main(Main.java:44)
    Java Result: 1As far as I can see it can't find the class. My question is how can I load the class/where can I find it?
    Thanks.

    You can use the java.util.jar.JarFile class to enumerate the contents of a jar. It's not good practice to search for plugins in this way though. A plugin may well involve serveral classes, which don't all have to be internal. Furthermore its wise to avoid any comitment about the mechaism by which class files are to be fetched. You might want to do it remotely, some time, or load them from a database.
    What seesms to be the standard approach is to put a list of plugin classes into the jar as a text file.
    Plugins for a given purpose usually implement some specified interface, or extend some abstract class to which their objects can be cast once loaded (without this they aren't really much use).
    Say your plugins implment org.myorg.WidgetFactory then you put a list of them, one fully qualified name to a line, in a file or jar entry called META-INF/services/org.myorg.WidgetFactory. You framework picks up all such files from the classpath using ClassLoader.getResources() and loads all the classes whose names if finds, hence you can add new sets of plugins just by adding a new jar or class directory to the class path.

  • Plz help me out with class loader problem

    hai forum members,
    I have a code which loads class files from local disk.
    It works fine with some classes ,
    But i get this exception when i am selecting certain other class files
    I am using jdeveloper.
    Exception in thread "AWT-EventQueue-0" java.lang.NoClassDefFoundError: Filter (wrong name: project1/Filter)
         at java.lang.ClassLoader.defineClass1(Native Method)
         at java.lang.ClassLoader.defineClass(ClassLoader.java:620)
         at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:124)
         at java.net.URLClassLoader.defineClass(URLClassLoader.java:260)
         at java.net.URLClassLoader.access$100(URLClassLoader.java:56)
         at java.net.URLClassLoader$1.run(URLClassLoader.java:195)
         at java.security.AccessController.doPrivileged(Native Method)
         at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:306)
         at java.lang.ClassLoader.loadClass(ClassLoader.java:251)
         at com.jutframe.JavaUnitTester.selectClass_actionPerformed(JavaUnitTester.java:449)
         at com.jutframe.JavaUnitTester$7.actionPerformed(JavaUnitTester.java:338)
         at javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1849)
         at javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2169)
         at javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:420)
         at javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:258)
         at javax.swing.AbstractButton.doClick(AbstractButton.java:302)
         at javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:1000)
         at javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:1041)
         at java.awt.Component.processMouseEvent(Component.java:5488)
         at javax.swing.JComponent.processMouseEvent(JComponent.java:3093)
         at java.awt.Component.processEvent(Component.java:5253)
         at java.awt.Container.processEvent(Container.java:1966)
         at java.awt.Component.dispatchEventImpl(Component.java:3955)
         at java.awt.Container.dispatchEventImpl(Container.java:2024)
         at java.awt.Component.dispatchEvent(Component.java:3803)
         at java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4212)
         at java.awt.LightweightDispatcher.processMouseEvent(Container.java:3892)
         at java.awt.LightweightDispatcher.dispatchEvent(Container.java:3822)
         at java.awt.Container.dispatchEventImpl(Container.java:2010)
         at java.awt.Window.dispatchEventImpl(Window.java:1766)
         at java.awt.Component.dispatchEvent(Component.java:3803)
         at java.awt.EventQueue.dispatchEvent(EventQueue.java:463)
         at java.awt.EventDispatchThread.pumpOneEventForHierarchy(EventDispatchThread.java:234)
         at java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:163)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:157)
         at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:149)
         at java.awt.EventDispatchThread.run(EventDispatchThread.java:110)
                        JFileChooser jfilechooser=new JFileChooser();
                        Filterclass filter=new Filterclass();
                        //Set selection mode for file chooser
                        jfilechooser.setFileSelectionMode(JFileChooser.FILES_ONLY);
                        //set file filter
                        jfilechooser.setFileFilter(filter);
                        int returnVal = jfilechooser.showOpenDialog(this);
                        if(returnVal == JFileChooser.APPROVE_OPTION)
                            try
                                    String str = jfilechooser.getSelectedFile().getName();
                                    String parent=jfilechooser.getSelectedFile().getParent();
                                     // Create a File object on the root of the directory containing the class file
                                     File file = new File(parent);
                                     // Convert File to a URL
                                     URL url = file.toURL();         
                                     URL[] urls = new URL[]{url};
                                     // Create a new class loader with the directory
                                     ClassLoader cl = new URLClassLoader(urls);
                                     StringTokenizer st = new StringTokenizer(str,".");
                                     String s = st.nextToken ();
                                     Class c = cl.loadClass(s);  //ERROR IS SHOWN IN THIS PARTICULAR LINE
                                     Object instance=c.newInstance();
    --------------------------------------------please help me trace my mistake.
    thank you all.

    i think the problem that i have set a particular class path for my class files and my application loads files from that alone.
    So plz tell me if theres any way to access the class path of a particular file dynamically?
    regards

  • Class loader Exception

    I am getting the following error even though the corresponding file is present in the app.jar.
    This happens when hibernates are getting loaded , when i start the oracle app server.
    Does anyone knows why its so.
    Caused by: org.hibernate.MappingException: entity class not found: com.iflex.fcr.app.deposit.td.us.dto.DepositRateHistoryDTOCheckNew
         at org.hibernate.mapping.PersistentClass.getMappedClass(PersistentClass.java:99)
         at org.hibernate.tuple.PropertyFactory.getGetter(PropertyFactory.java:166)
         at org.hibernate.tuple.PropertyFactory.buildIdentifierProperty(PropertyFactory.java:44)
         at org.hibernate.tuple.EntityMetamodel.<init>(EntityMetamodel.java:115)
         at org.hibernate.persister.entity.AbstractEntityPersister.<init>(AbstractEntityPersister.java:412)
         at org.hibernate.persister.entity.SingleTableEntityPersister.<init>(SingleTableEntityPersister.java:108)
         at org.hibernate.persister.PersisterFactory.createClassPersister(PersisterFactory.java:55)
         at org.hibernate.impl.SessionFactoryImpl.<init>(SessionFactoryImpl.java:216)
         at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1176)
         at com.iflex.fcr.infra.das.orm.hibernate.SessionFactoryLoader.<clinit>(Unknown Source)
         ... 5 more
    Caused by: oracle.classloader.util.AnnotatedClassNotFoundException:
         Missing class: com.iflex.fcr.app.deposit.td.us.dto.DepositRateHistoryDTOCheckNew
         Dependent class: org.hibernate.util.ReflectHelper
         Loader: global.libraries:1.0
         Code-Source: /D:/product/10.1.3.1/OracleAS_3/j2ee/FSI_RETAIL/applib/hibernate313.jar
         Configuration: <code-source> in /D:/product/10.1.3.1/OracleAS_3/j2ee/FSI_RETAIL/config/server.xml
    This load was initiated at global.libraries:1.0 using the Class.forName() method.
    The missing class is not available from any code-source or loader in the system.
         at oracle.classloader.PolicyClassLoader.handleClassNotFound(PolicyClassLoader.java:2078)
         at oracle.classloader.PolicyClassLoader.internalLoadClass(PolicyClassLoader.java:1679)
         at oracle.classloader.PolicyClassLoader.loadClass(PolicyClassLoader.java:1635)
         at oracle.classloader.PolicyClassLoader.loadClass(PolicyClassLoader.java:1620)
         at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:319)
         at java.lang.Class.forName0(Native Method)
         at java.lang.Class.forName(Class.java:164)
         at org.hibernate.util.ReflectHelper.classForName(ReflectHelper.java:108)
         at org.hibernate.mapping.PersistentClass.getMappedClass(PersistentClass.java:96)
         ... 14 more

    Neither, not using Oracle HTTP Server nor using JDK 1.4 incluence the behaviour of OC4J. It is your application deployment. As it should be with every Java EE server you provide an EAR file structure with modules like WAR files or EJB jar files. Each of these modules has more or less its own class loading environment.
    OC4J however supports application and global shared libraries. Application shared libraries can be packaged in the EAR file using the Java EE 5 library mechanism. In essence your libraries must be known by the class loader of the Java EE module otherwise your application doesn't work.
    What I need to know is what type of application (WAR, EJB, combo of both) you're using and how the files are laid out in the directory structure.
    To have an example, see this blog entry: http://blogs.oracle.com/olaf/2007/07/25
    --olaf                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                       

  • Custom class loader and local class accessing local variable

    I have written my own class loader to solve a specific problem. It
    seemed to work very well, but then I started noticing strange errors in
    the log output. Here is an example. Some of the names are in Norwegian,
    but they are not important to this discussion. JavaNotis.Oppstart is the
    name of my class loader class.
    java.lang.ClassFormatError: JavaNotis/SendMeldingDialog$1 (Illegal
    variable name " val$indeks")
    at java.lang.ClassLoader.defineClass0(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:502)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:431)
    at JavaNotis.Oppstart.findClass(Oppstart.java:193)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:299)
    at java.lang.ClassLoader.loadClass(ClassLoader.java:255)
    at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:315)
    at JavaNotis.SendMeldingDialog.init(SendMeldingDialog.java:78)
    at JavaNotis.SendMeldingDialog.<init>(SendMeldingDialog.java:54)
    at JavaNotis.Notistavle.sendMelding(Notistavle.java:542)
    at JavaNotis.Notistavle.access$900(Notistavle.java:59)
    at JavaNotis.Notistavle$27.actionPerformed(Notistavle.java:427)
    JavaNotis/SendMeldingDialog$1 is a local class in the method
    JavaNotis.SendMeldingDialog.init, and it's accessing a final local
    variable named indeks. The compiler automatically turns this into a
    variable in the inner class called val$indeks. But look at the error
    message, there is an extra space in front of the variable name.
    This error doesn't occur when I don't use my custom class loader and
    instead load the classes through the default class loader in the JVM.
    Here is my class loading code. Is there something wrong with it?
    Again some Norwegian words, but it should still be understandable I hope.
         protected Class findClass(String name) throws ClassNotFoundException
             byte[] b = loadClassData(name);
             return defineClass(name, b, 0, b.length);
         private byte[] loadClassData(String name) throws ClassNotFoundException
             ByteArrayOutputStream ut = null;
             InputStream inn = null;
             try
                 JarEntry klasse = arkiv.getJarEntry(name.replace('.', '/')
    + ".class");
                 if (klasse == null)
                    throw new ClassNotFoundException("Finner ikke klassen "
    + NOTISKLASSE);
                 inn = arkiv.getInputStream(klasse);
                 ut = new ByteArrayOutputStream(inn.available());
                 byte[] kode = new byte[4096];
                 int antall = inn.read(kode);
                 while (antall > 0)
                     ut.write(kode, 0, antall);
                     antall = inn.read(kode);
                 return ut.toByteArray();
             catch (IOException ioe)
                 throw new RuntimeException(ioe.getMessage());
             finally
                 try
                    if (inn != null)
                       inn.close();
                    if (ut != null)
                       ut.close();
                 catch (IOException ioe)
         }I hope somebody can help. :-)
    Regards,
    Knut St�re

    I'm not quite sure how Java handles local classes defined within a method, but from this example it seems as if the local class isn't loaded until it is actually needed, that is when the method is called, which seems like a good thing to me.
    The parent class is already loaded as you can see. It is the loading of the inner class that fails.
    But maybe there is something I've forgotten in my loading code? I know in the "early days" you had to do a lot more to load a class, but I think all that is taken care of by the superclass of my classloader now. All I have to do is provide the raw data of the class. Isn't it so?

  • Getting LinkageError with class loader

    I've written a class loader which extends java.net.URLClassLoader. My class is called EntryClassLoader. It only ovverides findClass() so that it will search a user-supplied path for a class. Beloww is the code:
    public Class findClass(String className) throws ClassNotFoundException
    try {
    // First check to see if the user has prepended some
    // directory path
    if (className.indexOf(File.separatorChar) != -1) {
    String path = className.substring(0,
    className.lastIndexOf(File.separatorChar));
    className = className.substring(className.lastIndexOf(File.separatorChar)
    + 1);
    addURL(new File(path).toURL());
    return super.findClass(className);
    catch (MalformedURLException e) {
    e.printStackTrace();
    return null;
    Here's a sample test program I've written:
    public static void main(String args[]) throws Exception {
    EntryClassLoader loader = new EntryClassLoader();
    loader.findClass("TestPlayer");
    loader.findClass("TestPlayer");
    If I comment out the 2nd call to findClass(), the program runs fine, and I know that TestPlayer is successfully loaded. With the code as is however, I get the following error:
    Exception in thread "main" java.lang.LinkageError: duplicate class definition: TestPlayer
    at java.lang.ClassLoader.defineClass0(Native Method)
    at java.lang.ClassLoader.defineClass(ClassLoader.java:509)
    at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:123)
    at java.net.URLClassLoader.defineClass(URLClassLoader.java:246)
    at java.net.URLClassLoader.access$100(URLClassLoader.java:54)
    at java.net.URLClassLoader$1.run(URLClassLoader.java:193)
    at java.security.AccessController.doPrivileged(Native Method)
    at java.net.URLClassLoader.findClass(URLClassLoader.java:186)
    at nirex.EntryClassLoader.findClass(EntryClassLoader.java:33)
    at TestLoader.main(TestLoader.java:8)
    Could someone please explain why I might be getting this error. And I really don't understand why it works if I only call findClass() once. Thanks.
    John

    Check if findLoadedClass(className) is null and load only then. If findLoadedClass() returns a non-null value, the class has already been loaded.

  • Help Needed on a similar but not same class loader problem

    Hi,
    Please help...
    There is a ClassLoader called MyLoader that overrides default findClass() method to decrypt already encrypted class files available in a separate jar file.
    MyClass also contains a public static method launchMe() method that starts off with a call similar to loadClass("ApplicationMainClass");
    The MyLoader class is also encrypted
    I modified the default launcher (c) code to:
    First find the encrypted MyLoader file then decrypt it and create a byte array.
    The byte array, along with the system class loader and other required arguments, is passed to DefineClass native method (defined in jvm.dll)
    Note: The system class loader class has been instantiated using static method ClassLoader.getSystemClassLoader() through Java's invocation API.
    The DefineClass succeeds and I'm able to instantiate MyLoader and later call launchMe() to start application.
    Now i come to the problem:
    I'm not able to use any class other that those in rt.jar (i.e.standard classes) in MyLoader class. I end up with a runtime error ClassDefNotFoundError while trying to load any third party jar.
    The classes i need are present in class path and also in the local jre's ext that i use to launch my app.
    Although i can avoid using third party jar in MyLoader but if there is any way...
    Piyush

    make sure that third party jar resides in your library.....
    or else put rt.jar and external jars under same folder
    this is matter of path.... no else than this.......
    cheers
    Rajesh42

  • Class Loader confusion

    I am trying to use java.net.URLClassLoader to load classes dynamically from jar files. The strange thing is, I can only get this to work successfully with one particular Jar file. With any other Jar file I have tried, I get a java.lang.NoClassDefFoundError. I'm trying to figure out what is different about this particular jar file.
    The first thing I should point out is that when I create the URLClassLoader, I can successfully load the appropriate classes using loadClass(). So I am not mistyping the filename of the Jar or anything like that.
    It's only when I try to create an instance of a class that is not in the Jar but uses a class in the Jar file, that I get the NoClassDefFoundError.
    The second thing I have noticed is that everything works fine when run using the Sun JDK1.3 VM. It is only in my production environment (Lotus Notes) that the problem occurs. It seems the Notes class loader is doing things differently to the sun class loader. Perhaps this is a security issue?
    Can anyone shed any light on why this is occuring? Why does everything work fine with one particular Jar (Jakarta POI) but no others I have tried? And why does it stop working in the Notes environment?
    Any help is appreciated.
    And here is my code:
        public void test()
            URL[] urls=new URL[1];
            File file=new File("c:/software/libraries/tablelayout.jar");
            try
                urls[0]=file.toURL();
            catch (MalformedURLException e)
                e.printStackTrace();
                return;
            ClassLoader cl = this.getClass().getClassLoader();
            ClassLoader loader=URLClassLoader.newInstance(urls,cl);
            Class agentClass=null;
            try
                // Test if we can actually load the class
                Class testClass = loader.loadClass("com.lowagie.text.pdf.PdfReader");
                System.out.println("loaded test class");
                agentClass = loader.loadClass("test.RandomAgent");
            catch (ClassNotFoundException e)
                e.printStackTrace();
                return;
            AgentBase agent=null;
            try
                agent = (AgentBase) agentClass.newInstance(); // This is where the NoClassDefFoundError is thrown
            catch (Exception e)
                e.printStackTrace();
                return;
            agent.NotesMain();
        }And the stack trace I get:
    loaded test class
    java.lang.NoClassDefFoundError: com/lowagie/text/pdf/PdfReader
         at java.lang.Class.newInstance0(Native Method)
         at java.lang.Class.newInstance(Class.java:262)
         at TestAgentUsingClassLoader.NotesMain(TestAgentUsingClassLoader.java:64)
         at lotus.domino.AgentBase.runNotes(Unknown Source)
         at lotus.domino.NotesThread.run(NotesThread.java:218)

    I figured it out. Thanks to this post: http://forum.java.sun.com/thread.jspa?threadID=484866&messageID=2267796
    The class test.RandomAgent was actually being loaded by the system classloader, even though I had asked to create it using the URLClassLoader. The URLClassLoader delegates the creation to its parent (the system class loader) which found the test.RandomAgent class on the system class path. Thereon, all class created by the RandomAgent class would have been loaded by its ClassLoader, i.e. the system class loader.
    To fix this, I had to ensure the test.RandomAgent class was not on the system classpath. To do that, I had to put it in its own Jar and add that jar to the URLClassLoader list.
    It turned out that the reason it worked with one jar (Jakart POI) was that that Jar was on my system classpath! So that was a red herring.

  • Error building project using kXML2 - "Class loading error: Wrong name"

    Hi,
    I'm testing the XML-Parser KXML2 and downloaded the latest package, but the minimal version (kxml2-min.zip). I put this file into the directory "%j2mewtk%\apps\KxmlTest\lib" and wrote the lines
    import org.kxml2.io.*;
    import org.xmlpull.v1.*;
    When I try to build the project with the Wireless Toolkit (v1.04) it spits out the following error:
    Error preverifying class kxml2.io.KXmlParser
    Class loading error: Wrong name
    com.sun.kvem.ktools.ExecutionException: Preverifier returned 1
    Build failed
    I also tried the full package "kxml2.zip" but the same error occurs.
    How can I get rid of this? Thanks in advance!

    Okay, finally worked it out (hopefully). I unpacked the archive to a directory (say "%J2MEWTK%\apps\KxmlTest\tmpclasses") and then preverified them "manually":
    %J2SDK%\bin\preverify.exe -classpath "%J2MEWTK%\apps\KxmlTest\tmpclasses";"%J2MEWTK%\lib\midpapi.zip" org.kxml2.io.KXmlParser
    %J2SDK%\bin\preverify.exe -classpath "%J2MEWTK%\apps\KxmlTest\tmpclasses";"%J2MEWTK%\lib\midpapi.zip" org.xmlpull.v1.XmlPullParser
    %J2SDK%\bin\preverify.exe -classpath "%J2MEWTK%\apps\KxmlTest\tmpclasses";"%J2MEWTK%\lib\midpapi.zip" org.xmlpull.v1.XmlPullParserException
    Then I packed them again to a jar-file:
    %J2SDK%\bin\jar.exe -cvf kxml2-min.jar %J2MEWTK%\apps\KxmlTest\tmpclasses\output\.
    That was all!

  • Performance issues with class loader on Windows server

    We are observing some performance issues in our application. We are Using weblogic 11g with Java6 on a windows 2003 server
    The thread dumps indicate many threads are waiting in queue for the native file methods:
    "[ACTIVE] ExecuteThread: '106' for queue: 'weblogic.kernel.Default (self-tuning)'" RUNNABLE
         java.io.WinNTFileSystem.getBooleanAttributes(Native Method)
         java.io.File.exists(Unknown Source)
         weblogic.utils.classloaders.ClasspathClassFinder.getFileSource(ClasspathClassFinder.java:398)
         weblogic.utils.classloaders.ClasspathClassFinder.getSourcesInternal(ClasspathClassFinder.java:347)
         weblogic.utils.classloaders.ClasspathClassFinder.getSource(ClasspathClassFinder.java:316)
         weblogic.application.io.ManifestFinder.getSource(ManifestFinder.java:75)
         weblogic.utils.classloaders.MultiClassFinder.getSource(MultiClassFinder.java:67)
         weblogic.application.utils.CompositeWebAppFinder.getSource(CompositeWebAppFinder.java:71)
         weblogic.utils.classloaders.MultiClassFinder.getSource(MultiClassFinder.java:67)
         weblogic.utils.classloaders.MultiClassFinder.getSource(MultiClassFinder.java:67)
         weblogic.utils.classloaders.CodeGenClassFinder.getSource(CodeGenClassFinder.java:33)
         weblogic.utils.classloaders.GenericClassLoader.findResource(GenericClassLoader.java:210)
         weblogic.utils.classloaders.GenericClassLoader.getResourceInternal(GenericClassLoader.java:160)
         weblogic.utils.classloaders.GenericClassLoader.getResource(GenericClassLoader.java:182)
         java.lang.ClassLoader.getResourceAsStream(Unknown Source)
         javax.xml.parsers.SecuritySupport$4.run(Unknown Source)
         java.security.AccessController.doPrivileged(Native Method)
         javax.xml.parsers.SecuritySupport.getResourceAsStream(Unknown Source)
         javax.xml.parsers.FactoryFinder.findJarServiceProvider(Unknown Source)
         javax.xml.parsers.FactoryFinder.find(Unknown Source)
         javax.xml.parsers.DocumentBuilderFactory.newInstance(Unknown Source)
         org.ajax4jsf.context.ResponseWriterContentHandler.<init>(ResponseWriterContentHandler.java:48)
         org.ajax4jsf.context.ViewResources$HeadResponseWriter.<init>(ViewResources.java:259)
         org.ajax4jsf.context.ViewResources.processHeadResources(ViewResources.java:445)
         org.ajax4jsf.application.AjaxViewHandler.renderView(AjaxViewHandler.java:193)
         org.apache.myfaces.lifecycle.RenderResponseExecutor.execute(RenderResponseExecutor.java:41)
         org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:140)
    On googling this seems to be an issue with java file handling on windows servers and I couldn't find a solution yet. Any recommendation or pointer is appreciated

    Hi shubhu,
    I just analyzed your partial Thread Dump data, the problem is that the ajax4jsf framework ResponseWriterContentHandler triggers internally a new instance of the DocumentBuilderFactory; every time; triggering heavy IO contention because of Class loader / JAR file search operations.
    Too many of these IO operations under heavy load will create excessive contention and severe performance degradation; regardless of the OS you are running your JVM on.
    Please review the link below and see if this is related to your problem.. This is a known issue in JBOSS JIRA when using RichFaces / ajaxJSF.
    https://issues.jboss.org/browse/JBPAPP-6166
    Regards,
    P-H
    http://javaeesupportpatterns.blogspot.com/

  • How can I get a dynamic list of Classes Loaded

    I assume this may need to use some sort of reflection. Does
    anyone have code or ideas where I can:
    a) I can get a list of all Classes loaded and their
    properties. This would probably be all instances of Class
    b) A list of all
    global instance variables. (This may not even be possible. I
    know it can be done in other languages)
    I assume this may need to use some sort of reflection.
    Thank you

    Adobe Newsbot hopes that the following resources helps you.
    NewsBot is experimental and any feedback (reply to this post) on
    its utility will be appreciated:
    mx.controls.List (Flex 3):
    If the data is incorrect, you can call the preventDefault()
    method to stop Flex from passing the new data back to the list
    control and from closing the
    Link:
    http://livedocs.adobe.com/flex/3/langref/mx/controls/List.html
    Displaying icons in a Flex List control at Flex Examples:
    http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/
    --> <mx:Application xmlns:mx=&quot;
    http://www.adobe.com/2006/mxml&quot;
    Link:
    http://blog.flexexamples.com/2007/08/17/displaying-icons-in-a-flex-list-control/
    Populate the list -- Flex 2.01:
    You populate a list-based form control with the
    <mx:dataProvider> child tag. The <mx:dataProvider> tag
    lets you specify list items in several ways.
    Link:
    http://livedocs.adobe.com/flex/201/html/tutorial_controls_019_4.html
    Smooth Scroll for Horizontal List - Flex India Community |
    Google:
    I have created image gallery with Horizontal List[Flex 2.0].
    Just as below ref site. My Problem is i need a smooth scroll for
    Horizontal List. where images
    Link:
    http://groups.google.com/group/flex_india/browse_thread/thread/a12441143b98d32c?hide_quote s=no
    Creating a List control -- Flex 2.01:
    The following example code adds a handler for a change event
    to the List control. Flex broadcasts a mx.ListEvent.CHANGE event
    when the value of the control
    Link:
    http://livedocs.adobe.com/flex/201/html/dpcontrols_062_03.html
    Disclaimer: This response is generated automatically by the
    Adobe NewsBot based on Adobe
    Community
    Engine.

Maybe you are looking for

  • What's in the JVM Process's Memory Space?

    Hello I'm noticing the following behavior on an NT system. On application startup, I see Total Heap 9 MB Used Heap 5.5 MB java.exe memory (from NT Task Manager) 36 MB After a "login" operation which loads a few more classes: Total Heap 12.5 MB Used H

  • Can you get iTunes to sync in the background?

    First, I'm on a PC, not a Mac... What I mean by my question is, that I'd like iTunes to sync every time I attach the iPhone, but I don't necessarily want the iTunes application to maximize and come to the front upon plugging the phone back in. For th

  • How to set pages in a PDF the same magnificaiton

    I have a PDF that is set to 100% for Magnification. It open in 100% but when I click around the PDF, the magification changes to 182%. Where is the setting that I can set no matter where I click in the PDF, the magification is ALWAYS 100%? Thanks in

  • Insert filler in text file

    Hi... Well .... i am using Clover Etl... tool for reading a text file and then performing some operations on it.... Each record on the text file is on a new line...Now what i would like to do is that make each line of the same length . For eg. i have

  • Host server name is blank.

    Hi All,       we are running virtual machines on host servers. we have installed scom agents on virtual machines. when I go to windows computers in monitoring pane and select display attribute as "host server name" and  "virtual machine" it is blank