Pickup a class in application without bouncing the WLS

Hi,
I've an application(deployed on WLS) which basically takes the name of a class and delegates it to another process, which then loads the class and calls a few methods reflectively. For this, I want the second process to reference to a directory(outside the ear) so that it looks for the resolution in this directory.
Now, the problem is, how to make the application refer to this directory. I do not want them to be loaded by server classloader as they will unnecessary be available to all other applications. So, adding the name to server classpath or deploying it as shared library is ruled out.
Other requirement is, the jar file can be introduced dynamically by a user into the directory and the application should take care of it for any references. Bouncing application should do this needful.
Does WLS have a feature to cater to this need?
Thanks.
Nitin

hi thanks at first,
the thing you mentioned could be a problem, but I dont think it is.
If I have the full qualified name (which I havent) then everything goes normal. I only have to load the "twoButtons" class and not the other (actionadapter class), so I dont think this is the point. In this case the twoButtons constructor constructs an object of the actionadapter class and everything goes well. The bad thing is though that I do not have the full qulified name :(
Invocation target exception tells me (in own words): Tried to acces the constructor of the actionadapter class (which is not public) out of class reflectionTest class .
reflectionTest is the class where the reflection stuff happens and the twoButttons class is defineClass() ed.
The problem is, only twoButtons class has the rights to call methods from the actionadapter class, the reflection class does not. BUT: I do not call the actionadapter methods from the reflection class. I call them only from the twoButtons class.
I hope somebody understands my problem :)

