MyEclipse: [Workaround] Deploying to oc4j 10g (10.1.2.0.)

bradm - Jul 27, 2005 - 08:51 PM
Post subject: [Workaround] Deploying to oc4j 10g (10.1.2.0.)
I pointed my eclipse to the j2ee/home directory in the oc4j directory; hooked up a jdk, and successfully started the server from within My Eclipse (this is the pure Java J2EE Containers version). I also deployed an application to the server, and My Eclipse reports that it was successful. The app doesn't really get deployed though, it seems: I see no evidence of it on the server, and a "Not Found" error results if I try to browse to it.

Is it too early for 10g (i.e. is 9i the only one supported)?

I'm on Eclipse 3.1RC4, and MyEclipse 4M2.
bradm - Jul 28, 2005 - 12:28 AM
Post subject:
I forgot to mention that I also tried the suggestions in the oc4j "Sticky" re: the server.xml and http-app.xml file adjustments, and that I tried deploying both an exploded app and a WAR.
support-scott - Jul 28, 2005 - 03:00 AM
Post subject:
OC4J is a strange beast. Exploded applications don't work at all. I *think* a war works and I'm sure an EAR works. Can you try creating an EAR project, adding your WAR to it (in the wizard) and deploying that as a packaged archive? That should work fine, provided you've set up the autodeploy directory in server.xml correctly.
Necron99 - Jul 28, 2005 - 03:22 PM
Post subject:
This thread might be of help to you:

http://www.myeclipseide.com/index.php?name=PNphpBB2&file=viewtopic&p=34647&highlight=#34647

Dave
bradm - Jul 29, 2005 - 02:50 AM
Post subject:
Thank you Dave. I had looked at that thread and tried what was suggested there with no luck.

I work for a university that has just committed to oc4j (or rather a department that has... but I digress....).

If anybody is looking at this who can share some battle scars please speak up! Thanks in advance.
support-scott - Jul 29, 2005 - 03:36 PM
Post subject:
Brad,

Did deploying a packaged EAR work?
bradm - Aug 02, 2005 - 12:05 AM
Post subject:
Scott,

Sorry to admit it, but I can't see how to take this project (which I initiated with Web Project abilities) and export it as an EAR file. I tried to export what I have, but I get a message saying that suggests I need to START a project with EAR capabilities first (" No EAR projects Found for Export. This wizard displays only those EAR projects that are currently OPEN."

What am I missing?
support-scott - Aug 02, 2005 - 02:13 AM
Post subject:
Brad,

You need to create an addition project using File > New > Project... > MyEclipse > J2EE Projects > Enterprise Application Project.
In the first page of the wizard under Creation Tasks > Available Tasks, uncheck the create ejb project settings. Click next and then select your web project in the bottom section of the next page under "Select Applicable Web Module Projects". Let the wizard finush running and then deploy this new EAR project (as packaged) to Oracle and you'll have a .ear file that properly includes you're web project's .war file.
bradm - Aug 02, 2005 - 11:15 AM
Post subject:
Hi Scott. All went just as you describe above, and again I'm told that deployment was successful. But again when I try to load a page from it in a browser oc4j tells me it "can't be found" (404).

For what it's worth this same app is loaded up just fine on Tomcat. How could Oracle have managed to make something so basic to the notion of a web server so impossibly complex and cryptic?
support-rkalla - Aug 02, 2005 - 03:07 PM
Post subject:
Brad,
I know that typically J2EE application servers require that you additionally "install" or "deploy" the EAR from within the server's administrative console, and MyEclipse's step of "deploying" it isn't the end of the road. So I looked up deploying an app into OC4J and found this link for 9, check the last section here: http://www.oracle.com/technology/sample_code/tech/xml/customermanagement/Install.html

