Skip to Content.
Sympa Menu

grouper-users - RE: [grouper-users] deleting a rule using GSH

Subject: Grouper Users - Open Discussion List

List archive

RE: [grouper-users] deleting a rule using GSH


Chronological Thread 
  • From: "Hyzer, Chris" <>
  • To: Scott Koranda <>, grouper-users <>
  • Subject: RE: [grouper-users] deleting a rule using GSH
  • Date: Tue, 1 Mar 2016 09:31:28 +0000
  • Accept-language: en-US
  • Authentication-results: gmail.com; dkim=none (message not signed) header.d=none;gmail.com; dmarc=none action=none header.from=isc.upenn.edu;
  • Spamdiagnosticmetadata: NSPM
  • Spamdiagnosticoutput: 1:23

grouperSession = GrouperSession.startRootSession();

stem = StemFinder.findByName(grouperSession, "test:testRules");

RuleApi.inheritGroupPrivileges(SubjectFinder.findRootSubject(), stem, Stem.Scope.SUB, SubjectFinder.findRootSubject(), Privilege.getInstances("admin"));

RuleApi.inheritGroupPrivileges(SubjectFinder.findRootSubject(), stem, Stem.Scope.SUB, SubjectFinder.findRootSubject(), Privilege.getInstances("admin"));

RuleApi.rulesToString(stem);

stem.getAttributeDelegate().removeAttributeByAssignId("af0aa3601b5149a08b71d7d82ea6a906");

 

I cant think of a reason why you would want two of the same rule, maybe one should be invalid if there is a duplicate.

 

https://bugs.internet2.edu/jira/browse/GRP-1261

 

Thanks

Chris

 

-----Original Message-----
From: [mailto:] On Behalf Of Scott Koranda
Sent: Monday, February 29, 2016 12:56 PM
To: grouper-users <>
Subject: [grouper-users] deleting a rule using GSH

 

Hi,

 

While debugging an issue with a rule on a stem I believe we

created multiple instances of the same rule. For example:

 

gsh 2% RuleApi.rulesToString(testFolder01)

Rule 0: attributeAssignTypeId: 76e5374288114134bb9df396ae9b9ada, actAsSourceId: g:isa, actAsSubjectId: GrouperSystem, checkStemScope: SUB, checkType: groupCreate, thenEnum: assignGroupPrivilegeToGroupId, thenEnumArg0: jdbc :::: subject1, thenEnumArg1: read,

Rule 1: attributeAssignTypeId: 944cd69989d14d41881c39362c79f78a, actAsSourceId: g:isa, actAsSubjectId: GrouperSystem, checkStemScope: SUB, checkType: groupCreate, thenEnum: assignGroupPrivilegeToGroupId, thenEnumArg0: jdbc :::: subject1, thenEnumArg1: read,

Rule 2:

gsh 3%

 

I think that says that the exact same rule is assigned twice to that

stem, correct?

 

If that is correct, what GSH command(s) can I use to delete 'Rule 1'?

 

Thanks,

 

Scott K

 



  • RE: [grouper-users] deleting a rule using GSH, Hyzer, Chris, 03/01/2016

Archive powered by MHonArc 2.6.16.

Top of Page