Skip to Content.
Sympa Menu

grouper-users - RE: [grouper-users] roll ups using the loader?

Subject: Grouper Users - Open Discussion List

List archive

RE: [grouper-users] roll ups using the loader?


Chronological Thread 
  • From: Chris Hyzer <>
  • To: "Bryan E. Wooten" <>, "" <>
  • Subject: RE: [grouper-users] roll ups using the loader?
  • Date: Fri, 21 Mar 2014 17:22:28 +0000
  • Accept-language: en-US

 

> I will confess that I have read that wiki a bunch of times and it just is not sinking in.

>

> I just wrote 3 views (students / instructors / both) and used 3 loader jobs.

 

For the both, it should return groupnames under the column subject_identifier, or group uuids under the column subject_id

 

>

> But having said that I am very intrigued by this line:

>

> grouperLoaderGroupQuery: select group_name, readers, updaters from course_group_query_v

 

That is metadata about the jobs.  It should return one row for every group in the loader job

 

>

> Is the course_group_query_v running against the Grouper DB or Oracle/Datawharehouse/other?

 

It runs against whatever database connect the loader job is configured for.  In Penn’s case we run it against the warehouse, but we have a database link back to the grouper db (or vise versa).  See which way gives you the best performance, and in oracle, “driving site” hint helped

 

>

> And lastly my grouperLoaderQueries all look like this: select group_name, subject_id, ‘ldap’

> from myView. Where ldap is my subject source.

>

> Where can I find documentation on all the allowed column names for the select (ie group_name,

> subject_id, readers, updaters, etc).

 

Should all be here:  https://spaces.internet2.edu/display/Grouper/Grouper+-+Loader

 

grouperLoaderQuery: This is the query to run in the DB, which must have certain columns required or optional based on the grouperLoaderType.  e.g. for SQL_SIMPLE, the SUBJECT_ID is required, and the SUBJECT_SOURCE_ID is optional.  If your DB supports views, might not be a bad idea to link query up to a view so you can easily see what it will return and change it without affecting the group attribute.  But will work with any select query.  This is required.  Note: in Grouper v2.1 you can try having SUBJECT_IDENTIFIER or SUBJECT_ID_OR_IDENTIFIER instead of SUBJECT_ID, though each is less efficient than the next since they require an extra subject lookup or multiple subject lookups per row

 

