Issue Details (XML | Word | Printable)

Key: GLDP-62
Type: Bug Bug
Status: Resolved Resolved
Resolution: Not A Bug
Priority: Blocker Blocker
Assignee: Luke Daley
Reporter: Jeremy Daggett
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
Gldapo

LDAP Searches throwing NPE

Created: 12/May/08 11:45 PM   Updated: 14/May/08 05:15 AM
Component/s: None
Affects Version/s: 0.6
Fix Version/s: 0.6

Time Tracking:
Not Specified

File Attachments: 1. File myLDAP.groovy (1 kB)

Environment: Windows XP SP2
Java 1.5.0_14
Groovy 1.5.6
GLDAPO-SNAPSHOT-0.6
Eclipse 3.3.2 with Groovy Plugins
Issue Links:
Related
 


 Description  « Hide
Enclosed script exhibits NPE in search methods at gldapo.GldapoDirectory.search(GldapoDirectory.groovy:141):

May 12, 2008 9:37:51 PM org.springframework.ldap.core.support.AbstractContextSource afterPropertiesSet
INFO: Property 'userDn' not set - anonymous context will be used for read-write operations
gldapo.Gldapo@11a75a2
Exception in thread "main" java.lang.NullPointerException
at org.codehaus.groovy.runtime.InvokerHelper.getProperty(InvokerHelper.java:178)
at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.getProperty(ScriptBytecodeAdapter.java:474)
at gldapo.GldapoDirectory.search(GldapoDirectory.groovy:141)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:95)
at org.codehaus.groovy.runtime.MetaClassHelper.doMethodInvoke(MetaClassHelper.java:599)
at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:904)
at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:740)
at org.codehaus.groovy.runtime.InvokerHelper.invokePogoMethod(InvokerHelper.java:773)
at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:753)
at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodN(ScriptBytecodeAdapter.java:167)
at gldapo.schema.GldapoSchemaClassInjecto$_clinit_closure31.doCall(GldapoSchemaClassInjecto.groovy:298)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.groovy.reflection.CachedMethod.invoke(CachedMethod.java:95)
at org.codehaus.groovy.runtime.MetaClassHelper.doMethodInvoke(MetaClassHelper.java:599)
at org.codehaus.groovy.runtime.metaclass.ClosureMetaClass.invokeMethod(ClosureMetaClass.java:252)
at groovy.lang.MetaClassImpl.invokeMethod(MetaClassImpl.java:740)
at groovy.lang.Closure.call(Closure.java:292)
at org.codehaus.groovy.runtime.metaclass.ClosureStaticMetaMethod.invoke(ClosureStaticMetaMethod.java:55)
at org.codehaus.groovy.runtime.MetaClassHelper.doMethodInvoke(MetaClassHelper.java:599)
at groovy.lang.MetaClassImpl.invokeStaticMethod(MetaClassImpl.java:1077)
at groovy.lang.ExpandoMetaClass.invokeStaticMethod(ExpandoMetaClass.java:958)
at org.codehaus.groovy.runtime.InvokerHelper.invokeMethod(InvokerHelper.java:744)
at org.codehaus.groovy.runtime.ScriptBytecodeAdapter.invokeMethodN(ScriptBytecodeAdapter.java:167)
at myLDAP.main(myLDAP.groovy:29)



 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Luke Daley added a comment - 13/May/08 06:25 AM
I can reproduce this on Groovy 1.5.4, but not 1.5.5 or 1.5.6.

Would it be possible that Eclipse is somehow using Groovy 1.5.4?

I am trying to get details of the change from the Groovy devs for more information. In the meantime, can you please verify that you are indeed running with >= 1.5.5.


Luke Daley added a comment - 13/May/08 06:28 AM
This is definitely related to the change in r158

Luke Daley added a comment - 14/May/08 05:15 AM
This appears to be the symptom of Gldapo now requiring Groovy 1.5.5 or greater. I have created a separate issue to update the documentation to reflect this.