JDBCRealm and GlassFish v2
By pelegri on Jun 09, 2006
Tomcat's JDBCRealm is used to provide authentication and authorization against a database. Since it is commonly used and it was lacking in GlassFish, JeanBaptiste submitted an intial code patch to do this; unfortunately, due to time constraints, this did not make it into GF v1 and this prompted Edson Richter to try it on his own. Using a Blog by Petr he has written another JDBCRealm implementation that has gained visibility very recently (JaxMag, TSS).
Meanwhile, back at the ranch, the original submission was worked on by Shing Wai and others which lead to yet another JDBCRealm, this one as a putback into the GF v2 trunk. Please check this latest implementation to be sure it does what you need; you can read about it in Shing Wai's Blog. Note that one of the differences between the two implementations is that Edson's was designed to use exactly the same configuration as Tomcat's while Shing Wai's does not. You can provide feedback at Shing Wai's blog or in this thread in the USERS mailing list.
This feature should show in the next GF v2 build (b07).