Hi,
With a netbeans Ent App to start I learned where to put all the necessary seam parts. If there is no wiki entry on this I could make one.
I do not put any seam anything into glassfish directly but all with the NetBeans. I choose the correct jars via the NetBeans project Properties-> Libraries category. It would be possible to make a NetBeans library for Seam but there are a number of cons. 1) there would be a need for more than one library; for the ejb and war respectively. 2) version upgrades are more painful(for me) 3) libraries haven't helped me when making CVS, SVN or mercurial systems work smoothly(i.e. the libraries are in the repository)
Some jars go with the ejb project and others go with the war. Some CANNOT, repeat, CANNOT go into the war; they kill your deploy and cause failures. I'll have to check but here is a list of the seam + jars in one of my war projects.
-------
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="
http://www.netbeans.org/ns/project/1">
<type>org.netbeans.modules.web.project</type>
<configuration>
<data xmlns="
http://www.netbeans.org/ns/web-project/3">
<name>ea-svg-chart-war</name>
<minimum-ant-version>1.6</minimum-ant-version>
<web-module-libraries>
<library files="1">
<file>${reference.ea-svg-chart-ejb.dist}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.batik-css.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.batik-dom.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.batik-svg-dom.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.batik-util.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.batik-xml.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.common-annotations.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.commons-beanutils.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.commons-collections-3.1.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.commons-collections.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.commons-digester.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.commons-logging.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.jawbone.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.jboss-seam-debug.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.jboss-seam-ioc.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.jboss-seam-remoting.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.jboss-seam-ui.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.jsf-facelets.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.jwnl.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.mathml-x-web.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.saxon9-dom.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.richfaces-api-3.2.0.GA.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.richfaces-impl-3.2.0.GA.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.richfaces-ui-3.2.0.GA.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.saxon9-xpath.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
<library files="1">
<file>${file.reference.saxon9.jar}</file>
<path-in-war>WEB-INF/lib</path-in-war>
</library>
</web-module-libraries>
<web-module-additional-libraries/>
<source-roots>
<root id="src.dir"/>
</source-roots>
<test-roots>
<root id="test.src.dir"/>
</test-roots>
</data>
<references xmlns="
http://www.netbeans.org/ns/ant-project-references/1">
<reference>
<foreign-project>ea-svg-chart-ejb</foreign-project>
<artifact-type>jar</artifact-type>
<script>build.xml</script>
<target>dist</target>
<clean-target>clean</clean-target>
<id>dist</id>
</reference>
</references>
</configuration>
</project>
-------
There are a number of other gotcha's to watch out for with putting seam into a Glassfish Ent App. One is there must be a seam.properties (even empty) in the
ent-app\ent-app-ejb\setup folder.
if there isn't a good Howto out there I can go through my experiences with Seam based Glassfish Ent App's. Including persistence setup, database schema's where applicable etc.
Let me know.
[Message sent by forum member 'rimartin7' (rimartin7)]
http://forums.java.net/jive/thread.jspa?messageID=277725