RMI and the class loader delegation model

Hello,
I need to know what the class loader delagation chain looks like when RMI does dynamic class loading. What is the RMIClassLoader's parent? Does it delegate to Thread.currentThread().getContextClassLoader()?
In a test application I can debug the chain which looks like this:
sun.misc.Launcher$AppClassLoader@bac748
sun.misc.Launcher$ExtClassLoader@7172ea
The AppClassLoader is the class loader for the test and is coincident with getSystemClassLoader(). Its parent is the ExtClassLoader which I believe is in charge of loading anything from jre/lib/ext. But I don't know how to get a reference to the RMIClassLoader in order to find out what it's parent is.
I would appreciate any info on this.
Thanks in advance,
Joe

Well that was easy.
I just used the RMIClassLoader.getClassLoader(String codebase) and was able to determine the chain.
FYI: the chian is as follows:
ExtClassLoader <-- AppClassLoader <-- sun.rmi.server.LoaderHandler
Of interest, if you have a custom class loader its parent will most likely be the AppClassLoader but the rmi class loader will not chain off of your custom class loader. It does some interesting things in order for this to work. It will look for custom class loader to load interfaces but will use the RMIClassLoader to load stubs. Pretty cool.
Thanks anyway.
Joe

Similar Messages

  • A thread, a loaded class, and a class loader

    I have a class loaded. How can I find the class loader of the thread this class was loaded into? Is the class.getClassLoader() the same thing?

    Great article...
    http://www.javaworld.com/javaworld/javaqa/2003-06/01-qa-0606-load.html
    Answers the question and then some.

  • Is it possible clear the class loader cache programatically?

    Hi,
    Is it possible clear the class loader cache programatically?
    Thanks

    By the cache do you mean the loaded classes? If so, you can do that by discarding any pointer you have to the class loader and creating a new class loader. ...though I wonder why you would need to do that...

  • Referencing external classes in the classes loaded into ORACLE8i

    Hi
    If I have to load a .class file into oracle8i and if it references another class XYZ.class file in the path /export/home/user what should I do to resolve during the loading. What happens if XYZ.class imports from a test.jar.
    Thanx

    Any external class references from classes loaded in ORACLE 8i must also be loaded into the database. The classes loaded into the db must be transitively closed. All external class reference must be either in the CORE Java api's (provided by Oracle) or must be loaded with the class in question.

  • HT4623 after the ios 7.0 update my iphone 4s and ipad keep switching in between the home screen and the apple loading screen, can anybody help?

    Can anybody help with the above?
    i.e
    both my iphone 4s and ipad switch in between the home screen and the apple loading screen
    Many thanks

    I would connect each device to a power source, and then reset them by holding the power button and the home button until they turn off.
    If it keeps happening, I would put the devices in recovery mode and restore them with iTunes.
    This article will help with that if needed:
    iOS: Unable to update or restore
    http://support.apple.com/kb/HT1808

  • While in email today, the computer began flashing. I had to turn off with button. When I turned it back on, I got the apple icon and the moving loading wheel. It would turn for about 60 seconds and then stop. I turned off again. I now have a black screen.

    while in email today, the computer began flashing. I had to turn off with button. When I turned it back on, I got the apple icon and the moving loading wheel. It would turn for about 60 seconds and then stop. I turned off again. I now have a black screen.

    Hi wiesenruth,
    If you are having issues starting up or booting your computer, you may find the following articles helpful:
    Troubleshooting: My computer won't turn on
    http://support.apple.com/kb/TS1367
    Mac OS X: Gray screen appears during startup
    http://support.apple.com/kb/ts2570
    Regards,
    - Brenden

  • Stand alone class and the class path

    Hi,
    I have a simple Java project in Eclipse environment. The project has it's class path,
    that contains a jar file that I need to use.
    The project runs perfect in the Eclipse.
    Now, I need to take the main class out of my project, to function alone in another environment.
    My problem is that out of the environment, I don't know how the class should know that classpath.
    I moved that jar to the same folder that the class located in, but I don't know how to tell it that the jar is there.
    My goal is to run my standalone class from another java class.
    I'm afraid that examples in command environment wouldn't help me.
    Thanks a lot for any help !

    moshi wrote:
    I have a simple Java project in Eclipse environment. The project has it's class path,
    that contains a jar file that I need to use.Ok, so you have a class that you have written that depends on an external library. Fair enough.
    The project runs perfect in the Eclipse.
    Now, I need to take the main class out of my project, to function alone in another environment.Maybe (just maybe!) defining what exactly that "other environment" is could help us help you.
    My problem is that out of the environment, I don't know how the class should know that classpath.Well, obviously that depends on what that other environment is.
    You must have some way to influence that other environments classpath, or you couldn't even get it to call/use your class.
    I moved that jar to the same folder that the class located in, but I don't know how to tell it that the jar is there.Now you're just guessing.
    My goal is to run my standalone class from another java class. That's simple enough, you probably do it all the time.
    I'm afraid that examples in command environment wouldn't help me.And why exactly is that?
    Do you realize that you tell us far too little about your problem for us to be able to actually help you?

  • Differences between R7950-2PMD3GD5/OC and the Twin Frozr III Model

    I notice that the R7950-2PMD3GD5/OC has reference design cooling compared to the double fan Frozr III 7950
    It is also clocked 50mhz slower!
    My 7950 (Frozr III) also has 7970 PCB with 6+8 power connectors...
    What other differences am I missing here? Which card is better... in your opinion
    Frankly given these huge differences I am convinced that the single fan/slower clock/ 7950 pcb are all reasons to say that the Frozr III is better

    with those 2 cards here are the differences:
    R7950-2PMD3GD5/OC has a single central fan on it and will run slightly hotter as it has a more limited capacity to move air through the fin array (would also expect it to be more noisy as that fan will spin faster all the time in an attempt to cool the card down). now clock rates with the same GPU on this to the other are subject to how good the GPU sample can handle it and as this one has stock power delivery its is restricted automatically to the standard stock max voltages so unless the GPU is very good it will be limited alot more then the equivalent R7950 Twin Frozr 3GD5/OC in theory.
    R7950 Twin Frozr 3GD5/OC has a twin fan cooler that moves more air volume (it will be quieter as the fans can spin slower while suppling the required air to cool the GPU down) and as a result it will run cooler under operation at load especially (less heat and a lower chance of damage long term to the connections under the GPU). the board has heavier power delivery to the stock so it can handle more voltage supply with less droop compared to the other but again its subject to the individual GPU sample on the card and how it responds to an over-clock <--- but in theory if the GPU you have on the card is good it should be capable of much higher stable clocks and voltages to the reference PCB version on the other card just due to the fact it has alot more to deliver to the core (but its up to the GPU to how it reacts to it as its all random lately "silicon lottery time") and even if you run it at the stock levels it will still be alot more stable long term as the power delivery will not be being as taxed all the time as the stock type.
    here is my own personal opinion of the 2 in conclusion:
    R7950-2PMD3GD5/OC - OK this is cheaper but I would doubt how long it would last long term before it gave up and I would also expect it to get very hot compared to the other and more loud under load.
    R7950 Twin Frozr 3GD5/OC - with the twin frozr i would expect it to be cooler as it runs, quieter too and the power to be more stable and as a result it would be a longer life card that will last a longer time after the other would have gave up.

  • Problem with outer joins and the class indicator/discriminator

    Hello,
    I am having a problem defining a query in toplink (10.1.3.3).
    In the workbench, I have created a parent and 2 child descriptors. The parent is "AbstractValue", the children are "DefaultValue", classified by the discriminator 'DEF', and "OverrideValue", classified by 'OVR', both located in the same table.
    Another descriptor (containing a one-on-one mapping to both a "DefaultValue", and a "OverrideValue") needs to be queried for its 'value'.
    The way the query should act is: If an override value (row) exists, this one applies for that object. If an override doesn't exist, return the default value.
    The query then comes down to (as I have it now):
    builder.getAllowingNull("OverrideValue").getAllowingNull("value").ifNull(builder.get("DefaultValue").get("value")).equal(builder.getParameter(VALUE_PARAM));
    The problem is that toplink adds the distinction for the different kind of "values" in the where clause WITHOUT checking for null values e.g. it performs an outer join, but then still checks for the discriminator value thus
    ....t1.ovr_id = t2.id(+) AND t2.discriminator = 'OVR' AND ...
    instead of
    ... LEFT JOIN values t2 ON (t1.ovr_id = t2.id AND t2.discriminator = 'OVR') ...
    This leads to the behaviour that the query returns ONLY the objects that have override and default values.
    An overview of the queries (simplified)
    Toplink, at the moment, returns only results if both override and default values exists:
    SELECT t1.id
    t1.def_id,
    t1.ovr_id
    FROM values t2,
    parameter t1,
    values t0
    WHERE nvl(t2.value, t0.value) = 15 AND
    t1.ovr_id = t2.id(+) AND t2.discriminator = 'OVR' AND
    t1.def_id = t0.id AND t0.discriminator = 'DEF'
    Situation Wanted:
    SELECT t1.id
    t1.def_id,
    t1.ovr_id
    FROM parameter t1
    LEFT JOIN values t2 ON (t1.ovr_id = t2.id AND t2.discriminator = 'OVR')
    JOIN values t0 ON (t1.def_id = t0.id AND t0.discriminator = 'DEF')
    WHERE nvl(t2.value, t0.value) = 15
    Anyone know if there is some statement I am missing to allow an actual outer join on descriptors containing class indicators/discriminators? A possible rewrite?
    Thanks in advance,
    Rudy

    This is a bug in TopLink's outer join support for Oracle. Currently the outer join is put in the where clause, instead of the from clause, as we do on other platforms. You might be able to fix it by changing your OraclePlatform to return false for shouldPrintOuterJoinInWhereClause().
    Please log this bug on EclipseLink, or through Oracle technial support.
    There is a workaround using,
    descriptor.getInhertiancePolicy().setAlwaysUseOuterJoinForClassType(true);
    James : http://www.eclipselink.org

  • Java Reflection and dynamic class loading

    I am trying to load my classes 'dynamically' using java reflection, which is a feature absolutely necessary for my webapp. I could not get this to work as of yet. Could someone please give me a piece of sample code that would do the following :
    - return the value (String) of known method y from class x
    - class x is only known at runtime (from the query-string in this case)
    - method y is known
    Thanks in advance.
    cheers,
         Tom
    PS: Please do not give me any links to tutorials/articles that do not do the EXACT thing that I asked for. Thank you.

    tried it, but it always gives me a MethodNotFoundException, because its trying to find my class in java.lang.String for some reason...
    heres part of the code (its an altered version of the code given in the invoke tutorial):
    public String getMethodReturnValue(String methodName, String className) {
    String result = null;
    Class theModuleClass = String.class;
    Class[] parameterTypes = new Class[] {};
    Method concatMethod;
    //Object[] arguments = new Object[] {parameters};
    try {
    concatMethod = theModuleClass.getMethod(methodName, null);
    result = (String) concatMethod.invoke(createObject(className), parameterTypes);
    } catch (NoSuchMethodException e) {
    result = e.toString();
    } catch (IllegalAccessException e) {
    result = e.toString();
    } catch (InvocationTargetException e) {
    result = e.toString();
    return result;
    private Object createObject (String className) {
    Object object = null;
    try {
    Class classDefinition = Class.forName(className);
    object = classDefinition.newInstance();
    } catch (Exception e) {}
    return object;
    Thanks for any help!
    -Tom

  • Recently firefox loads LinkedIn home page as text only. Was no problem before I installed latest version and the page loads fine in Explorer and Safari.

    See image.

    Thank you for the screenshot. Something is preventing the style from loading.
    There is an option in page permissions I would check first:
    # Right click on the page and select "Page Info"
    # Under Media make sure "Block Images from..." is not checked
    Then check out: [[Websites look wrong or appear differently than they should]]
    Mainly I would focus on the cache, as the cached page might be corrupt. To clear any corrupt pages it is possible to forget the site from the about:permissions page -> this is not recoverable.
    You can open the Web Console (Firefox/Tools > Web Developer).
    Check on the Network tab if any content is blocked and has a file size 0 (zero).
    * https://developer.mozilla.org/Tools/Web_Console

  • I get a message when going to any webpage "server not found" or "problem loading page". I click on try again and the page loads fine. This happens on bookmarked pages or manually entered urls. The issues started after I updated Firefox.

    Server not found messages and problem loading page message since I updated to the latest version of Firefox. Usually will load the 2nd time after hitting the try again option.
    Does not happen with Internet Explorer at all.

    See:
    *http://kb.mozillazine.org/Error_loading_websites

  • After installing Firefox6 many sites will not finish loading. I click on "stop loading this page" and then click on "reload this page" and the page loads. Also if I disable javascript the page will load.

    After installing Firefox 6 MANY web site will not finish loading. I disabled all add-ons and still have the problem. If I disable javascript, the pages will load. When the page is trying to load, if I hit "stop loading this page" and then hit "reload this page", the page will load; but sometimes I have to do this 2-3 times for the page to finish loading. No problem with these pages using IE8.

    I see that you ave changed some network.http prefs.<br />
    Doing that can cause all kinds of problems because not all servers like such changes, so you can try to reset those prefs on the about:config page.<br />
    network.http.max-connections 48<br />
    network.http.max-connections-per-server 16<br />
    network.http.max-persistent-connections-per-proxy 16<br />
    network.http.max-persistent-connections-per-server 8<br />
    network.http.pipelining true<br />
    network.http.pipelining.firstrequest true<br />
    network.http.pipelining.maxrequests 8<br />
    network.http.proxy.pipelining true<br />
    network.http.request.max-start-delay 0<br />
    Start Firefox in [[Safe Mode]] to check if one of your add-ons is causing your problem (switch to the DEFAULT theme: Tools > Add-ons > Themes).
    See [[Troubleshooting extensions and themes]] and [[Troubleshooting plugins]]

  • I just bought a new macbook pro 13-inch. I ran coconut battery test and it says age of the macbook is 22 weeks. And the battery load cycles shows 4 and battery capacity is 96%. Is this all normal? Does anyone have same issues?

    I just bought a new macbook pro 13-inch 6 days ago. I ran coconut battery test and it says age of the macbook is 22 weeks. It shows 4 battery load cycles and battery capacity is 96%. Is this all normal? Does anyone have same issues?

    "Is this all normal?"
    Yes.
    "Does anyone have same issues?"
    What issues?
    Coconut indicates an approximate battery capacity, and 96% is excellent.  During testing and run-in, the MBP is charged and discharged, and a cycle count of 4 is appropriate.

  • Everytime I click on a link and a new tab/window opens to open the link - i get an alert that says URL is not valid and cnnot be loaded. I click ok and the page loads fine. How do I get rid of this alert?

    See above

    Actually the OP is running Firefox 3.6.8, but has a user agent that is corrupted by an extension (NET_mmhpset)
    You can check the '''general.useragent''' prefs on the about:config page.<br />
    You can open the '''about:config''' page via the location bar, just like you open a website.<br />
    Filter: general.useragent<br />
    If '''general.useragent''' prefs are bold (user set) then you can right-click that pref and choose Reset.<br />
    <br />
    See [[Web sites or add-ons incorrectly report incompatible browser]] and [[Finding your Firefox version]]
    See also http://kb.mozillazine.org/Resetting_your_useragent_string_to_its_compiled-in_default

Maybe you are looking for

  • I am trying to transfer my songs from an old to computer to a new computer on iTunes with Ion products

    I am trying to transfer my music from an old computer to a new one.  Nothing I recorded from Ion (I have spent over 2 years on this, so I am almost in tears thinking I have wasted 2 years) is showing up on the new computer.  When I put a burned CD in

  • Font Issue with Report Generation Toolkit for Microsoft Office

    I have been using this toolkit for only a few days now, but I just have to get this issue off my back. When developing a toolkit it would be a good idea to use the same cluster to represent fonts in ALL places. If you look at "Excel Set Graph Font" v

  • Link Airport Express to an AirPort Time Capsule to use Airplay?

    I am thinking about getting an 2GB AirPort Time Capsule. I use the Airplay feature on my Airport Express that is not part of the AirPort Time Capsule and that is the only reason I have not replaced the Airport Express with the Airport Time Capsule. H

  • SQL service pack installation

    Installing SQL 2005 through SQL4SAP.VBS will install its available service pack 2 automatically (or) Do we need to install manually.   Can we install the service pack 2 manually even after SAP Installtion .If so,please give the procedure. Thanks

  • Error when installing update for desktop software

    when i try to update my software i am getting the error message saying  Blackberry Destiop Software requires that Microsoft Visual C++ 2008 SP1 RAedistributable package is installed . Can some one please help me