It looks like you need to edit some config files to let the app server become aware of the installed app. I can't imagine that OC4J dosen't include an administrative console much like WebSphere has that you can "Install" the EAR from, does it?
kinjalsonpal - Aug 03, 2005 - 06:29 AM
Post subject:
After good amount of research on OC4J deployment, I've managed to achieve true hot deployment (for both, the web content and java content). Following is a step by step procedure. I've tested this on MEI 3.8.4 with OC4J 9.0.4 and 10.1.3. The standalone OC4J installation in both the cases was a fresh install on a Windows XP (SP1) m/c. Go through and follow contents of the ReadMe in the downloaded OC4J archive. Configure OC4J in MEI as described in the tutorial.

1) modify server.xml to achive following effect.

<application-server application-directory="../applications"
deployment-directory="../application-deployments"
connector-directory="../connectors"
application-auto-deploy-directory="../application-autodeploy"
check-for-updates="true"
>

2) Create a directory called application-autodeploy under $OC4J_HOME\j2ee\home.

3) Start OC4J using the server launcher. Create a J2EE Enterprise Application Project and a subproject (typically a webproject), if you already do not have one. OC4J recognises only .ear files for auto-deploy.

4) Click on the Deploy button to bring up deployment dialog. Choose the Enterprise Application's project from the selection box, Click Add button, choose Oracle 9i/AS as target server, choose Packaged Archive and click Deploy.

5) Once the deployment is successful, on the OC4J console, there would be good number of informational messages regarding the deployment process. Test your newly deployed application. Now, shutdown OC4J.

6) While the server is down, again go to deployment dialog, choose the same project in the list of deployments below the project selection box. Click on Remove. Now repeat deployment with only one exception. Instead of choosing Packaged Deployment, choose Exploded Deployment option.

7) Start OC4J as usual, now it'll have a fully hot deployable application.

I've observed that sometimes, changes are not HotSynched. This typically happens if MEI is restarted. If this happens, just do Exploded Deployment again. Btw, if you guys have a choice, use version 10.1.x. It comes with a pretty comprehensive admin console running on port 1810.

I'm sure the MEI team will be able to refine this further and correct it if required.

HTH.

Regards,
Kinjal
bradm - Aug 03, 2005 - 12:22 PM
Post subject:
Thank you very much for your detailed instructions Kinjal. I'm sorry to report that following them to the letter still leads to the same problem: "Page Not Found".

I'm going to just lobby this department against using oc4j! This one takes the cake.
kinjalsonpal - Aug 03, 2005 - 01:46 PM
Post subject:
bradm wrote:
Thank you very much for your detailed instructions Kinjal. I'm sorry to report that following them to the letter still leads to the same problem: "Page Not Found".


There're good number of reasons why you would receive "Page Not Found" error. It ranges from a typo in the address bar of your browser to misconfiguration of the application server. Is the same application working on some other application server, like, say Tomcat which only deals with a .war file? Also, were you able to follow all the above steps successfully?

Quote:
I'm going to just lobby this department against using oc4j! This one takes the cake.
Lobbying against a product just because it's a tough cookie does not look to be a good thing to do IMHO. Sometimes people do not have such a luxury of liking or disliking a product, they're just asked to make it work.

My 2 cents.

Regards,
Kinjal
bradm - Aug 03, 2005 - 10:27 PM
Post subject:
Yes, all the steps you outlined appeared to be successful; and yes: the same app has been deployed as a WAR file and in exploded form on two different servers using Tomcat.

I'm curious: is there anything about oc4j that other options don't provide that would explain it's comparative complexity and fussiness?
support-scott - Aug 04, 2005 - 12:26 AM
Post subject:
One thing we haven't covered is what port you're trying to access to see the server. See (http://www.johntopley.com/kb/oracle/0025.html) which shows the default port is 8888. So, try http://localhost:8888/...
bradm - Aug 06, 2005 - 03:09 AM
Post subject:
I did change the port (because I use 8888 for Tomcat), but since the default page for oc4j comes up fine when I browse to localhost:9999 I'm confident that something else is wrong.
ctrapani - Aug 10, 2005 - 10:29 PM
Post subject:
Hi all,

For what it's worth, I also have struggled with deploying to OC4J standalone 10.1.2, but stumbled on success just now. There are two additional things beyond what is documented in this thread that I did to my OC4J installation to make things work on my Win2K machine:

1) Certain OC4J config files in [OC4J_INSTALL]\j2ee\home\config\ were Read Only!! I took that attribute off all my config files.

