Skip to Content.
Sympa Menu

grouper-dev - [grouper-dev] RE: Cannot run LDAP Loader as a daemon

Subject: Grouper Developers Forum

List archive

[grouper-dev] RE: Cannot run LDAP Loader as a daemon


Chronological Thread 
  • From: Gagné Sébastien <>
  • To: "Chris Hyzer" <>
  • Cc: <>
  • Subject: [grouper-dev] RE: Cannot run LDAP Loader as a daemon
  • Date: Thu, 7 Jun 2012 15:34:20 -0400

Seems to work ! In my test I forgot to change it at the second location mentioned in the bug.

 

I’m still wondering how to turn on and off the loader without deleting the group, maybe I can put a very long CRON …

 

Thanks

 

De : Chris Hyzer [mailto:]
Envoyé : 7 juin 2012 14:23
À : Gagné Sébastien;
Objet : RE: Cannot run LDAP Loader as a daemon

 

Yes, sorry, this was fixed a couple of months ago in 2.1.1 but it hasnt been released yet, can you change it to this?

 

      if (grouperLoaderType.equals(GrouperLoaderType.ATTR_SQL_SIMPLE)) {

       

        runJobAttrDef(hib3GrouploaderLog, attributeDef, grouperSession);

      } else if (grouperLoaderType.equals(GrouperLoaderType.LDAP_SIMPLE)

        || grouperLoaderType.equals(GrouperLoaderType.LDAP_GROUP_LIST)

        || grouperLoaderType.equals(GrouperLoaderType.LDAP_GROUPS_FROM_ATTRIBUTES)) {

       

        runJobLdap(hib3GrouploaderLog, group, grouperSession);

      } else {

        //all other jobs go through here

        runJob(hib3GrouploaderLog, group, grouperSession);

      }

 

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

 

Thanks,

Chris

 

From: On Behalf Of Gagné Sébastien
Sent: Thursday, June 07, 2012 2:07 PM
To:
Subject: [grouper-dev] Cannot run LDAP Loader as a daemon

 

Hi,

I’m able to run the LDAP loader job manually with loaderRunOneJob(group). But when I try to start the loader, the job fails (see trace below).

 

I did define the LDAP server ID = personLdap in my group. The problem seems to be in the init phase for a daemon job since the job can be run manually.

 

I also had a question : how do I turn on and off the LDAP loader ? It seems that as soon as there is a group with the appropriate attribute, the loader ldap will be in function.

 

 

2012-06-07 12:58:30,033: [DefaultQuartzScheduler_Worker-4] ERROR GrouperLoaderJob.runJob(387) -  - Error on job: LDAP_GROUP_LIST__etc:confLDAPLoader__e7b97262558b477fab09c0b48f98ed1c

java.lang.RuntimeException: Cant find the ldap connection named: 'null' in the grouper-loader.properties.  Should have entry: ldap.null.url,

Problem with ldap conection: null,

Error querying ldap server id: null, searchDn: null, filter: 'null', returning subject attribute: null

        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderConfig.retrieveLdapProfile(GrouperLoaderConfig.java:288)

        at edu.internet2.middleware.grouper.ldap.LdapSession.blockingLdapPool(LdapSession.java:54)

        at edu.internet2.middleware.grouper.ldap.LdapSession.callbackLdapSession(LdapSession.java:174)

        at edu.internet2.middleware.grouper.app.loader.db.GrouperLoaderResultset.initForLdapListOfGroups(GrouperLoaderResultset.java:427)

        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType$7.runJob(GrouperLoaderType.java:763)

        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderJob.runJob(GrouperLoaderJob.java:379)

        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderJob.execute(GrouperLoaderJob.java:281)

        at org.quartz.core.JobRunShell.run(JobRunShell.java:202)

        at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:529)

 

2012-06-07 12:58:30,038: [DefaultQuartzScheduler_Worker-4] ERROR GrouperLoaderJob.execute(284) -  - Error running up job

java.lang.RuntimeException: Cant find the ldap connection named: 'null' in the grouper-loader.properties.  Should have entry: ldap.null.url,

Problem with ldap conection: null,

Error querying ldap server id: null, searchDn: null, filter: 'null', returning subject attribute: null

        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderConfig.retrieveLdapProfile(GrouperLoaderConfig.java:288)

        at edu.internet2.middleware.grouper.ldap.LdapSession.blockingLdapPool(LdapSession.java:54)

        at edu.internet2.middleware.grouper.ldap.LdapSession.callbackLdapSession(LdapSession.java:174)

        at edu.internet2.middleware.grouper.app.loader.db.GrouperLoaderResultset.initForLdapListOfGroups(GrouperLoaderResultset.java:427)

        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderType$7.runJob(GrouperLoaderType.java:763)

        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderJob.runJob(GrouperLoaderJob.java:379)

        at edu.internet2.middleware.grouper.app.loader.GrouperLoaderJob.execute(GrouperLoaderJob.java:281)

        at org.quartz.core.JobRunShell.run(JobRunShell.java:202)

        at org.quartz.simpl.SimpleThreadPool$WorkerThread.run(SimpleThreadPool.java:529)

 

 

Digging in the code, maybe the problem comes from :

 

GrouperLoaderJob.java (line 273 to 281)

      if (grouperLoaderType.equals(GrouperLoaderType.ATTR_SQL_SIMPLE)) {

       

        runJobAttrDef(hib3GrouploaderLog, attributeDef, grouperSession);

      } else if (grouperLoaderType.equals(GrouperLoaderType.LDAP_SIMPLE)) {

       

        runJobLdap(hib3GrouploaderLog, group, grouperSession);

      } else {

        //all other jobs go through here

        runJob(hib3GrouploaderLog, group, grouperSession);

      }

 

Based on the stack trace I’m going in the else, which doesn’t seem to load all the LDAP attributes like runJobLdap does, but going the same path as LDAP_SIMPLE gives me a Null pointer exception.

 

Thanks

 

 

Sébastien Gagné,     | Analyste en informatique

514-343-6111 x33844  | Université de Montréal,

                     | Pavillon Roger-Gaudry, local X-100-11

 




Archive powered by MHonArc 2.6.16.

Top of Page