Oc4j startup classes - please help!

I am trying to create a startup class for my Oc4j container. I have created a new class with all the required code. However when I come to update my server.xml config file like so:
<startup-classes>
<startup-class classname="MyStartupClass" failure-is-fatal="true">
<execution-order>0</execution-order>
</startup-class>
</startup-classes>
The container on initialisation says that the class cannot be found. I have also tried giving the fully qualified package name as the class name i.e. com.blah.blahh.MyStartupClass. However still no success.
Anyone know why this is happening and how I can get the container to find my startup class?

make a jar of ur classes and put it in(u can put single class also)
jdev--\j2ee\home\applib
put this line in the server.xml file
<init-library path="../applib" />
try this...
Hope this helps
N@vin

Similar Messages

  • Option key can't function to access start up manager, so i can't choose startup disk. please help me

    option key can't function to access start up manager, so i can't choose startup disk. please help me

    If you have Apple Care, call them and get a case number.  Otherwise, take the computer to an Apple store or an AASP.  Whichever is more convenient for you. 

  • OC4J with MySQL please Help

    i wanna test my work with Ejb 3.0 and i want connect with MySQL
    i tested connection with MySQL database from JDeveloper
    and it successed and i created CMP from MySQL tables
    But the problem when im trying to deploy it with OC4J
    it throws an exception SQLException ( Invalid Oracle URL )
    if anybody know anything about this problem
    please help me

    thankx for help
    but it didnt work i dont know why
    i tried many way to deploy it but it stell throws exception
    << Invalid Oracle URL specifiedError Code: 17067
    >>
    this is OC4J data-sources.xml file
    <?xml version="1.0" ?>
    <data-sources xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://xmlns.oracle.com/oracleas/schema/data-sources-10_1.xsd" schema-major-version="10" schema-minor-version="1">
    <managed-data-source user="root" password="pagera" connection-pool-name="Example Connection Pool" jndi-name="jdbc/MySQLDS" name="MySQLDS" />
    <connection-pool name="Example Connection Pool">
    <connection-factory factory-class="oracle.jdbc.pool.OracleDataSource" user="root" password="pagera" url="jdbc:mysql://localhost/test" />
    </connection-pool>
    </data-sources>
    and i tried it
    <data-source class="com.mysql.jdbc.jdbc2.optional.MysqlDataSource"
    name="mysqlDS" location="jdbc/mysqlCoreDS" xa-location="jdbc/xa/mysqlXADS"
    ejb-location="jdbc/mysqlDS" connection-driver="com.mysql.jdbc.Driver"
    username="root"
    password="pagera"
    url="jdbc:mysql://localhost/test"
    inactivity-timeout="30" />
    but it didnt work too
    i dont know what to do.....
    if anyone has another way pls tell me

  • Error in creating a process using runtime class - please help

    Hi,
    I am experimenting with the following piece of code. I tried to run it in one windows machine and it works fine. But i tried to run it in a different windows machine i get error in creating a process. The error is attached below the code. I don't understand why i couldn't create a process with the 'exec' command in the second machine. Can anyone please help?
    CODE:
    import java.io.*;
    class test{
    public static void main(String[] args){
    try{
    Runtime r = Runtime.getRuntime();
         Process p = null;
         p= r.exec("dir");
         BufferedReader br = new BufferedReader(new InputStreamReader(p.getInputStream()));
         System.out.println(br.readLine());
    catch(Exception e){e.printStackTrace();}
    ERROR (when run in the dos prompt):
    java.io.IOException: CreateProcess: dir error=2
    at java.lang.Win32Process.create(Native Method)
    at java.lang.Win32Process.<init>(Win32Process.java:63)
    at java.lang.Runtime.execInternal(Native Method)
    at java.lang.Runtime.exec(Runtime.java:550)
    at java.lang.Runtime.exec(Runtime.java:416)
    at java.lang.Runtime.exec(Runtime.java:358)
    at java.lang.Runtime.exec(Runtime.java:322)
    at test.main(test.java:16)
    thanks,
    Divya

    As much as I understand from the readings in the forums, Runtime.exec can only run commands that are in files, not native commands.
    Hmm how do I explain that again?
    Here:
    Assuming a command is an executable program
    Under the Windows operating system, many new programmers stumble upon Runtime.exec() when trying to use it for nonexecutable commands like dir and copy. Subsequently, they run into Runtime.exec()'s third pitfall. Listing 4.4 demonstrates exactly that:
    Listing 4.4 BadExecWinDir.java
    import java.util.*;
    import java.io.*;
    public class BadExecWinDir
    public static void main(String args[])
    try
    Runtime rt = Runtime.getRuntime();
    Process proc = rt.exec("dir");
    InputStream stdin = proc.getInputStream();
    InputStreamReader isr = new InputStreamReader(stdin);
    BufferedReader br = new BufferedReader(isr);
    String line = null;
    System.out.println("<OUTPUT>");
    while ( (line = br.readLine()) != null)
    System.out.println(line);
    System.out.println("</OUTPUT>");
    int exitVal = proc.waitFor();
    System.out.println("Process exitValue: " + exitVal);
    } catch (Throwable t)
    t.printStackTrace();
    A run of BadExecWinDir produces:
    E:\classes\com\javaworld\jpitfalls\article2>java BadExecWinDir
    java.io.IOException: CreateProcess: dir error=2
    at java.lang.Win32Process.create(Native Method)
    at java.lang.Win32Process.<init>(Unknown Source)
    at java.lang.Runtime.execInternal(Native Method)
    at java.lang.Runtime.exec(Unknown Source)
    at java.lang.Runtime.exec(Unknown Source)
    at java.lang.Runtime.exec(Unknown Source)
    at java.lang.Runtime.exec(Unknown Source)
    at BadExecWinDir.main(BadExecWinDir.java:12)
    As stated earlier, the error value of 2 means "file not found," which, in this case, means that the executable named dir.exe could not be found. That's because the directory command is part of the Windows command interpreter and not a separate executable. To run the Windows command interpreter, execute either command.com or cmd.exe, depending on the Windows operating system you use. Listing 4.5 runs a copy of the Windows command interpreter and then executes the user-supplied command (e.g., dir).
    Taken from:
    http://www.javaworld.com/javaworld/jw-12-2000/jw-1229-traps.html

  • B575: Microsoft Visual C++ Runtime Library Error on Startup? Please Help!

    This came out of the blue, I just started up my laptop and out of no where my Windows 7 Ultimate transperancy graphics are gone and I can't connect to the internet! I get this message on startup saying 'Microsoft Visual C++ Runtime Library Error', for controlhandler.cpp and I have no clue what it is! I tried a clean boot and safemode boot, and it is the same thing! Please help
    Solved!
    Go to Solution.

    hi ironmax,
    As a last resort, you can:
    1. Press the One Key Recovery button to restore the unit from factory settings or
    2. Create a recovery disc and use this disc to restore the system from factory
    Note:
    Backup important before doing a factory reset
    Regards,
    neokenchi
    Did someone help you today? Press the star on the left to thank them with a Kudo!
    If you find a post helpful and it answers your question, please mark it as an "Accepted Solution"! This will help the rest of the Community with similar issues identify the verified solution and benefit from it.
    Follow @LenovoForums on Twitter!

  • Itouch stuck on startup screen-please help!

    My itouch has been stuck on the startup screen since last night; first I tried letting it charge, and after 30 minutes with no results I unplugged it, let the battery drain completely and started again. After another hour of charging with no results I tried restarting it, again with no results-upon restarting it returned to being stuck on the startup screen. This morning I tried letting it drain again and it became extremely hot until it turned off again. A while ago I plugged it into my computer, hoping to reset and restore it, but it is now, once again, stuck on the startup screen. It's not even being recognized by iTunes or my computer. My ipod is NOT jailbroken btw. Please help!! I don't think I can go on much longer without my music lol

    What do you mean by startup screen?
    Try here:
    iOS: Not responding or does not turn on
    An appointment at the Genius Bar of an Apple store is likely in order since the hotness tends to indicate as hardware problem.

  • NewInstance from variable class(Please Help)

    I want to generate an object from xml
    example :
    <com.toto.titi.variable>
         <name>tata</name>
         <age>20</age>
    </com.toto.titi.variable>
    my java code :
    str = "com.toto.titi.variable" ;
    int idx0 = str.lastIndexOf(".");
    String testObj = str.substring(idx0+1);
    Class cls = Class.forName(str);
    o_ = (testObj)cls.newInstance(); //testObj it's variable, i dont now origin class or Interface
    this code is not work
    Please help
    Thanks

    do a search on here for "beanbox"....that shows how to do object persistence and creation using xml.

  • JWindow class please help me

    sir<br>
    i design a splash window by the use of JWindow class
    i use the following constructor
    public class splash extends JWindow
    //get content pane and set by the setContentPane method
    and add the three panels in it.
    One JPanel have a JTextField
    but JTextField is not accept the input or focus
    means i try to write text in it but it not work
    the code as follows
    //Create Jwindow
    import javax.swing.*;
    import java.awt.*;
    public class SplashScreen extends JWindow
    public static void main(String args[])
    new SplashScreen().setVisible(true);
    //define Variables
    Toolkit tk=Toolkit.getDefaultToolkit();
    Container cp=getContentPane();
    SplashScreenPanel1 p1;
    SplashScreenPanel2 p2;
    SplashScreenPanel3 p3;
    SplashScreen()
    Dimension d=tk.getScreenSize();
    p1=new SplashScreenPanel1(d.getWidth(),d.getHeight());
    p2=new SplashScreenPanel2(d.getWidth(),d.getHeight());
    p3=new SplashScreenPanel3(d.getWidth(),d.getHeight());
    this.setSize(d);
    this.setContentPane(cp);
    this.getContentPane().setLayout(null);
    cp.setBackground(new Color(47,168,122));
    p1.setBounds(new Rectangle(0,(int)(d.getHeight()-100),(int)d.getWidth(),100));
    p2.setBounds(new Rectangle(0,0,(int)d.getWidth(),100));
    p3.setBounds(new Rectangle(0,100,(int)(d.getWidth()),400));
    this.getContentPane().add(p1);
    this.getContentPane().add(p2);
    this.getContentPane().add(p3);
    p1.b1.requestFocus();
    }//end of spalshscreen
    create JPanel
    public class spashscreenpanel3 extends JPanel
    JTextField t=new JTextField();
    splashscreenpanel3
    this.setSize(200,100);
    this.setLayout(null);
    t.setBounds(10,20,100,20);
    this.add(t);
    }//end of JPanel
    Please help me i am very thankful to u

    Some helpful information is here:
    http://java.sun.com/docs/books/tutorial/uiswing/misc/focus.html
    import javax.swing.*;
    import java.awt.*;
    public class hamad extends JFrame
      public static void main(String args[]) 
        new hamad();
      //define Variables
      SplashScreenPanel1 p1;
      SplashScreenPanel2 p2;
      SplashScreenPanel3 p3;
      JWindow window;
      public hamad()
        createWindow(this);
        setDefaultCloseOperation(EXIT_ON_CLOSE);
        setSize(300,200);
        setLocation(500,300);
        setVisible(true);
      private void createWindow(JFrame frameReference) {
        window = new JWindow(frameReference);
        Toolkit tk = Toolkit.getDefaultToolkit();
        Dimension d=tk.getScreenSize();
        p1=new SplashScreenPanel1();
        p2=new SplashScreenPanel2();
        p3=new SplashScreenPanel3();
        window.getContentPane().add(p1, "North");
        window.getContentPane().add(p2, "Center");
        window.getContentPane().add(p3, "South");
        window.setSize(d.width/4, d.width/4);
        window.setLocation(100,100);
        window.setVisible(true);
      private class SplashScreenPanel1 extends JPanel
        JTextField field;
        public SplashScreenPanel1()
          setBackground(new Color(200,150,190));
          setPreferredSize(new Dimension(100,50));
          field = new JTextField();
          field.setPreferredSize(new Dimension(100, 20));
          add(field);
      private class SplashScreenPanel2 extends JPanel
        JTextField field;
        public SplashScreenPanel2()
          setBackground(new Color(220,90,180));
          field = new JTextField();
          field.setPreferredSize(new Dimension(75,20));
          add(field);
      //create JPanel
      private class SplashScreenPanel3 extends JPanel
        JTextField t=new JTextField();
        public SplashScreenPanel3()
          setBackground(Color.pink);
          setPreferredSize(new Dimension(100,50));
          setLayout(null);
          t.setBounds(10,20,100,20);
          add(t);
      }//end of JPanel
    }//end of spalshscreen

  • Computer Startup issue, please help!

    My Toshiba Laptop was working fine in the morning, all I did in the morning was check my email. After coming from school, I checked it and it automatically went to the startup repair. After it was done checking, I started it up AGAIN! Happened a million times. I tried f8 options, I tried ALL of them and it didn't work. They just also went to the startup repair again. Safe mode doesn't work. The repair option, only Startup repair is available, the memory diagnose etc doesn't shop up. I have no money to let someone help, please help!!!!

    What happens when you select Safe Mode?
    - Peter

  • HT1386 Trying to Sync - Unable to load data class - please help

    I just cleared my I-Pod Touch to put new music on it and my computer is prompting the following. "I-Tunes was unable to load data class information from sync sevices." Reconnect of try again later. Another prompt that keeps appearing is  "the application apple mobile device help quit unexpectedly." Please help me...

    Apple Mobile Device Restart. Disable all security software ex. Firewalls and Antivirus. Follow article http://support.apple.com/kb/TS1567  . The above listed article is correct by lllaass. I resolve it by unchecking the different categories in itunes sync pages... Plug in device, click on name on left side of itunes, Click on different sync pages like summary, info, music, movies, etc. You need to uncheck the main check box to sync content. An example would be unchecking "Sync Music" . You will then need to sync once for each category until you locate the source of your corrupt files or folders. Syncing without it checked removes content from device. Follow this step even if there is nothing on the device. Once you identify if it is picture or music etc. you will need to delete corrupt files or move them somewhere else on the computer so itunes can't find it anymore.

  • What am i doing wrong with this class please help

    What am i doing wrong with this class? I'm trying to create a JFrame with a JTextArea and a ScrollPane so that text can be inserted into the text area. however evertime i run the program i cannot see the textarea but only the scrollpane. please help.
    import java.io.*;
    import java.util.*;
    import java.awt.event.*;
    import java.awt.*;
    import javax.swing.*;
    import javax.swing.event.*;
    public class Instructions extends JFrame{
    public JTextArea textArea;
    private String s;
    private JScrollPane scrollPane;
    public Instructions(){
    super();
    textArea = new JTextArea();
    s = "Select a station and then\nadd\n";
    textArea.append(s);
    textArea.setEditable(true);
    scrollPane = new JScrollPane(textArea, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS);
    this.getContentPane().add(textArea);
    this.getContentPane().add(scrollPane);
    this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    this.setTitle("Instructions");
    this.setSize(400,400);
    this.setVisible(true);
    }//end constructor
    public static void main(String args[]){
    new Instructions();
    }//end class

    I'm just winging this so it might be wrong:
    import java.io.*;
    import java.util.*;
    import java.awt.event.*;
    import java.awt.*;
    import javax.swing.*;
    import javax.swing.event.*;
    public class Instructions extends JFrame{
    public JTextArea textArea;
    private String s;
    private JScrollPane scrollPane;
    public Instructions(){
    super();
    textArea = new JTextArea();
    s = "Select a station and then\nadd\n";
    textArea.append(s);
    textArea.setEditable(true);
    scrollPane = new JScrollPane(textArea, JScrollPane.VERTICAL_SCROLLBAR_ALWAYS, JScrollPane.HORIZONTAL_SCROLLBAR_ALWAYS);
    // Here you already have textArea in scrollPane so no need to put it in
    // content pane, just put scrollPane in ContentPane.
    // think of it as containers within containers
    // when you try to put them both in at ContentPane level it will use
    // it's layout manager to put them in there side by side or something
    // so just leave this out this.getContentPane().add(textArea);
    this.getContentPane().add(scrollPane);
    this.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
    this.setTitle("Instructions");
    this.setSize(400,400);
    this.setVisible(true);
    }//end constructor
    public static void main(String args[]){
    new Instructions();
    }//end class

  • Oc4j startup classes

    I am trying to create a startup class for my Oc4j container. I have created a new class with all the required code. However when I come to update my server.xml config file like so:
    <startup-classes>
    <startup-class classname="MyStartupClass" failure-is-fatal="true">
    <execution-order>0</execution-order>
    </startup-class>
    </startup-classes>
    The container on initialisation says that the class cannot be found. I have also tried giving the fully qualified package name as the class name i.e. com.blah.blahh.MyStartupClass. However still no success.
    I have placed the startup class in the .jar file in the .ear file which I have deployed to the /application dir.
    Anyone know why this is happening and how I can get the container to find my startup class?

    My container starts fine now with the startup class in place.
    The startup class simply makes some calls to a third party job scheduling library.
    However, when I try to invoke a job, I get the following error:
    core.JobRunShell - Job Manual.Job1 threw a JobExecutionException:
    org.quartz.JobExecutionException: javax.naming.NamingException: Not in an application scope - start Orion with the -userThreads switch if using user-created thread
    However when i start the OC4J container up, I do include this flag.
    i.e. java -jar oc4j.jar -userThreads
    Anyone have any idea what is going on?

  • Accessing a thread from a main class, please help!

    Hi, I have a thread, T1, that I need to access from my main class. I cannot use runnable, it's got to be done with extands thread. I can start it alright, but I cannot stop it;
    MAIN CLASS
    public class Uppgift1 {
    public static void main(String args[]) throws InterruptedException {
    // Start Thread 1
         Thread trad1 = new T1( );
         trad1.start( );
         //Wait for 5 seconds
         Thread.sleep(5000);
         //Stop the Thread
         trad1.stopIt();
    public class T1 extends Thread {
         boolean go = true;
    public void run ( ) {
    while(go){
         System.out.println("T1: Trad 1");
    try{
    Thread.sleep(1000);
    } catch( InterruptedException e ) {
    public void stopIt(){
    go = false;
    Why can't I run stopIt from my main class?
    Please help me.

    manswide wrote:
    The reason I have to use Thread is that it's for a school thing; I guess I gotta learn to do it the bad way in order to learn why to love the good way later on.Good plan. Making mistakes is a fantastic learning tool
    How do I declare a reference to my own class?
    T1 t1 = new T1();

  • MacBook Pro won't Startup! Please Help!!

    I installed 2 softwares this morning, "USB Screen Lock" and " Logonkey". Both allow u to unlock your mac with a usb drive. After installing USB screen lock i tested it out, put my computer to sleep and then came back a few hours later to test out Logonkey. After downloading the free version on their website and installing it, it requierd a restart. When my mac was turning on, it got stuck after showing the Apple logo. All i see is a gray screen with a spinning circle that comes and goes after a couple of seconds. This same thing keeps repeating for hours. I dont know if it's related to one of the softwares or not. I tried to Safe Boot it but it didnt make any difference. Also reseted the NVRAM/PRAM thingy but it didnt make any difference either.
    Please help!! :(

    You need to reinstall Lion. If that doesn't help, then there's a deeper problem that could or could not be related to the software you installed.
    Reinstalling Lion/Mountain Lion Without Erasing the Drive
    Boot to the Recovery HD: Restart the computer and after the chime press and hold down the COMMAND and R keys until the menu screen appears. Alternatively, restart the computer and after the chime press and hold down the OPTION key until the boot manager screen appears. Select the Recovery HD and click on the downward pointing arrow button.
    Repair the Hard Drive and Permissions: Upon startup select Disk Utility from the main menu. Repair the Hard Drive and Permissions as follows.
    When the recovery menu appears select Disk Utility. After DU loads select your hard drive entry (mfgr.'s ID and drive size) from the the left side list.  In the DU status area you will see an entry for the S.M.A.R.T. status of the hard drive.  If it does not say "Verified" then the hard drive is failing or failed. (SMART status is not reported on external Firewire or USB drives.) If the drive is "Verified" then select your OS X volume from the list on the left (sub-entry below the drive entry,) click on the First Aid tab, then click on the Repair Disk button. If DU reports any errors that have been fixed, then re-run Repair Disk until no errors are reported. If no errors are reported click on the Repair Permissions button. Wait until the operation completes, then quit DU and return to the main menu.
    Reinstall Lion/Mountain Lion: Select Reinstall Lion/Mountain Lion and click on the Continue button.
    Note: You will need an active Internet connection. I suggest using Ethernet if possible because it is three times faster than wireless.

  • Premiere CS4 freezing on startup menu, please help.

    Hi,
    I installed Adobe Premiere CS4 not too long ago as part of Master Collection and all the other programs seem to work but Premiere doesn't.
    Whenever I open Premiere CS4, the splash screen loads up and then I get that menu with New Project and Open Project buttons. That's when it freezes. The buttons don't work and whenever I click on them the menu flickers slightly and nothing happens. I tried closing some Adobe processes like acrotray and Import Process but that didn't help.Has this got something to do with Quicktime or something else? Please help, I need Premiere CS4 to work on my college assignments.

    I solved the problem!:)
    I actually found it through the panel on the right for similar problems.
    Apparently WindowBlinds 6 was the cause of the probelm and there was an option in it that I had to change.
    Now Premiere works.

Maybe you are looking for

  • Acrobat XI Pro "Not Responding

    I recently updated to Windows 8 Professional and Acrobat worked like a charm for 3 days with instantaneous reponse. Now progressively I am back to the old problem that I had under Windows 7 and with Acrobat X and 9 - Whenever I open a new PDF it take

  • 160G iPod classic Will NOT restore

    160G iPod classic Will NOT restore Timeline: 1. iPod freezes 2. restart 3. everything gone from device_ creating appearance of factory settings having been restored. 4. plug into computer. 5. computer says it cannot recognize iPod because formatless

  • Binary File Read

    Hello everyone, I am not that comfortable with binary file reading. I am trying to learn. I have a vi which logs a sine wave in a binary file. The Read vi which I have written is not giving the expected data. Thanks in advance cooldude  Attachments:

  • DYNAMIC SELECTIONS IN SELECTION SCREEN

    I DONNO ANYTHING ABT DYNAMIC SELECTIONS. CUD U PLZ TELL ME HOW TO GIVE DYNAMIC SELECTIONS FOR ANY FIELD?

  • Why am I seeing italicized words in a pdf file in bold type?

    In my iPad2 why do I see italicized words in a pdf file in bold type?