Skip to Content.
Sympa Menu

grouper-dev - too many users returned from subject source

Subject: Grouper Developers Forum

List archive

too many users returned from subject source

Chronological Thread 
  • From: Chris Hyzer <>
  • To: "" <>
  • Subject: too many users returned from subject source
  • Date: Wed, 23 Sep 2009 21:03:20 -0400
  • Accept-language: en-US
  • Acceptlanguage: en-US


We have a subject search field which includes in the user is active or not
active. So if someone searches for "active" (actually, this is the "filter"
in the lite ui, which I should change the label to "search" instead of
"filter"), then the subject API returns hundreds of thousands of results
(since it matches "active" and "not active" and our tomcat runs out of
memory. I kind of think subject sources should have a config option
(optional) where it can throw an exception if too many results are returned
(e.g. we might set ours to 1000). So for instance in a JDBC source, it could
do a count(*), if the count is ok, do the query. Or it could do the query,
and cycle through the resultset until the limit, and throw the exception
before continuing (this is probably preferable). This would be a subclass of
RuntimeException so it wouldn't affect the compilation of other people's
code. Then UI's could catch that exception and tell the user to narrow the
search. I think we would need to add code to handle that exception in the
lite UI and the regular UI. I can implement this in the jdbc2 source. Not
sure what is possible for jndi sources. Thoughts?


Archive powered by MHonArc 2.6.16.

Top of Page