Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Oc4j startup classes  RSS feed

 
Ryan Acc
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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?
 
Valentin Tanase
Ranch Hand
Posts: 704
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Ryan,

I�m not much of an Oc4j expert (actually I know nothing about it :-) but it occurs to me like you have a classpath issue. Employing my WebLogic knowledge I can only say that you probably need to add this class to the system classpath. That�s it, pack it as a jar and go through server�s startup scripts and figure out how the classpath is initialized. Finally you need to modify the script and add your library as well.
Regards.
 
Larry O Anderson
Greenhorn
Posts: 3
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If your class is contained in a jar, a simple tag like

<init-library path="../applib/yourjar.jar" />

should suffice to help your app server instance know about the class.

See this link
http://download-east.oracle.com/docs/cd/B25221_03/web.1013/b14433/startclas.htm
[ March 16, 2006: Message edited by: Larry O Anderson ]
 
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!