Java EE SDK Runs ADF Faces
The saga of Oracle ADF Faces on the Java EE SDK continues. In our
last installment,
href="http://sfjsf.blogspot.com/2006/02/adf-faces-and-jsf-12.html">Adam
Winer explained why ADF Faces won't run on Glassfish. I'm happy to
report that after some minor tweaks to Sun's JSF implementation in the
Java EE SDK, I think I have it running. However, I would appreciate any
testing people could give to see if the entirety of ADF Faces works.
ADF Faces is a large piece of software and their demo app is rather
comprehensive. Incidentally, it's also a great testcase for extending
JSF and exposed a few bugs which have also been fixed.
Here's how to try it. I'm using the jsf-glasssfish-updater technique
described in
href="http://weblogs.java.net/blog/edburns/archive/2006/01/glassfish_jsf_1.html">an
earlier blog.
-
href="http://java.sun.com/javaee/5/downloads/">Download and
install the Java EE 5 SDK. If you already have JDK 5.0
installed, you can just download
. Currently there is noSun Java System
Application Server PE 9 Beta
Mac OS X build of the Java EE SDK, but don't despair! Mac
Users will have to use href="https://glassfish.dev.java.net/public/downloadsindex.html">Glassfish,
the Open Source Application Server from which the Java EE SDK
is built. Mac OS X is my main development platform, so I know
it works there. -
Go to the href="https://javaserverfaces.dev.java.net/servlets/ProjectDocumentList?folderID=1703">the
nightly download area. If you're running the Java EE SDK
Preview, download the
jsf-sjsas9pebeta-updater.jar. If you're running
Glassfish, downloadjsf-glassfish-updater.jar -
Execute this with the JDK 5 Java interpreter.
java -jar jsf-<glassfish-or-sjsas9pebeta>-updater.jar <PATH_TO_YOUR_ASINSTALL_DIRECTORY>Where
<glassfish-or-sjsas9pebeta>sjsas9pebeta or
glassfish, andPATH_TO_YOUR_AS_INSTALL_DIRECTORYis the
parent of thelib,bin,domains
(and so on) directories. -
Download Oracle ADF Faces from href="http://www.oracle.com/technology/products/jdev/htdocs/partners/addins/exchange/jsf/">Oracle's
website. Note, you have to join their developer network
to get it. -
Unfortunately, ADF Faces appears to have been developed
without taking advantage of the benefits of the robust href="http://java.sun.com/javaee/5/docs/api/javax/security/jacc/package-summary.html">SecurityManager in Java EE 5.
Therefore, you'll have to put the following entry in your
server.policyfile if you want the
chooseDatecomponent to work from the
adf-faces-demo.war.grant codeBase "file:${com.sun.aas.installRoot}/domains/domain1/applications/j2ee-modules/adf-faces-demo/WEB-INF/lib/adf-faces-api-SNAPSHOT.jar" {
permission java.net.NetPermission "specifyStreamHandler";
};Of course, you'll have to tweak the entries if you use the components
in your apps. Also of note, the Sun App Server team has been debating
turning the security manager off by default, so this step may not be
necessary in the future. -
Make sure any attempts to deploy a previous version of
adf-faces-demo.warhave been completely removed
from the App Server. For example, I have noticed that
occasionally theadf-faces-demodirectory stick
around in
domains/domain1/applications/j2ee-modules. I had
to manually remove this directory to enable the demo to
work. -
From the ADF Faces download, deploy the
adf-faces-demo.warto your running Java EE SDK
App Server and visit the demo to enjoy ADF Faces on Java EE 5!
If you find any bugs when trying the demo please file them on the
href="https://javaserverfaces.dev.java.net/servlets/ProjectIssues">JSF
issue tracker or the
href="https://glassfish.dev.java.net/servlets/ProjectIssues">Glassfish
issue tracker.
Also, note that this version of JSF includes the new
invokeOnComponent feature we developed with help from Jacob
Hookom and mentioned
href="http://weblogs.java.net/blog/jhook/archive/2006/02/new_feature_for.html">in
his blog. Lastly, the jsf jars in the
href="https://maven-repository.dev.java.net/nonav/repository/javax.faces/jars/">java.net
Maven 1 Repository have been updated as well.
Technorati Tags: edburns
- Login or register to post comments
- Printer-friendly version
- edburns's blog
- 2811 reads






Comments
Ed you have saved
by komarios - 2009-12-06 20:48
Ed you have saved me.Without you I would never have been able to deploy an adf application to glassfish. I have posted a more recent successful attempt to deploy adf faces in glassfish:
http://mariosgaee.blogspot.com/2009/12/glassfish-and-adf-faces.html
along with another successful attempt to deploy Adf Toplink Ejbs 10g here:
http://mariosgaee.blogspot.com/2009/12/glassfish-and-adf-toplink-10g.html
and here
http://mariosgaee.blogspot.com/2009/12/glassfish-and-adf-toplink-part-2....
keep up the very good work!
glassfish rocks!