2) After multiple failed attempts to deploy where console indicated success but I got 404 not found in browser, I resorted to running Oracle's admin.jar utility to deploy the EAR and then bind it to the http-web-site (default) web site. Here is a sample of those commands:

From the [OC4J_INSTALL]\j2ee\home directory

java -jar admin.jar ormi://localhost:23791 admin [your_admin_pass] -deploy -file [ear_file_name.ear] -deployName [appName]

java -jar admin.jar ormi://localhost:23791 admin [your_admin_pass] -bindWebApp [appName] [WARfileNameWithoutTheWar] http-web-site [contextWithoutTheLeadingSlash]

That worked, so I undeployed the app using the admin.jar (which also unbound the app from the web site).:

java -jar admin.jar ormi://localhost:23791 admin [your_admin_pass] -undeploy [appName]

Then ... magic, the MyEclipse deployment works like a charm. I'm not really sure what the deal is. I feel a bit like a plumber with plunger, but I'm used to that working with Oracle App server. Of course, Tomcat worked fine first time. I bet other app servers work first time too.

I'm very happy with MyEclipse so far and can't say enough good about the great documentation and features that I've found so far, especially compared with Eclipse WTP (still too churning for me). Keep up the great work folks!!

Carl
support-rkalla - Aug 11, 2005 - 07:16 AM
Post subject:
Carl,
We really appreciate you posting these details for other users, these forums are truely a boom for anyone trying to work with J2EE development, not just using MyEclipse.
developerwiz - Aug 15, 2005 - 08:09 PM
Post subject:
support-scott wrote:
One thing we haven't covered is what port you're trying to access to see the server. See (http://www.johntopley.com/kb/oracle/0025.html) which shows the default port is 8888. So, try http://localhost:8888/...
Hello:
I am trying to repeat the process.
While deployng the EAR file I am getting the following in the OC4J console:
05/08/15 15:07:01 Oracle Application Server Containers for J2EE 10g (9.0.4.0.0) initialized
05/08/15 15:07:26 Auto-unpacking D:\tools\OracleAS\oc4j_extended\j2ee\home\application-autodeploy\HelloWorldEAR.ear... 05/08/15 15:07:27 Error installing applications: Unknown assembly root-tag attribute: xmlns
done.

05/08/15 15:07:31 Error installing applications: Unknown assembly root-tag attribute: xmlns

Any ideas?
THanks
developerwiz - Aug 15, 2005 - 08:15 PM
Post subject:
developerwiz wrote:
support-scott wrote:
One thing we haven't covered is what port you're trying to access to see the server. See (http://www.johntopley.com/kb/oracle/0025.html) which shows the default port is 8888. So, try http://localhost:8888/...
Hello:
I am trying to repeat the process.
While deployng the EAR file I am getting the following in the OC4J console:
05/08/15 15:07:01 Oracle Application Server Containers for J2EE 10g (9.0.4.0.0) initialized
05/08/15 15:07:26 Auto-unpacking D:\tools\OracleAS\oc4j_extended\j2ee\home\application-autodeploy\HelloWorldEAR.ear... 05/08/15 15:07:27 Error installing applications: Unknown assembly root-tag attribute: xmlns
done.

05/08/15 15:07:31 Error installing applications: Unknown assembly root-tag attribute: xmlns

Any ideas?
THanks
Never mind, silly me - had wrong J2EE level...
bgblanch - Sep 13, 2005 - 05:14 PM
Post subject: Deploying to OC4J and Oracle Portal
I am writing this to hopefully help out some people trying to use Eclipse/MyEclipse with Oracle Portal. I spent about a day gathering information and playing around with the .xml files trying to get it to work. After requesting help from MyEclipse Support (thank you Scott), I was able to get it up and running. So, to save you some time, here is what you need to do.

First, set up the OC4J server. To do this, go to Window > Preferences. Click the + next to MyEclipse, the the + next to Application Servers. Click on Oracle 9i/AS. Click on the radion button next to Enable (yup, to enable the server). Next to Oracle AS Home Directory, Browse to the j2ee/home directory of your installation (C:\JDev1012\j2ee\home for me), and set the Host:ORMI Port to localhost:23791. Click the + next to Oracle 9i/AS and then on JDK. Make sure that you have added a proper J2SDK (J2SDK1.4.2 for me). Click OK and you're done.

In order to deploy a web application from Eclipse 3.1 and MyEclipse 4.0, you have to use the J2EE 1.3 Specification Level when creating the web application. Once you've got your web app completed, create a new Enterprise Application Project (again using the J2EE 1.3 Specification Level). Uncheck the "Define EJB Project Modules" under Creation Tasks (I found this advice in the forums and it works), click next. Under Web Project Modules, select any applicable Web Module Projects (the web app you created previously), click next, then finish. Make sure that you have the Oracle AS setup correctly. Deploy the web app you created to the OC4J (this will create a .war file). Then deploy the Enterprise Application Project to the OC4J server (this will create the .ear file).

To deploy your .ear file to the Oracle Portal, log into the middle tier and find a suitable OC4J container (I would recommend against the default OC4J as your code will get wiped out when you do any patches). If you don't have any suitable OC4J containers, create one and then click on the name/link. Click on Applications, then the Deploy EAR File button. Browse to your .ear file (mine was in C:\JDev1012\j2ee\home\application-autodeploy), give it a name and then deploy it.

NOTE: You may have to do some other futsing around to get the deployment correct, if this doesn't work for you, explore the rest of the thread as I may have missed a step or you may have something set up different than I did.

Specs:
M$ Windows XP
Eclipse 3.1
MyEclipse 4.0
Oracle JDeveloper 10.1.2
(for the OC4J server - you can also download just the OC4J server from Oracle)
Oracle Portal 10g/Application Server 10.1.2
support-rkalla - Sep 13, 2005 - 05:24 PM
Post subject:
Thank you very much bqblanch for posting and making this thread valuable to everyone that may be running into similar problems.
gooshy1 - Feb 22, 2006 - 04:22 PM
Post subject:
What operating system and version are you running? - Windows XP SP2
What Eclipse version and build id are you using? - Version: 3.1.1
- Was Eclipse freshly installed for MyEclipse? Yes
- Are any other external plugins installed? - No
- How many plugins in the <eclipse>/plugins directory are like org.eclipse.pde.* - 14
What MyEclipse version are you using? - 4.1.0 GA
What JDK version are you using to run Eclipse? - build 1.4.2_08-b03
What JDK version are you using to launch your application server? build 1.4.2_08-b03
What application server are you using? OC4J 10.1.2.0.2
Are there any exceptions in the Eclipse log file? No.

Having followed the instructions on this thread for setting up oc4j I have encountered the following error when accessing the initial page of the app. I get the following error message in the console window:

06/02/22 16:05:10 Oracle Application Server Containers for J2EE 10g (10.1.2.0.2) initialized
06/02/22 16:05:49 Auto-unpacking C:\Servers\10g_extended1012\j2ee\home\application-autodeploy\anpr2.ear... done.
06/02/22 16:05:51 Auto-unpacking C:\Servers\10g_extended1012\j2ee\home\application-autodeploy\anpr2\anpr.war... done.
06/02/22 16:06:13 Auto-deploying anpr2 (Assembly had been updated)...
06/02/22 16:06:13 Auto-deploying anpr (Assembly had been updated)...
06/02/22 16:06:47 Error: null
06/02/22 16:06:47 Errors parsing jar:file:/C:/Servers/10g_extended1012/j2ee/home/application-autodeploy/anpr2/anpr/WEB-INF/lib/standard.jar!/META-INF/fn.tld
06/02/22 16:06:47 Error: null
06/02/22 16:06:47 Errors parsing jar:file:/C:/Servers/10g_extended1012/j2ee/home/application-autodeploy/anpr2/anpr/WEB-INF/lib/standard.jar!/META-INF/permittedTaglibs.tld
06/02/22 16:06:47 Error: null
06/02/22 16:06:47 Errors parsing jar:file:/C:/Servers/10g_extended1012/j2ee/home/application-autodeploy/anpr2/anpr/WEB-INF/lib/standard.jar!/META-INF/scriptfree.tld


The application works fine when deploying from an ant script that I have. I have not seen this error before and I dont think that its a problem with my code.

Any help is appreciated.

Thanks
Scott.
support-rkalla - Feb 22, 2006 - 05:22 PM
Post subject:
Scott, go into the C:/Servers/10g_extended1012/j2ee/home/application-autodeploy/anpr2/anpr/WEB-INF/lib directory and open the standard.jar file with a zip utility like WINZIP, then go into the META-INF directory, do you see fn.tld, permittedTaglibs.tld and scriptfree.tld?
gooshy1 - Feb 23, 2006 - 09:04 AM
Post subject:
support-rkalla wrote:
Scott, go into the C:/Servers/10g_extended1012/j2ee/home/application-autodeploy/anpr2/anpr/WEB-INF/lib directory and open the standard.jar file with a zip utility like WINZIP, then go into the META-INF directory, do you see fn.tld, permittedTaglibs.tld and scriptfree.tld?


Yes they are present.
support-rkalla - Feb 23, 2006 - 01:05 PM
Post subject:
Odd. Try shutting down the app server, removing your deployment, rebuilding your projects then recreating the deployment THEN restarting the server. Same thing?
gooshy1 - Feb 23, 2006 - 01:24 PM
Post subject:
support-rkalla wrote:
Odd. Try shutting down the app server, removing your deployment, rebuilding your projects then recreating the deployment THEN restarting the server. Same thing?


Yes the same thing happened.
support-rkalla - Feb 23, 2006 - 01:55 PM
Post subject:
Would you be able to upgrade to 10.1.3 rc3 here: http://www.oracle.com/technology/tech/java/oc4j/1013/index.html

and see if the problem persists?
gooshy1 - Feb 23, 2006 - 02:22 PM
Post subject:
support-rkalla wrote:
Would you be able to upgrade to 10.1.3 rc3 here: http://www.oracle.com/technology/tech/java/oc4j/1013/index.html

and see if the problem persists?


I'll give it a go and see what happens, however our deployment environment is set in stone at the moment.
jimsong - Apr 10, 2006 - 11:10 PM
Post subject:
I am doing a deploy packaged archive from my Enterprise Application project as suggested. It hangs at creating the war file.

The same web app deploys to Tomcat in seconds with no problem.
support-rkalla - Apr 10, 2006 - 11:49 PM
Post subject:
Jim we are going to need more information from you if you would like help with the problem, you haven't given us anything to trouble shoot yet. Can you please post all the information we request in the Posting Guidelines thread at the top of this forum? That will give us some context so that we can determine if this is an installation issue, a configuration problem, or a bug. Thanks.
mike.ring - Apr 17, 2006 - 08:09 PM
Post subject:
jimsong wrote:
I am doing a deploy packaged archive from my Enterprise Application project as suggested. It hangs at creating the war file.

The same web app deploys to Tomcat in seconds with no problem.

I had a similar problem when I was trying to deploy a very large web app. It would hang at creating the war file and give me a blank error message. I had to increase the memory for eclipse on startup. Check out:
http://www.myeclipseide.com/PNphpBB2+file-viewtopic-t-10087-highlight-increase+heap+memory.html
http://www.myeclipseide.com/PNphpBB2+file-viewtopic-t-97-highlight-increase+heap+memory.html
skshaffer - Apr 19, 2006 - 03:58 PM
Post subject:
gooshy1 wrote:

Having followed the instructions on this thread for setting up oc4j I have encountered the following error when accessing the initial page of the app. I get the following error message in the console window:

06/02/22 16:05:10 Oracle Application Server Containers for J2EE 10g (10.1.2.0.2) initialized
06/02/22 16:05:49 Auto-unpacking C:\Servers\10g_extended1012\j2ee\home\application-autodeploy\anpr2.ear... done.
06/02/22 16:05:51 Auto-unpacking C:\Servers\10g_extended1012\j2ee\home\application-autodeploy\anpr2\anpr.war... done.
06/02/22 16:06:13 Auto-deploying anpr2 (Assembly had been updated)...
06/02/22 16:06:13 Auto-deploying anpr (Assembly had been updated)...
06/02/22 16:06:47 Error: null
06/02/22 16:06:47 Errors parsing jar:file:/C:/Servers/10g_extended1012/j2ee/home/application-autodeploy/anpr2/anpr/WEB-INF/lib/standard.jar!/META-INF/fn.tld
06/02/22 16:06:47 Error: null
06/02/22 16:06:47 Errors parsing jar:file:/C:/Servers/10g_extended1012/j2ee/home/application-autodeploy/anpr2/anpr/WEB-INF/lib/standard.jar!/META-INF/permittedTaglibs.tld
06/02/22 16:06:47 Error: null
06/02/22 16:06:47 Errors parsing jar:file:/C:/Servers/10g_extended1012/j2ee/home/application-autodeploy/anpr2/anpr/WEB-INF/lib/standard.jar!/META-INF/scriptfree.tld
.

What operating system and version are you running? - Windows XP SP2
What Eclipse version and build id are you using? - Version: 3.1.2
- Was Eclipse freshly installed for MyEclipse? Yes
- Are any other external plugins installed? - No
- How many plugins in the <eclipse>/plugins directory are like org.eclipse.pde.* - 8 (i think; 4 directories and 4 jars)
What MyEclipse version are you using? - 4.1.0 GA
What JDK version are you using to run Eclipse? - 1.4.2_10
What JDK version are you using to launch your application server? 1.4.2_10
What application server are you using? OC4J 10.1.2.0.2
Are there any exceptions in the Eclipse log file? No.

Was there a solution to this problem above? I am currently running into the same exact problem. I would move to 10.1.3 because I know it works however for our customer I have to use 10.1.2.0.2. Just wondering if there has been any luck on this.
skshaffer - Apr 19, 2006 - 07:12 PM
Post subject:
Nevermind, I figured it out. I had to replace my standard.jar with the one provided in %ORACLE_HOME%/j2ee/home/jsp/lib/taglib directory. I didnt have any errors after that.
support-rkalla - Apr 19, 2006 - 10:18 PM
Post subject:
Thank you for following up for others.
lqtlyl - Sep 20, 2006 - 09:45 PM
Post subject:
Did bradm or someone else finally figure out this, though this post is kinda old?

I am getting exactly same problem. I am using myeclipse 5.0 and oc4j 10.1.3.
I tried everything here and none of them works. But if I move my project folder (for instance myWeb) from application-autodeploy folder to default-web-app folder, then everything works fine of course.

Any idea?
support-rkalla - Sep 21, 2006 - 12:19 AM
Post subject:
lqtlyl,
If it's just the deployment location, you can use a custom location deployment instead of one specifically to the server and that will work around the issue I believe.
dshitzu1 - Nov 15, 2006 - 10:59 PM
Post subject: Deploy to OC4J 10.1.2 from MyEclipse 5.0.1?
I'm trying to create and deploy an .ear file to OC4J 10.1.2 from within MyEclipse 5.0.1. I can do this successfully when I deploy to OC4J 10.1.3 unfortunately there is no option that I can see to select OC4J 10.1.2 as a target server in MyEclipse so I've deployed to
v. 10.1.3 and then moved everything over to v.10.1.2 (time consuming but educational....)

When I startup v.10.1.2 after deploying the app I get the following error message:
"Error instantiating application at file <application path.ear>: Unknown assembly root-tag attribute: version" . I assume this a J2EE versioning issue but don't know how to correct it.

I don't have a build.xml file for this app and don't want to have to create one - I like running everything from within MyEclipse but it looks like this is a deal-breaker.
Anyone have any ideas. Our company won't upgrade to OC4J 10.1.3 at this time, so that's not an option.

Thanks!
support-rkalla - Nov 15, 2006 - 11:01 PM
Post subject:
Quote:

I'm trying to create and deploy an .ear file to OC4J 10.1.2 from within MyEclipse 5.0.1. I can do this successfully when I deploy to OC4J 10.1.3 unfortunately there is no option that I can see to select OC4J 10.1.2 as a target server in MyEclipse so I've deployed to
v. 10.1.3 and then moved everything over to v.10.1.2 (time consuming but educational....)

MyEclipse does not make any specific requirements for app server version for deployments... are you sure you aren't using WTP and not MyEclipse?

For example, did your deployment steps look similar to the ones outlined in our App Server guide here?
http://myeclipseide.com/enterpriseworkbench/help/index.jsp?topic=/com.genuitec.myeclipse.doc/html/quickstarts/webprojects/index.html
(Click on Section 7.1 to start for screenshots)
yuvrajw - Mar 24, 2007 - 08:33 AM
Post subject: Does not work with EJBs in oc4j 10.1.3
kinjalsonpal wrote:
After good amount of research on OC4J deployment, I've managed to achieve true hot deployment (for both, the web content and java content). Following is a step by step procedure. I've tested this on MEI 3.8.4 with OC4J 9.0.4 and 10.1.3. The standalone OC4J installation in both the cases was a fresh install on a Windows XP (SP1) m/c. Go through and follow contents of the ReadMe in the downloaded OC4J archive. Configure OC4J in MEI as described in the tutorial.

1) modify server.xml to achive following effect.

<application-server application-directory="../applications"
deployment-directory="../application-deployments"
connector-directory="../connectors"
application-auto-deploy-directory="../application-autodeploy"
check-for-updates="true"
>

2) Create a directory called application-autodeploy under $OC4J_HOME\j2ee\home.

