Seam Security demo running on Glassfish
After a little hacking, I have the new JBoss Seam booking demo running under GlassFish. This is based on Seam 1.1.6GA and uses the new Seam security model (which looks very cool).
The sample source code that ships with the Seam 1.1.6 glassfish demo is missing some crucial settings:
- Your web.xml needs a ejb-ref definition to the new Authenticator bean
- Seam security requires a drools securtyRules.drl config file
- You need to include the associated drools libraries (even if you don't use drools)
- components.xml needs to declare the location of the drools securtyRules.drl file
I also reworked the demo to make it open as a Netbeans Enterprise project. If you want to run this, you will need:
- GlassFish. I used the latest 9.0 UR1 build
- Netbeans. I used Netbeans 5.5.1 (it has some fixes to integrate with later GlassFish builds)
- The Seam 1.1.6GA distribution
You can download the NetBeans project file at http://mediacast.sun.com/share/warren/seamBooking.zip
You will need to define a few Libraries using the NetBeans library manager. I wish there was a nice way of exporting library definitions in NetBeans - but until then I have resorted to the hack of packing up my library definitions from ~/.netbeans/.... as a zip file. If you are brave, you can try dropping these into your own private NetBeans library folder (after editing the library paths), or failing that, have a look at the xml defs and it should be fairly obvious which jar files you need to include.
Here are the Netbeans library xml definitions: http://mediacast.sun.com/share/warren/SEAM-Libraries.zip
Enjoy
powered by performancing firefox

Posted by かず on February 21, 2007 at 07:09 PM MST #
Posted by Michael Yuan on February 28, 2007 at 08:42 AM MST #