Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

LDAP-118: Java 6: NoClassDefFoundError: com.sun.jndi.ldap.ctl.PagedResultsResponseControl #157

Closed
spring-projects-issues opened this issue Jun 23, 2008 · 2 comments
Milestone

Comments

@spring-projects-issues
Copy link

Damian Gołda(Migrated from LDAP-118) said:

While creating new instance PagedResultsRequestControl I’ve got:

java.lang.NoClassDefFoundError: com.sun.jndi.ldap.ctl.PagedResultsResponseControl
at org.springframework.ldap.control.PagedResultsRequestControl.class$(PagedResultsRequestControl.java:42)
at org.springframework.ldap.control.PagedResultsRequestControl.(PagedResultsRequestControl.java:42)

The reason is line:

```
private static final Class DEFAULT_RESPONSE_CONTROL = PagedResultsResponseControl.class;
```

On Java 6 (and probably 5) I cannot find com.sun.jndi.ldap.ctl.PagedResultsResponseControl – but there is javax.naming.ldap.PagedResultsResponseControl.

I’ve changed PagedResultsRequestControl to use javax.naming.ldap.PagedResultsResponseControl and it works fine for me but it’s only Java 5 compatible…

@spring-projects-issues
Copy link
Author

Mattias Hellborg Arthursson said:

This can be solved by adding the ldapbp.jar library to the classpath. Either way the hard reference should be removed, so I’m planning this for the upcoming release.

@spring-projects-issues
Copy link
Author

Mattias Hellborg Arthursson said:

Now removed all explicit dependencies on any of the control classes and defaulting to the Java5 classes. If the Java5 classes are not available we will try to fallback to the Booster Pack stuff.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant