Skip to Content.
Sympa Menu

grouper-users - [grouper-users] LDAP Group of Groups loader job

Subject: Grouper Users - Open Discussion List

List archive

[grouper-users] LDAP Group of Groups loader job


Chronological Thread 
  • From: Sam Erie <>
  • To:
  • Subject: [grouper-users] LDAP Group of Groups loader job
  • Date: Tue, 19 Jun 2018 14:18:28 -0800
  • Ironport-phdr: 9a23:zjSiPxVuYYa83xcDjRRU6xKtSvTV8LGtZVwlr6E/grcLSJyIuqrYbROAt8tkgFKBZ4jH8fUM07OQ7/i9HzRYqb+681k6OKRWUBEEjchE1ycBO+WiTXPBEfjxciYhF95DXlI2t1uyMExSBdqsLwaK+i764jEdAAjwOhRoLerpBIHSk9631+ev8JHPfglEnjWwba9yIRmssQndqtQdjJd/JKo21hbHuGZDdf5MxWNvK1KTnhL86dm18ZV+7SleuO8v+tBZX6nicKs2UbJXDDI9M2Ao/8LrrgXMTRGO5nQHTGoblAdDDhXf4xH7WpfxtTb6tvZ41SKHM8D6Uaw4VDK/5KptVRTmijoINyQh/W/XhMJ+j79Vrgy9qBFk2YHYfJuYOeBicq/Bf94XQ3dKUMZLVyxGB4Oxd5YBAPAEPe1FoIf9vVoOogWjDgSrH+Pg1CVIhn7o0qAhyeshFRvJ3BcjH90Uqnjbssj6NLoLXO2z0aLGwzLDb/ZM1jf87ojFagsuoPGLXb1rc8re11UgFx/ejlWMs4PlIzKV2fgXv2iA9eVgS/ygh3YoqwFrpTiv298shZfTho4P0F/E7T15zJ4pJd24Uk50f8SrH4ZKuyGAKot2RNsuQ2FpuCkhxLAGvIC0fC0Rx5s53R7fcPyHc4mQ4h3+TumRJi10hGl/d7KhmRm+6Uegyvf7VsmpyFZFsDBFncXWuXAJ0xzc8NOISv9j8Uu7xTmAzQTT6uVcLU8vlavbLIUuwrwumZUPrUTPBDT2l1/ojKCIbkkk9PWo6/j6YrX8uJCcK5V7ihr9Mqg0gMy/HOI4Pw4TVGaY4eSxzKPv8EzlTLhIi/A2nKrUv4vGKckeqaO1HxNZ34gm5hmjEzum3tEVkHwZIF9LeB+KiZXiNUvUL/DiF/i/hkyhkDd1yPDCOb3sGpDNIWLCkLflZLp97FJcxBYqwdFQ+Z5ZBLEMLOj8Wk/2s9zYARs5PBKuz+n7D9V905sSWWOJAqCHLKPfqUGE6+MzL+SOYYIVtjXwJOM56/PrgnI1hUMRcKes0JQLdHy4EPFrLkCHbXfigtoNCWIKsRA/TOzuhl2CSzlTZ3OqUqIn+D47EoOmApnYS4+3hLyOxjy7Hp5MaWxcFF+DDGroe52eW/gQcCKSPtNhkjscWLiuUY8h0gyutBfkxLp9N+bU5zYYuoz51Nhu/ODTkRAy9SdoD8SGzW2BVWB0nmUURzAoxqB/p1Jyykud3aRinfNXCMFTtLt1VVI1L5nB1+FgTs3pVxjaVtaPVFu8RNi6W3c8Qs9i7cUJZhNGEtDqowrC0mL+GLIPlrGjDZg96aHVmXX9OpAumD79yKA9ggx+EYN0Pmq8i/sn+g==

So this is a continuation of my previous Group of Groups question, and I have a potential solution. I would like to make sure that I am understanding this correct, and am not about to make a big mess for myself.

I have a group source set up, which will resolve subjects of type group. This doesn't work with the loader job though because it is trying to resolve groups by uuid. I am getting an exception when I try to run my group of groups loader saying that it cannot find a specific group by uuid, that I can find as a group like: 
groovy:000> findSubject('ua-oit-ca-dept','group','ADgroups');
===> Subject id: ua-oit-ca-dept, sourceId: ADgroups

I will include the loader error at the bottom incase I am missing something important.

So my potential solution (and only possibility I can imagine) is to create groups from all the subjects. I can get a list of the group subjects like:
groupSubs = SubjectFinder.findAll("*","ADgroups");

And then I could go through them with a forloop and create a group for each like:
gs = GrouperSession.startRootSession();
addGroup("Statewide", var, var);
group = GroupFinder.findByName(gs, "Statewide:"+var);
group.store();

I'm unsure if addGroup() is designating the uuid or if that is generated,
I think it is generated. If it is I would still need to come up with some way
to find the uuid from the groupname in the loader. 

Hopefully this is a bit more clear than my last post. I appreciate any
advice I can get.

Here is the full output from the failed loader:

groovy:000> findSubject('ua-oit-ca-dept','group','ADgroups');
===> Subject id: ua-oit-ca-dept, sourceId: ADgroups
groovy:000> loaderRunOneJob(lg);
java.lang.RuntimeException: edu.internet2.middleware.grouper.exception.GroupNotFoundException: Cant find group by uuid: ua-oit-ca-dept,
Exception in save: edu.internet2.middleware.grouper.Membership, edu.internet2.middleware.grouper.hibernate.ByObject@2caf2795,
Problem in HibernateSession: HibernateSession (6f75330): notNew, notReadonly, READ_WRITE_NEW, activeTransaction, session (5c2a8b5a),
Exception in save: edu.internet2.middleware.grouper.Membership, ByObjectStatic, query: ', cacheable: null, cacheRegion: null, entityName: ImmediateMembershipEntry, tx type: null,
, group name: Statewide:UA_Users, subject: Subject id: ua-oit-ca-dept, sourceId: ADgroups, field: members,
Problem in HibernateSession: HibernateSession (383625e8): new, notReadonly, READ_WRITE_NEW, notActiveTransaction, session (5c2a8b5a)
        at edu.internet2.middleware.grouper.Group$4.callback(Group.java:1412)
        at edu.internet2.middleware.grouper.hibernate.HibernateSession.callbackHibernateSession(HibernateSession.java:700)
        at edu.internet2.middleware.grouper.Group.internal_addMember(Group.java:1366)
        at edu.internet2.middleware.grouper.Group.addMember(Group.java:940)
        at edu.internet2.middleware.grouper.Group.addMember(Group.java:859)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType.syncOneMemberAddMemberLogic(GrouperLoaderType.java:4747)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType.access$400(GrouperLoaderType.java:126)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType$13$2.callLogic(GrouperLoaderType.java:3149)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType$13$2.callLogic(GrouperLoaderType.java:3141)
        at edu.internet2.middleware.grouper.util.GrouperCallable$1.callback(GrouperCallable.java:191)
        at edu.internet2.middleware.grouper.GrouperSession.callbackGrouperSession(GrouperSession.java:974)
        at edu.internet2.middleware.grouper.util.GrouperCallable.callLogicWithSessionIfExists(GrouperCallable.java:188)
        at edu.internet2.middleware.grouper.util.GrouperCallable.call(GrouperCallable.java:154)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:748)
Caused by: edu.internet2.middleware.grouper.exception.GroupNotFoundException: Cant find group by uuid: ua-oit-ca-dept,
Exception in save: edu.internet2.middleware.grouper.Membership, edu.internet2.middleware.grouper.hibernate.ByObject@2caf2795,
Problem in HibernateSession: HibernateSession (6f75330): notNew, notReadonly, READ_WRITE_NEW, activeTransaction, session (5c2a8b5a),
Exception in save: edu.internet2.middleware.grouper.Membership, ByObjectStatic, query: ', cacheable: null, cacheRegion: null, entityName: ImmediateMembershipEntry, tx type: null
        at edu.internet2.middleware.grouper.internal.dao.hib3.Hib3GroupDAO.findByUuid(Hib3GroupDAO.java:1666)
        at edu.internet2.middleware.grouper.internal.dao.hib3.Hib3GroupDAO.findByUuid(Hib3GroupDAO.java:1634)
        at edu.internet2.middleware.grouper.Membership.processPostMembershipSaveOrUpdate(Membership.java:2132)
        at edu.internet2.middleware.grouper.Membership.onPostSave(Membership.java:2008)
        at edu.internet2.middleware.grouper.hibernate.ByObject.save(ByObject.java:224)
        at edu.internet2.middleware.grouper.hibernate.ByObjectStatic$7.callback(ByObjectStatic.java:494)
        at edu.internet2.middleware.grouper.hibernate.HibernateSession.callbackHibernateSession(HibernateSession.java:700)
        at edu.internet2.middleware.grouper.hibernate.ByObjectStatic.save(ByObjectStatic.java:481)
        at edu.internet2.middleware.grouper.internal.dao.hib3.Hib3MembershipDAO.save(Hib3MembershipDAO.java:2095)
        at edu.internet2.middleware.grouper.Membership.internal_addImmediateMembership(Membership.java:1257)
        at edu.internet2.middleware.grouper.Group$4.callback(Group.java:1394)
        ... 16 more
java.lang.RuntimeException: edu.internet2.middleware.grouper.exception.GroupNotFoundException: Cant find group by uuid: ua-oit-ca-dept,
Exception in save: edu.internet2.middleware.grouper.Membership, edu.internet2.middleware.grouper.hibernate.ByObject@26fe6298,
Problem in HibernateSession: HibernateSession (7703f829): notNew, notReadonly, READ_WRITE_NEW, activeTransaction, session (79b1c4d6),
Exception in save: edu.internet2.middleware.grouper.Membership, ByObjectStatic, query: ', cacheable: null, cacheRegion: null, entityName: ImmediateMembershipEntry, tx type: null,
, group name: Statewide:UA_Users, subject: Subject id: ua-oit-ca-dept, sourceId: ADgroups, field: members,
Problem in HibernateSession: HibernateSession (2e53dfd): new, notReadonly, READ_WRITE_NEW, notActiveTransaction, session (79b1c4d6)
        at edu.internet2.middleware.grouper.Group$4.callback(Group.java:1412)
        at edu.internet2.middleware.grouper.hibernate.HibernateSession.callbackHibernateSession(HibernateSession.java:700)
        at edu.internet2.middleware.grouper.Group.internal_addMember(Group.java:1366)
        at edu.internet2.middleware.grouper.Group.addMember(Group.java:940)
        at edu.internet2.middleware.grouper.Group.addMember(Group.java:859)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType.syncOneMemberAddMemberLogic(GrouperLoaderType.java:4747)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType.access$400(GrouperLoaderType.java:126)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType$13$2.callLogic(GrouperLoaderType.java:3149)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType$13$2.callLogic(GrouperLoaderType.java:3141)
        at edu.internet2.middleware.grouper.util.GrouperCallable.tryCallablesWithProblems(GrouperCallable.java:51)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType$13.callback(GrouperLoaderType.java:3176)
        at edu.internet2.middleware.grouper.internal.dao.hib3.Hib3TransactionDAO$1.callback(Hib3TransactionDAO.java:66)
        at edu.internet2.middleware.grouper.hibernate.HibernateSession.callbackHibernateSession(HibernateSession.java:700)
        at edu.internet2.middleware.grouper.internal.dao.hib3.Hib3TransactionDAO.transactionCallback(Hib3TransactionDAO.java:56)
        at edu.internet2.middleware.grouper.hibernate.GrouperTransaction.callbackGrouperTransaction(GrouperTransaction.java:87)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType.syncOneGroupMembership(GrouperLoaderType.java:3084)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType.syncGroupLogicForOneGroup(GrouperLoaderType.java:2000)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType.access$200(GrouperLoaderType.java:126)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType$12.callLogic(GrouperLoaderType.java:1906)
        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType$12.callLogic(GrouperLoaderType.java:1896)
        at edu.internet2.middleware.grouper.util.GrouperCallable$1.callback(GrouperCallable.java:191)
        at edu.internet2.middleware.grouper.GrouperSession.callbackGrouperSession(GrouperSession.java:974)
        at edu.internet2.middleware.grouper.util.GrouperCallable.callLogicWithSessionIfExists(GrouperCallable.java:188)
        at edu.internet2.middleware.grouper.util.GrouperCallable.call(GrouperCallable.java:154)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:748)
Caused by: edu.internet2.middleware.grouper.exception.GroupNotFoundException: Cant find group by uuid: ua-oit-ca-dept,
Exception in save: edu.internet2.middleware.grouper.Membership, edu.internet2.middleware.grouper.hibernate.ByObject@26fe6298,
Problem in HibernateSession: HibernateSession (7703f829): notNew, notReadonly, READ_WRITE_NEW, activeTransaction, session (79b1c4d6),
Exception in save: edu.internet2.middleware.grouper.Membership, ByObjectStatic, query: ', cacheable: null, cacheRegion: null, entityName: ImmediateMembershipEntry, tx type: null
        at edu.internet2.middleware.grouper.internal.dao.hib3.Hib3GroupDAO.findByUuid(Hib3GroupDAO.java:1666)
        at edu.internet2.middleware.grouper.internal.dao.hib3.Hib3GroupDAO.findByUuid(Hib3GroupDAO.java:1634)
        at edu.internet2.middleware.grouper.Membership.processPostMembershipSaveOrUpdate(Membership.java:2132)
        at edu.internet2.middleware.grouper.Membership.onPostSave(Membership.java:2008)
        at edu.internet2.middleware.grouper.hibernate.ByObject.save(ByObject.java:224)
        at edu.internet2.middleware.grouper.hibernate.ByObjectStatic$7.callback(ByObjectStatic.java:494)
        at edu.internet2.middleware.grouper.hibernate.HibernateSession.callbackHibernateSession(HibernateSession.java:700)
        at edu.internet2.middleware.grouper.hibernate.ByObjectStatic.save(ByObjectStatic.java:481)
        at edu.internet2.middleware.grouper.internal.dao.hib3.Hib3MembershipDAO.save(Hib3MembershipDAO.java:2095)
        at edu.internet2.middleware.grouper.Membership.internal_addImmediateMembership(Membership.java:1257)
        at edu.internet2.middleware.grouper.Group$4.callback(Group.java:1394)
        ... 27 more
ERROR java.lang.RuntimeException:
java.lang.RuntimeException: Error in loader job: Loaders:SWgroupLoader, check logs: null
        at edu.internet2.middleware.grouper.app.loader.GrouperLoader.runJobOnceForGroup (GrouperLoader.java:1579)
        at edu.internet2.middleware.grouper.app.gsh.loaderRunOneJob.invoke (loaderRunOneJob.java:92)
        at edu.internet2.middleware.grouper.app.gsh.loaderRunOneJob$invoke.call (Unknown Source)
        at groovysh_evaluate.loaderRunOneJob (groovysh_evaluate:4)

 




Archive powered by MHonArc 2.6.19.

Top of Page