Announcement Announcement Module
Collapse
No announcement yet.
ClassNotFoundException with 1.1.1 Page Title Module
Move Remove Collapse
X
Conversation Detail Module
Collapse
  • Filter
  • Time
  • Show
Clear All
new posts

  • ClassNotFoundException with 1.1.1

    I did a drop-in replacement of the spring-ldap-1.1.jar with the new spring-ldap-1.1.1.jar and with no other changes, my unit tests are failing now:

    Code:
    org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'ldapTemplate' defined in class path resource [applicationContext-infrastructure.xml]: Cannot resolve reference to bean 'ldapContextSource' while setting constructor argument; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'ldapContextSource' defined in class path resource [applicationContext-infrastructure.xml]: Instantiation of bean failed; nested exception is java.lang.NoClassDefFoundError: com.sun.jndi.ldap.ctl.ResponseControlFactory
    Caused by: org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'ldapContextSource' defined in class path resource [applicationContext-infrastructure.xml]: Instantiation of bean failed; nested exception is java.lang.NoClassDefFoundError: com.sun.jndi.ldap.ctl.ResponseControlFactory
    Caused by: java.lang.NoClassDefFoundError: com.sun.jndi.ldap.ctl.ResponseControlFactory
    	at org.springframework.ldap.support.LdapContextSource.class$(LdapContextSource.java:42)
    	at org.springframework.ldap.support.LdapContextSource.<clinit>(LdapContextSource.java:42)
    	at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
    	at sun.reflect.NativeConstructorAccessorImpl.newInstance(Unknown Source)
    	at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(Unknown Source)
    	at java.lang.reflect.Constructor.newInstance(Unknown Source)
    Is there a new dependency?
    Thanks
    Alan

  • #2
    Yes, the support for Controls requires the LDAP Booster Pack, ldapbp.jar. It's included in the "with-dependencies" distribution, in the lib directory.

    Sorry for the inconvenience.

    Comment


    • #3
      Yes, the support for Controls requires the LDAP Booster Pack, ldapbp.jar. It's included in the "with-dependencies" distribution, in the lib directory.

      Sorry for the inconvenience.
      Thanks. Is there a maven group id or artifact id for this jar? I looked in the manifest of the jar and most of the packages start with com/sun/jndi ... There's nothing on the repo1.maven.org/maven2 site that I could find, so was just going to create my own
      Thanks
      Alan

      Comment


      • #4
        This jar is not publically available in any repos, at least not officially. I think it has something to do with licenses. You'd have to create your own repository artifact, just like we did:

        https://svn.sourceforge.net/svnroot/...ldapbp-1.0.jar

        The above URL is for our internal purposes only. There's no guarantee it will exist tomorrow (although it's very likely).

        Comment

        Working...
        X