grouperLoaderGroupQuery: query (optional) for SQL_GROUP_LIST which should return cols: group_name, group_display_name (optional), group_description (optional) which if there are used for the group display and extension.  Note: the parent stem display names are only changed when creating them.  This should return all groups in the membership list, and if not there, its ok, the extension will be used as display extension, and a generated description. Note: the display name is the display path, with the display extension of each parent stem.  If there is a column named any of the following: readers, viewers, admins, updaters, optins, optouts, then the data in the column (comma separated subjectId's or subjectIdentifers (which can include group names) will be assigned to that privilege list.  Note, existing assignments to that privilege list will not be removed, so if you remove an item from the query, you will need to manually remove it from the groups.  This is a way to have a loaderJob-wide list of readers or viewers.

 

>

> I assume your select with readers / updaters doesn’t actually create the group but adds

> privileges to subjects for an existing group. Does that make sense?

> 

 

Mmm, I think for empty groups it will create the empty group

 

Thanks,

Chris

 

 

From: [mailto:] On Behalf Of Bryan E. Wooten
Sent: Friday, March 21, 2014 1:15 PM
To:
Subject: FW: [grouper-users] roll ups using the loader?

 

Sorry, I meant to send this to the list….

 

-Bryan

 

From: Bryan E. Wooten
Sent: Friday, March 21, 2014 11:10 AM
To: 'Chris Hyzer'
Subject: RE: [grouper-users] roll ups using the loader?

 

I will confess that I have read that wiki a bunch of times and it just is not sinking in.

 

I just wrote 3 views (students / instructors / both) and used 3 loader jobs.

 

But having said that I am very intrigued by this line:

 

grouperLoaderGroupQuery: select group_name, readers, updaters from course_group_query_v

 

Is the course_group_query_v running against the Grouper DB or Oracle/Datawharehouse/other?

 

And lastly my grouperLoaderQueries all look like this: select group_name, subject_id, ‘ldap’ from myView. Where ldap is my subject source.

 

Where can I find documentation on all the allowed column names for the select (ie group_name, subject_id, readers, updaters, etc).

 

I assume your select with readers / updaters doesn’t actually create the group but adds privileges to subjects for an existing group. Does that make sense?

 

Thanks,

 

Bryan

 

 

 

From: [] On Behalf Of Chris Hyzer
Sent: Friday, March 21, 2014 10:36 AM
To: Scott Koranda; grouper-users
Subject: RE: [grouper-users] roll ups using the loader?

 

Yes, that is what the classlist at penn and the joins to the grouper_groups table does...  obviously I need to revist that doc, its hard to understand.

 

I wrote this up earlier this year with a long discussion on the list:

 

https://spaces.internet2.edu/display/Grouper/Grouper+loader+example+include+exclude+and+privileges

 

 

Now you need to flex your SQL muscles and make a query that will create all the other groups for you (use UNION?). Or this could be multiple loader jobs.   This is in a separate loader job that runs after (?) the first one. You can join to the grouper groups table so that it only does groups that exist and wont have unresolvable subject errors. Note if you join to the grouper_groups table, the you will get better performance too.  However you might want to run this 3 times in a row (or however many times it needs) so that all can be managed in one day.

grouperLoaderQuery:   select group_name, subject_identifier, subject_source_id from course_group_structure_v

 

GROUP_NAME

SUBJECT_IDENTIFIER

SUBJECT_SOURCE_ID

courses:math101:math101

courses:math101:math101_students

g:gsa

courses:math101:math101

courses:math101:math101_instructors

g:gsa

courses:math101:math101_students

courses:math101:math101_students_includes

g:gsa

courses:math101:math101_students

courses:math101:math101_students_systemOfRecord

g:gsa

courses:math101:math101_instructors

courses:math101:math101_instructors_includes

g:gsa

courses:math101:math101_instructors

courses:math101:math101_instructors_systemOfRecord

g:gsa

courses:english101:english101

courses:english101:english101_students

g:gsa

courses:english101:english101

courses:english101:engilsh101_instructors

g:gsa

Now we can have privileges on these groups... again, you can do this with views, and unions, etc  Note, if you can join to the grouper_groups table and use the group UUIDs, it would be faster.

grouperLoaderGroupQuery: select group_name, readers, updaters from course_group_query_v

 

GROUP_NAME

READERS

UPDATERS

courses:math101:math101

courses:etc:courseReaders,courses:math101:math101_instructors

 

courses:math101:math101_students

courses:etc:courseReaders,courses:math101:math101_instructors

 

courses:math101:math101_students_includes

courses:etc:courseReaders,courses:math101:math101_instructors

courses:etc:courseUpdaters,courses:math101:math101_instructors

courses:math101:math101_instructors

courses:etc:courseReaders,courses:math101:math101_instructors

 

courses:math101:math101_instructors_includes

courses:etc:courseReaders,courses:math101:math101_instructors

courses:etc:courseUpdaters,courses:math101:math101_instructors

courses:english101:english101

courses:etc:courseReaders,courses:english101:english101_instructors

 

sdf

 

 

 

 

-----Original Message-----
From: [] On Behalf Of Scott Koranda
Sent: Friday, March 21, 2014 12:32 PM
To: grouper-users
Subject: [grouper-users] roll ups using the loader?

 

Hi,

 

Outside of the addIncludeExclude functionality is it possible for a

loader job to manage arbitrary "roll ups" of groups like 'students',

'instructors', and 'guests' into an 'all' group?

 

Thanks,

 

Scott K




Archive powered by MHonArc 2.6.16.

Top of Page