top button
Flag Notify
    Connect to us
      Site Registration

Site Registration

How can I get hold of realm object (JDBCRealm) within Java app?

+1 vote
270 views

I have configured JDBCRealm Tomcat with the following:

I have a few questions:
1) How can I get hold of this realm object within my Java app?
2) Even if I get the instance of the JDBCRealm - how do I get the list of all roles available?

posted Sep 2, 2014 by anonymous

Looking for an answer?  Promote on:
Facebook Share Button Twitter Share Button LinkedIn Share Button
What's the purpose of doing this?

If I wanted to get a list of my users or roles, I would use JDBC and pull them from the database. Then I don't have to tie my application to Tomcat's internal classes.

...