Similar Messages

  • Trun off archiving without bouncing the database

    Hello,
    Is there a way to turn off archive log mode without bouncing the database in 9i? I know we can turn off automatic archival with out bringing down the db.
    Thanks.

    Hi,
    One thing is ARCHIVELOG and NOARCHIVELOG, another thing is automatic or manual archiving. When the Database is configured in ARCHIVELOG mode, you can dinamically turn on or off automatic archiving, but you cannot switch from ARCHIVELOG to NOARCHIVELOG (or viceversa) without shutting down the DB : this change has to be done when the DB is mounted but not open.

  • I m trying to manage space in my iPhone but what I find is I m not able to delete document data alone of an application without deleting the entire application ... Any other suggestions or methods to accompanish this? Any pointers welcome... Is this a bug

    I m trying to manage space in my iPhone but what I find is I m not able to delete document data alone of an application without deleting the entire application ... Any other suggestions or methods to accompanish this? Any pointers welcome... Is this a bug

    You mean take the cover off of the iPhone, to look inside?  I'd recommend against it.  Even with warranty expired, you might qualify for an out-of-warranty service, which for 3GS is $149.
    Other than that, any repair/service options are going to cost money.  You might want to see if a wireless carrier will let you get a new contract & phone.
    Out of curiousity, you're just using at as, basically, an iPod Touch, if there's no cell provider?  Did I understand that correctly?

  • Loading a class via reflection without knowing the full qualified path ?

    Hi there
    I d like to load a class via reflection and call the constructor of the class object. My problem is that I dont know the full qulified name e.g. org.xyz.Classname bur only the Classname.
    I tried different things but none seem to work:
         1. Class c = Class.forName("Classname");  //does not suffice, full qualified name required
    2. ClassLoader classloader = java.lang.ClassLoader.getSystemClassLoader();
             try {
               Class cl = classloader.loadClass(stripFileType(Filename));//if i do not pass the full qualified name i get a ClassNotFoundException
    3. I tried to consruct a class object with my own classloader , calling:
              Class cl = super.defineClass(null, b, 0, b.length );     b is of type byte[]This almost works. I get a class Object without knowing the full qulified path. I can transform a filename into a raw array of bytes and I get the class out of it. But there is still a problem: If there are more than on classes defined in the same textfile I get an InvocationTargetException.
    It looks like this:
    package org.eml.adaptiveUI.demo;
    import com.borland.jbcl.layout.*;
    import java.awt.*;
    import org.eml.adaptiveUI.layout.*;
    import javax.swing.*;
    import java.awt.event.*;
    * <p>Title: </p>
    * <p>Description: </p>
    * <p>Copyright: Copyright (c) 2003</p>
    * <p>Company: </p>
    * @author not attributable
    * @version 1.0
    public class twoButtons extends JFrame {
      SPanel sPanel1 = new SPanel();
      JButton jButton1 = new JButton();
      GridBagLayout gridBagLayout1 = new GridBagLayout();
      GridBagLayout gridBagLayout2 = new GridBagLayout();
      public twoButtons() throws HeadlessException {
        try {
          jbInit();
        catch(Exception e) {
          e.printStackTrace();
      public static void main(String args[]){
        twoButtons twob = new twoButtons();
        twob.pack();
        twob.show();
      private void jbInit() throws Exception {
        this.getContentPane().setLayout(gridBagLayout1);
        jButton1.setText("button 1");
        jButton1.addActionListener(new TransformationDemo_jButton1_actionAdapter(this));
        this.getContentPane().add(sPanel1,  new GridBagConstraints(0, 0, 1, 1, 1.0, 1.0
                ,GridBagConstraints.CENTER, GridBagConstraints.BOTH, new Insets(57, 52, 94, 108), 35, 44));
        sPanel1.add(jButton1,  new GridBagConstraints(0, 0, 1, 1, 0.0, 0.0
                ,GridBagConstraints.CENTER, GridBagConstraints.NONE, new Insets(5, 41, 0, 0), 0, 0));
      void jButton1_actionPerformed(ActionEvent e) {
        System.out.println("button 1 source: " + e.getSource());
        System.out.println("d: " + e.getID());
       System.out.println("/n commmand: " + e.getActionCommand());
    class TransformationDemo_jButton1_actionAdapter implements java.awt.event.ActionListener {
      twoButtons adaptee;
      TransformationDemo_jButton1_actionAdapter(twoButtons adaptee) {
        this.adaptee = adaptee;
      public void actionPerformed(ActionEvent e) {
        adaptee.jButton1_actionPerformed(e);
    }As you can see there is the class TransformationDemo_jButton1_actionAdapter class defined in the same classfile. The problem is now that the twoButtons constructor calls the TransfomationDemo_jButton1_actionAdapter constructor and this leads to InvocationTargetException. I dont know if this is a java bug because it should be possible.
    Can you help me?

    hi thanks at first,
    the thing you mentioned could be a problem, but I dont think it is.
    If I have the full qualified name (which I havent) then everything goes normal. I only have to load the "twoButtons" class and not the other (actionadapter class), so I dont think this is the point. In this case the twoButtons constructor constructs an object of the actionadapter class and everything goes well. The bad thing is though that I do not have the full qulified name :(
    Invocation target exception tells me (in own words): Tried to acces the constructor of the actionadapter class (which is not public) out of class reflectionTest class .
    reflectionTest is the class where the reflection stuff happens and the twoButttons class is defineClass() ed.
    The problem is, only twoButtons class has the rights to call methods from the actionadapter class, the reflection class does not. BUT: I do not call the actionadapter methods from the reflection class. I call them only from the twoButtons class.
    I hope somebody understands my problem :)

  • Deploy simple Labview applications without installing the Labview runtime?

    [Labview 8.21 - Windows XP]
    Hello and a happy new year to all !
    I have coded very simple Labview applications that basically read text files (exported from Ms Excel), make some string operations, array sorting and at the end write another text file that is then imported in Ms Access. Now I would like other people from the School parents association to use this application on their own PC but ideally without having to install the Labview run-time;  for various reasons one of them being that they are not administrator of their PC, another reason being that I feel bad to ask them to install 100Mb of programs on their PC to execute my <1Mb applications. All that I can assume is that they have Excel and Access installed on their PC.
    I have read some postings on the Forum and in the Knowledge base from which I understand that the only way to use my application without the Labview runtime is to build a shared library that maybe I could then link via a VBA code from inside Excel or Access. But I cannot find any usable example on how to do that practically. And maybe it is not possible. 
    What is the easiest way to run such very simple Labview compiled applications on a PC that does not have Labview installed? Is Labview not at all built for such use?
    Thanks a lot for your help and ideas.
    Christophe

    You will need to have the runtime installed. There is a lot of other languages that also have the need for there own runtime, but they are commonly installed with the OS, so you don't realize it. Just building a dll won't solve this.
    There might be a hack possible, though. People have managed to strip down the required installation and been able to deploy the required parts of the runtime only. If you want to go this way, search on LAVA. But I'm not sure if it works with LV 8.20, and you will need to invest some time to figure out the minimum requirements. But be aware that it is a hack, so it's on your own risk.
    Felix
    www.aescusoft.de
    My latest community nugget on producer/consumer design
    My current blog: A journey through uml

  • How can i run external application without specifying the full path?

    for example, ms word executable file is winword.exe, but in java i am using the following command:
    Runtime.getRuntime().exec("\"C:\\Program Files\\Microsoft Office\\Office10\\winword.exe\");
    the thing is, i dont know where ms word is installed on every machine, so rather than making an assumption, do you know how i can run ms word without specifying the full path?
    thanks

    1) You could ask the user to tell you where it's at (and remember for next time)
    2) You could do a file search for it (and remember it for next time)

  • Clinet Application without joining the cluster

    Hi All,
    is it possible for client application to access the cache within a coherence cluster. The Client application is not a part of cluster and it didnt start with and cache config files or anything else.
    The client application just uses :
    NamedCache cache = CacheFactory.getCache("VirtualCache");
    if a client application starts with a cache-config file it will also join the cluster in this case the JVM of the client app will aslo be loaded/distributed/replicated with the cache contents ?
    Please clarify my doubts.
    Regards
    Srinivas.

    The only clean way of NOT joining the cluster is to connect via Extend.
    You can join the cluster, and specify LocalStorage=False parameter, however, that is only applicable for distributed cache. Replicated cache data still exists on every node. A bigger issue in my mind, is that your node will be actively managing membership of other members in the cluster, and that can become a problem.
    Timur

  • Migrating to Sharepoint 2013 from 2010 - Can you use the same URL for the Web Application without affecting the 2010 environment?

    Hi,
    I am currently trying to migrate our SharePoint 2010 environment to SharePoint 2013. The first thing I'm doing is creating a 2013 development environment to verify that this migration goes smoothly. I'm also doing this so that we will have a testing environment
    after the upgrade to 2013 is complete. 
    So here is my question: I have a 3 tier farm including; 1 app server, 1 wfe, and 1 sql server. I have made a copy of our SharePoint 2010 database and installed that on our sql server 2012 sever (This new environment is on 3 completely separate servers from
    our 2010 environment). I have also installed the prereqs and configured SharePoint 2013 on the App server and wfe servers, as well as configuring the necessary service applications (I have created a completely new 2013 database where I will migrate my 2010
    database content when I'm ready).
    I am now at the point where I need to create a new web application on the 2013 app server, where I will be migrating the copied 2010 database.  (Also note that we have a 2010 development site called https://[email protected])
    When I go to create a new web application in our 2013 dev environment, can I use the same url (https://[email protected]) to create this web app, or will this screw up our current 2010 dev environment?
    I'm new to SharePoint migrations, so I apologize if this is a stupid question.
    Thanks in advance for any insight you can share on this!
    Boe Barlage

    So, what you are recommending is that before I create a web application in my new 2013 environment, I need go into my hosts file on my 2013 app server and alter it to point to my 2013 wfe.
    Then after I do that, then I can create my new web application on my 2013 app server with the same url as my 2010 testing environment
    (https://[email protected]). 
    Then after that I should be able to access my new sharepoint 2013 environment at the same URL (https://[email protected])?
    I must be missing something.
    In your first reply, you told me to alter the host file on my 2010 app server and point it to my 2010
    wfe (I guess I thought it probably already is). You also told me to alter the host file on my 2013 app server and point it to my 2013 wfe. 
    so I am confused on after I do this, what url would I access my 2010 test environment, and what url would
    I access my 2013 test environment?
    I am fine with having my test environment as a different URL until I am totally ready to roll everything over and kill the 2010 site. But I want to make sure that when I migrate my database, none of the site links are broken.
    I also want to make sure that if I proceed this way, I want to be sure that I will be able to modify the URL to what my 2010 environment is (without a lot of headaches) when I am ready to kill the 2010 site.
    Thanks again for your help, it's much appreciated!
    Boe Barlage

  • Accessing an application without forcing the user to login

    I'm a new guy, so please forgive me if I don't have this quite right. I have an inquiry OAF application bolted on to apps R12 that I need to make available to users that do not have user IDs. They're all inside the firewall, so there are no issues with security as long as they can only access this single inquiry. Do I need to mount a separate OC4J server, or can this be done somehow with the existing apps OC4j server? Maybe based on the referring page or something? Can someone point me to anything that will get me started with this? Thanks.

    I found this topic in the forum which helps...
    How to make a seeded page in EBS bookmarkable
    I think it should work but let me check it out

  • Run External application without Exiting main application

    Hi,
    I am trying to implement a function that executes the external program from within my java application. I am using windows xp. I had googled for this and found some code but so far I am able to run the application in a condition if my main application exits. Instead I want to run the application without exiting my main application. How can I do that:
    Code I am using is:
    ========================
    try{
    Runtime.getRuntime().exec("external program");
    System.exit(0);
    catch (Exception err){
    err.printStackTrace();
    System.exit(-1);
    =========================
    my problem is I cannot run the external program without the line "System.exit(0)". If I remove that line, the external program only starts after I exit my main java application. Is there a way to run the external application without leaving the main application?
    By the way I am using the latest version of JDK 6 update 2 and Netbeans 5.5.1
    Thanks

    I tried and I tried and I couldn't make the same problem occur unless I specfically had a long task execute BEFORE calling the runtime command. See the code below:
    I tried a bunch of things, including having a GUI run before the Runtime call, after the runtime call. Neither affected the movie from being played.
    I tried with different versions of the runtime command, none of it made a problem.
    I tried running the application with a long task that would keep the main thread busy for a while AFTER I launched mplayer - no problem.
    The only thing that made the app work the way you describe was when I built the long task that keeps the main thread active for a while BEFORE I launched mplayer (which is the state of the code as I pasted it below).
    So my guess is that you have a single threaded application and you add the call to mplayer at the very end of your program's execution - thus it doesn't get called until the last thing. My suggestions:
    1) Move the call to the Start of your code, not the end
    2) Move your other work to a new thread so that it can be kicked off without holding the main thread in check.
    package movies;
    import inheritance.BaseWindow;
    import java.util.*;
    import java.io.*;
    class StreamGobbler extends Thread
        InputStream is;
        String type;
        OutputStream os;
        StreamGobbler(InputStream is, String type)
            this(is, type, null);
        StreamGobbler(InputStream is, String type, OutputStream redirect)
            this.is = is;
            this.type = type;
            this.os = redirect;
        public void run()
            try
                PrintWriter pw = null;
                if (os != null)
                    pw = new PrintWriter(os);
                InputStreamReader isr = new InputStreamReader(is);
                BufferedReader br = new BufferedReader(isr);
                String line=null;
                while ( (line = br.readLine()) != null)
                    if (pw != null)
                        pw.println(line);
                    System.out.println(type + ">" + line);   
                if (pw != null)
                    pw.flush();
            } catch (IOException ioe)
                ioe.printStackTrace(); 
    public class MyMainClass
        public static void main(String args[]) throws InterruptedException
             //This is just a GUI as a test
            BaseWindow bw = new BaseWindow();
            bw.show();
            //Keep App Running for a while
            int count = 0;
            while (count < 200) {
                 Thread.sleep(20);
                 count++;
                 System.err.println(count);
            if (args.length != 1)
                System.out.println("USAGE java movies.MyMainClass \"<movie to play>\"");
                System.exit(1);
            try
                Runtime rt = Runtime.getRuntime();
                //String[] cmds = new String[] { "cmd", "/c", "C:\\Mplayer\\mplayer.exe", args[0]};
                //String[] cmds = new String[] { "C:\\Mplayer\\mplayer.exe", args[0]};
                //Process proc = rt.exec(cmds);
                Process proc = rt.exec("C:\\Mplayer\\mplayer.exe "+args[0]);
                // any error message?
                StreamGobbler errorGobbler = new
                    StreamGobbler(proc.getErrorStream(), "ERROR");           
                // any output?
                StreamGobbler outputGobbler = new
                    StreamGobbler(proc.getInputStream(), "OUTPUT");
                // kick them off
                errorGobbler.start();
                outputGobbler.start();
                //Keep App Running for a while
    //            int count = 0;
    //          while (count < 2000000) {
    //                 Thread.sleep(200);
    //                 count++;
    //                 System.err.println(count);
                // any error???
                int exitVal = proc.waitFor();
                System.out.println("ExitValue: " + exitVal);
            } catch (Throwable t)
                t.printStackTrace();
    }I will restate myself:
    "I was not able to repeat the problem, except as described, as long as I took the hints mentioned in the article I posted into account and actually put them into action."
    Of course, as soon as I ignored those hints, I was able to reproduce the error described above quite easily in all the different tests I made... But I guess the OP implemented those fixes, right? He did say he read the article...
    Message was edited by:
    stevejluke

  • Trying to run the SOA/BPM managed server withOUT running the Admin server

    (This is for demo/development purposes... Using 11.1.1.4 in Windows 7 with 4gb)
    Because of memory constrains I am trying to run the BPM/workspaces application without needing the Admin to be running.
    When they both run, I can use the credentials I create with the Admin server but the response time is prohibitive and all my memory is used...
    It seems to run much faster when only the bpm managed server is running but then I cannot login ...
    So my question is simply: Whats the easiest way to set it up so I can use credentials elsewhere without requiring the admin server to be running?
    ( I could connect to an OID instance I have outside this server or the seeded demo they refer to in other posts ... but do these also require the admin server to be running???)
    aTdHvAaNnKcSe ! (thanks IN advance)
    Claudio
    Edited by: clichten on Aug 20, 2011 9:35 AM

    I don't know if what you want is possible. Only did a suggestion that works fine for me. I'm running SOA Suite and BPM Suite 11.1.1.5 on WLS 10.3.5
    Configure a new WLS domain and see if the BPM Dev template is available in your version.
    I've tuned my startup script (setSOADomainEnv.cmd) as follows:
    set JAVA_OPTIONS=%JAVA_OPTIONS%
    set DEFAULT_MEM_ARGS=-Xms512m -Xmx1024m
    set PORT_MEM_ARGS=-Xms1536m -Xmx1536m
    if "%JAVA_VENDOR%" == "Oracle" goto OracleJVM
    set DEFAULT_MEM_ARGS=%DEFAULT_MEM_ARGS% -XX:PermSize=128m -XX:MaxPermSize=512m
    set PORT_MEM_ARGS=%PORT_MEM_ARGS% -XX:PermSize=256m -XX:MaxPermSize=512m
    Use visualvm that's available from your jdk/bin directory to monitor your jvm and optimize it accordingly
    Regards,
    Melvin

  • Is there anyway to kill the email app. without rebooting the phone?

    I get emails, but I can't do anything on the screen.  It is totally unresponsive to touch. In addition, my sleep button is broken, so I can't reboot the phone.  (ordered new one, but not getting it for weeks).  Is there anyway to kill the email application without rebooting the phone?

    Thanks, I figured as much. Will I be able to save all my apps and content by importing them to my computer and then uploading them back to my iPad after I upgrade the iOS? If so, do you happen to know if a gen 1 iPad running an iOS 4.2.1 is able to upgrade to an iOS 5? I did read online that the iOS 6 is NOT compatible with it so I want to be sure the iOS 5 is before I go through the trouble...

  • Please help me to undeploy web applications without starting weblogic.

    My colleague deployed his web application to my weblogic domain. However, the domain cannot be started after deployment. How to undeploy that application without starting the weblogic?
    I use weblogic 10.3.3. His application uses servlet and jsp and tests that application in weblogic 10.3.2

    Delete the application from the deploy directory. The domains/base_domain/autodeploy is the directory for auto deployed applications, which get deployed when server is started. Or, the domain's InstallDir directory.
    Edited by: dvohra16 on Jan 22, 2011 4:43 PM

  • Open application without mouse/trackpad

    Hi guys,
    I always wondered how can you open a file (document, movie, application) without using the mouse to double click it ...
    pressing enter renames the file, and I tried Cmd Enter, Alt Enter, and nothing, is there a special trick for this? Just to avoid going move my hand to the mouse/trackpad.
    I know the preview (Space bar) but I want to really open the document/file in it's default application.
    Thanks

    so easy
    I knew it had to be easy... didn't know witch one

  • Incremental Version releases without redeploying the ear

    We had deployed the ear in oracleAS10g server on windows2000 platform.
    We need to apply the incremental version(patches) changes of jsp/.class files without redeploying the ear file. Where exactly we need to change the files for this to happen, So that we the changes in the files can be viewed. At most we may stop/start server without redeployment of the ear. Plz help usASAP.
    Thanks & regards.
    S. Anand Mohan

    Hi Andreas,
    Thanks for Your help. Could you plz help us in the .class files. What should we do to get the .class files changed without redeploying the ear.
    My mail Id is [email protected]
    with regards,
    S. Anand Mohan

Maybe you are looking for

  • Error in Matl download

    hi, i am getting the following error while downloading a material group from ECC 5.0-> CRM 5.0 : "Category for product hierarchy 1010AV does not exist" i had carried out the download of DNL_CUST_PROD1 and i've  checked this material group is present

  • Connecting Macbook to printer in wireless network

    I recently got a Macbook. I have a pc downstairs that is connected to an HP officejet printer, and one upstairs connected to the same printer via the wireless network. My Macbook uses the same wireless network but I don't know how to find and connect

  • Swing component's margin in a frame

    Hello all, When you set the bounds of a Swing component in a frame, it will automatically apply those bounds to the VISIBLE part of the frame, so that, a Y value of 0, for example, will not be at the very top of the frame, but right underneath the ti

  • Insert statement with loop function

    Hello all, I'm new with the loop function What need to do is to use a select statement with a condition This output needs to be inserted in a table The values of the condition are stored also in a table It will be something like this: BEGIN   FOR i I

  • No play-head during playback on iPhone 4.

    When I'm using the iPod function on my iPhone, to play tunes or podcasts, the playhead is no longer there. This means I can't see how far through the track I am, I can't scrub back and forth, and the 'rewind 30 seconds' function is no more. I recetly