This class provides an implementaion of the factory API based on
information obtained from a database.
Usage of this class as service factory requires several
configuration parameters for accessing the database. The
factory uses the following ordered lookup procedure to determine
these parameters:
The following parameters are used:
dataSource
- The lookup name of the data source in JNDI
(e.g.
java:/DefaultDS ).
allUsersQuery
- The query that returns the known users as a two column result with
the user's entry's primary key in the first column and the user's
display name in the second.
allRolesQuery
- The query that returns the known roles as a two column result with
the role's entry's primary key in the first column and the role's
display name in the second.
allGroupsQuery
- The query that returns the known groups as a two column result with
the group's entry's primary key in the first column and group's
display name in the second.
userNameQuery
- The query that returns user data as a single column result with the
user's display name in the only column. The user's entry's primary key
is set as query parameter.
roleNameQuery
- The query that returns role data as a single column result with the
role's display name in the only column. The role's entry's primary key
is set as query parameter.
groupNameQuery
- The query that returns group data as a single column result with the
group's display name in the only column. The group's entry's primary key
is set as query parameter.
userLookupQuery
- The query that returns a user's data as a two column result with the
user's entry's primary key in the first column and the user's display
name in the second. The user's account name (usually the login name) is
set as query parameter.
roleLookupQuery
- The query that returns a role's data as a two column result with the
role's entry's primary key in the first column and the role's display
name in the second. The role's "account" name (clear text name) is set
as query parameter.
groupLookupQuery
- The query that returns a group's data as a two column result with the
group's entry's primary key in the first column and the group's name
display in the second. The groups's "account" name (clear text name) is
set as query parameter.
rolesQuery
- The query that returns a user's roles as a two column result with the
role's entry's primary key in the first column and the role's display
name in the second. The user's entry's primary key is set as query
parameter.
groupsQuery
- The query that returns a user's groups as a two column result with the
group's entry's primary key in the first column and the group's display
name in the second. The user's entry's primary key is set as query
parameter.
author: Michael Lipp version: $Revision: 1.7 $ |