Child pages
  • Unresolvable Subject Deletion Utility (USDU)
Skip to end of metadata
Go to start of metadata

 This topic is discussed in the "Grouper Maintenance" training video.

Unresolvable Subject Deletion Utility (USDU)

This document is released alongside Grouper v1.4.0.

The Unresolvable Subject Deletion Utility finds and optionally deletes memberships for subjects which can not be found by their source.

An unresolvable subject is a subject that can not be found by its source. A subject may be unresolvable because of a temporary or permanent source failure, or because it was removed from its source before memberships or privileges were deleted or revoked.

This utility attempts to lookup every member's subject. If a subject can not be found, it's immediate memberships are printed and optionally deleted.

A future version may extend the Source class to provide more efficient lookups of subjects.

Usage

$GROUPER_HOME/bin/gsh.sh -usdu <command line arguments>

Without any arguments, USDU prints its usage

usage: USDU -all | -source <arg> | -uuid <arg> [-delete] [-start <arg>]
 -all            find unresolvable subjects from all sources
 -delete         delete memberships and privileges
 -source <arg>   find unresolvable subjects from source
 -start <arg>    start session as this subject, default GrouperSystem
 -uuid <arg>     find unresolvable subject with member uuid

Unresolvable subjects are printed to stdout.

If an unresolvable subject is not a member of any groups:
 member_uuid='<uuid>' subject='<id>' no_memberships

For every group or stem and list that an unresolvable subject is a member of:
 member_uuid='<uuid>' subject='<id>' group|stem='<name>' list='<name>' [delete]

For every unresolvable subject, usdu prints one line for every immediate membership. If an unresolvable subject is not a member of any groups and has no privileges, usdu prints no_memberships.

Find unresolvable subjects from all sources

$GROUPER_HOME/bin/gsh.sh -usdu -all
member_uuid='e58697e4-...' subject='id1'/'source'/'person' group='stem:group1' list='members'
member_uuid='e58697e4-...' subject='id2'/'source'/'person' group='stem:group2' list='members'
...

Find unresolvable subjects from a specified source

$GROUPER_HOME/bin/gsh.sh -usdu -source CustomSource

Find unresolvable subject via member uuid

$GROUPER_HOME/bin/gsh.sh -usdu -uuid e58697e4-11a5-4082-b318-cb1e79191923

Delete unresolvable subject from all groups

$GROUPER_HOME/bin/gsh.sh -usdu -uuid e58697e4-... -delete
member_uuid='e58697e4-...' subject='id1'/'source'/'person' group='stem:group1' list='members' delete

Details

This utility finds and deletes memberships and privileges. It is possible for an unresolvable subject to be a creator or modifier of a group, in that case, calling Group.getCreateSubject() or Group.getModifySubject() will result in a SubjectNotFoundException.

Unresolvable subjects are not deleted from the grouper_members table. If an unresolvable subject becomes resolvable again, it will retain its member uuid.

  • No labels

1 Comment

  1. Default Grouper config does not allow USDU removal if the number of unresolvable subjects exceeds 200. However you can change increase this limit via the usdu.failsafe.maxUnresolvableSubjects Grouper property.

    Here is an extract from grouper.base.properties :

    #########################################
    ## Unresolvable Subject Deletion Utility
    #########################################

    # Don't do anything if more than this number of unresolvable subjects are found
    usdu.failsafe.maxUnresolvableSubjects = 200