3) Start OC4J using the server launcher. Create a J2EE Enterprise Application Project and a subproject (typically a webproject), if you already do not have one. OC4J recognises only .ear files for auto-deploy.

4) Click on the Deploy button to bring up deployment dialog. Choose the Enterprise Application's project from the selection box, Click Add button, choose Oracle 9i/AS as target server, choose Packaged Archive and click Deploy.

5) Once the deployment is successful, on the OC4J console, there would be good number of informational messages regarding the deployment process. Test your newly deployed application. Now, shutdown OC4J.

6) While the server is down, again go to deployment dialog, choose the same project in the list of deployments below the project selection box. Click on Remove. Now repeat deployment with only one exception. Instead of choosing Packaged Deployment, choose Exploded Deployment option.

7) Start OC4J as usual, now it'll have a fully hot deployable application.

I've observed that sometimes, changes are not HotSynched. This typically happens if MEI is restarted. If this happens, just do Exploded Deployment again. Btw, if you guys have a choice, use version 10.1.x. It comes with a pretty comprehensive admin console running on port 1810.

I'm sure the MEI team will be able to refine this further and correct it if required.

HTH.

Regards,
Kinjal


Thanks Kinjal for providing this workaround. Unfortunately, after exploded archive deployment, Oc4j 10.1.3 does not seem to be finding any EJBs. I keep getting the following error (WARNING) on deploying the exploded archive:
WARNING J2EE EJB-03001 EJB module contains no beans.

On running the app, I get NameNotFoundException for the EJBs. The same thing works well with packaged archive deployment. Any Ideas ?
tgullo - Apr 30, 2007 - 10:01 PM
Post subject:
Kinjal,
Thanks. It worked for me.
All times are GMT - 6 Hours
Powered by PNphpBB2 © 2003-2004 The PNphpBB Group
Credits