[Yanel-dev] Loading of users and groups as XML
Guillaume Déflache
guillaume.deflache at wyona.com
Thu Feb 11 11:12:05 CET 2010
Hi!
Michael Wechner schrieb:
> Hi
>
> The PolicyManager resource
>
> src/contributions/resources/policymanager/src/java/org/wyona/yanel/impl/resources/policymanager/PolicyManagerResource.java
>
>
> is loading users and groups via the following query string
>
> /foo/bar?yanel.policy=update&get=identities
>
> which then is handled by the YanelServlet#doAccessPolicyRequest()
>
> first, but then forwarded again to the PolicyManager resource
>
> if (getXML != null && getXML.equals("identities")) {
> sb.append(getIdentitiesAndRightsAsXML(getRealm().getIdentityManager(),
> getRealm().getPolicyManager(), get
> RequestedLanguage()));
>
> Now I would like to re-use this for editing users and groups, but it
> seems to me that the main purpose of the policy manager
> resource is to manage policies and not users and groups and hence I
> think we should re-factor this by introducing a IdentityManagerResource.
>
> WDYT?
I fully agree!
I think we should put that under e.g. <yanel-prefix>/admin/groups and
<yanel-prefix>/admin/users
Also why not using /foo/bar/yanel.usecase=read-policy (resp.
update-policy) instead of /foo/bar?yanel.policy=read (resp. update)?
It goes in the way of allowing to fully split policy reading code from
the PolicyManager, which would be also helpful IMHO, because you may
want to reimplement both parts separately.
Cheers,
Guillaume
More information about the Yanel-development
mailing list