Skip to Content.
Sympa Menu

grouper-users - RE: [grouper-users] Using a custom attribute for subject display

Subject: Grouper Users - Open Discussion List

List archive

RE: [grouper-users] Using a custom attribute for subject display

Chronological Thread 
  • From: Chris Hyzer <>
  • To: Peter DiCamillo <>, "" <>
  • Subject: RE: [grouper-users] Using a custom attribute for subject display
  • Date: Fri, 3 Aug 2012 05:47:24 +0000
  • Accept-language: en-US

Unfortunately the subject query method that the UI uses wasnt calling the
subject filter in 2.1.1. I fixed this and tested in 2.1.2 (currently in the
svn branch GROUPER_2_1_BRANCH)

I used the subject customizer Java class (attached). I configured it in the

# customize subjects by implementing this interface:
# or extending this class:
edu.internet2.middleware.grouper.subj.SubjectCustomizerBase (recommended)
# note the instance will be reused to make sure it is threadsafe
subjects.customizer.className =

I configured the media.propeties (note that for the lite UI you need to edit
the grouper/ and not the custom/, see

# for jdbc subjects in admin ui

# lite display settings
grouperUi.subjectImg.screenEl.1 = ${subject.getAttributeValue('uiLabel')}

Then I created the group (you can change this in the java source):
etc:privilegedGroup, and added some users to it.

When I logged in as those users, I saw a different display more info), than
when I logged in as users not in that group. If you can pull Grouper and
Grouper-UI from the branch, try it out. Otherwise, 2.1.2 should be out
shortly :)



on behalf of Peter DiCamillo
Sent: Thursday, August 02, 2012 4:08 PM

Subject: [grouper-users] Using a custom attribute for subject display

We're upgrading to Grouper 2.1.1, and I'm trying to improve how we
display subjects in the Grouper UI. Ideally, I'd like to display either:
lastname, firstname or
lastname, firstname (internal_id)
The internal id is confidential, but very convenient for privileged
staff who are allowed to access it. Grouper would include the internal
id in subject displays when a session's subject is privileged.

I tried to do this by defining a new attribute for subjects, and
specifying it for the source's subject.display attribute in
media.properies. First I tried to add the attribute to subjects using an
override for decorateSubjects. However, I never saw decorateSubjects
being called for subject display. After that, I tried overriding
filterSubjects, and adding the attribute to the subjects' attribute
maps. That worked for search results, but didn't work for group
membership results. Finally, while still using filterSubjects, I tried
defining a virtual attribute from the added attribute, and that didn't
work at all.

Is there a way to do what I want to do, or is it to too ambitious? The
new video regarding this topic was very helpful, and gave me the idea
this might be possible. Even if it isn't, I'm impressed by what clearly
is possible now.



Archive powered by MHonArc 2.6.16.

Top of Page