Directory Studio
  1. Directory Studio
  2. DIRSTUDIO-865

NullPointerException thrown when connecting to Domino 8.5.2FP3 LDAP

    Details

      Description

      Connecting to a Domino 7.1 LDAP. I get the following:

      'Open Connection' has encountered a problem. Error while opening connection

      Error while opening connection
      java.lang.NullPointerException
      at org.apache.directory.studio.ldapbrowser.core.jobs.SearchRunnable.initFlags(SearchRunnable.java:707)
      at org.apache.directory.studio.ldapbrowser.core.jobs.SearchRunnable.searchAndUpdateModel(SearchRunnable.java:348)
      at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeRootDSERunnable.searchRootDseEntries(InitializeRootDSERunnable.java:414)
      at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeRootDSERunnable.loadRootDSE(InitializeRootDSERunnable.java:250)
      at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeAttributesRunnable.initializeAttributes(InitializeAttributesRunnable.java:226)
      at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeAttributesRunnable.initializeAttributes(InitializeAttributesRunnable.java:204)
      at org.apache.directory.studio.ldapbrowser.core.BrowserConnectionListener.openBrowserConnection(BrowserConnectionListener.java:117)
      at org.apache.directory.studio.ldapbrowser.core.BrowserConnectionListener.connectionOpened(BrowserConnectionListener.java:64)
      at org.apache.directory.studio.connection.core.jobs.OpenConnectionsRunnable.runNotification(OpenConnectionsRunnable.java:132)
      at org.apache.directory.studio.connection.core.jobs.StudioConnectionJob.run(StudioConnectionJob.java:115)
      at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

      java.lang.NullPointerException

        Activity

        Hide
        Brad Thurber added a comment -

        I've attached a Wireshark capture of where I believe the failure occurs. I'm hesitant to include the whole conversation as I'm not sure how to obfuscate the info.

        Show
        Brad Thurber added a comment - I've attached a Wireshark capture of where I believe the failure occurs. I'm hesitant to include the whole conversation as I'm not sure how to obfuscate the info.
        Hide
        Brad Thurber added a comment -

        Error occurs on 2.0M3 and latest nightly. I haven't tried other versions.

        Show
        Brad Thurber added a comment - Error occurs on 2.0M3 and latest nightly. I haven't tried other versions.
        Hide
        Emmanuel Lecharny added a comment -

        There is nothing wrong in the PDU you sent. It's a basic SearchRequest done on cn=schema, searching for ObjectClass only. The response is a SearchResultEntry which has 2 ObjectClasses (top and subschema) and a SearchResultDone with a success. There is no reason for Studio to produce a NPE when doing that... Unless you have a namingContext which is not valid in your RootDSE.

        Can you attach the Naming Context to this Jira ?

        (PS : we should not throw a NPE whatever the problem can be...)

        Show
        Emmanuel Lecharny added a comment - There is nothing wrong in the PDU you sent. It's a basic SearchRequest done on cn=schema, searching for ObjectClass only. The response is a SearchResultEntry which has 2 ObjectClasses (top and subschema) and a SearchResultDone with a success. There is no reason for Studio to produce a NPE when doing that... Unless you have a namingContext which is not valid in your RootDSE. Can you attach the Naming Context to this Jira ? (PS : we should not throw a NPE whatever the problem can be...)
        Hide
        Pierre-Arnaud Marcelot added a comment -

        Hi Brad,

        I just committed a potential fix for this.

        I'm going to build a version of Studio for you to verify the issue.

        Show
        Pierre-Arnaud Marcelot added a comment - Hi Brad, I just committed a potential fix for this. I'm going to build a version of Studio for you to verify the issue.
        Hide
        Brad Thurber added a comment -

        Correction: This is Domino v8.5.2FP3 - NOT v7.1

        I'll be glad to try the potential fix.

        Regarding namingContext, the closest thing I see to that is namingcontexts (note 's' on end). This is empty on Root DSE.

        Some further troubleshooting information for you. I switched the Provider on the Network Parameter tab from Apache Directory LDAP Client API to JNDI and was able to get past the initial error but then I encountered a new error:
        Error while opening connection

        • ERR_04196 Unexpected character '/' at position 12. Excpected start of attributeType descr.
          org.apache.directory.shared.ldap.model.exception.LdapInvalidDnException: ERR_04196 Unexpected character '/' at position 12. Excpected start of attributeType descr.

        Does this error warrant a new JIRA issue? Note also this misspelling of "Expected" in the error code.

        Show
        Brad Thurber added a comment - Correction: This is Domino v8.5.2FP3 - NOT v7.1 I'll be glad to try the potential fix. Regarding namingContext, the closest thing I see to that is namingcontexts (note 's' on end). This is empty on Root DSE. Some further troubleshooting information for you. I switched the Provider on the Network Parameter tab from Apache Directory LDAP Client API to JNDI and was able to get past the initial error but then I encountered a new error: Error while opening connection ERR_04196 Unexpected character '/' at position 12. Excpected start of attributeType descr. org.apache.directory.shared.ldap.model.exception.LdapInvalidDnException: ERR_04196 Unexpected character '/' at position 12. Excpected start of attributeType descr. Does this error warrant a new JIRA issue? Note also this misspelling of "Expected" in the error code.
        Hide
        Pierre-Arnaud Marcelot added a comment -

        The version is available here:
        http://people.apache.org/~pamarcelot/DIRSTUDIO-865/

        Could you give it a try? Thanks!

        Show
        Pierre-Arnaud Marcelot added a comment - The version is available here: http://people.apache.org/~pamarcelot/DIRSTUDIO-865/ Could you give it a try? Thanks!
        Hide
        Pierre-Arnaud Marcelot added a comment -

        Thanks for the correction on the version.

        Yeah, it's that empty 'namingcontexts' value which seem to cause issues with Studio.

        Yes please, open a new JIRA issue for the other error.

        Thanks!

        Show
        Pierre-Arnaud Marcelot added a comment - Thanks for the correction on the version. Yeah, it's that empty 'namingcontexts' value which seem to cause issues with Studio. Yes please, open a new JIRA issue for the other error. Thanks!
        Hide
        Brad Thurber added a comment -

        Test version fails as well, but fails sooner. New stack trace:

        Error while opening connection
        java.lang.NullPointerException
        at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeRootDSERunnable.searchRootDseEntries(InitializeRootDSERunnable.java:416)
        at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeRootDSERunnable.loadRootDSE(InitializeRootDSERunnable.java:250)
        at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeAttributesRunnable.initializeAttributes(InitializeAttributesRunnable.java:226)
        at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeAttributesRunnable.initializeAttributes(InitializeAttributesRunnable.java:204)
        at org.apache.directory.studio.ldapbrowser.core.BrowserConnectionListener.openBrowserConnection(BrowserConnectionListener.java:117)
        at org.apache.directory.studio.ldapbrowser.core.BrowserConnectionListener.connectionOpened(BrowserConnectionListener.java:64)
        at org.apache.directory.studio.connection.core.jobs.OpenConnectionsRunnable.runNotification(OpenConnectionsRunnable.java:132)
        at org.apache.directory.studio.connection.core.jobs.StudioConnectionJob.run(StudioConnectionJob.java:115)
        at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54)

        java.lang.NullPointerException

        Show
        Brad Thurber added a comment - Test version fails as well, but fails sooner. New stack trace: Error while opening connection java.lang.NullPointerException at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeRootDSERunnable.searchRootDseEntries(InitializeRootDSERunnable.java:416) at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeRootDSERunnable.loadRootDSE(InitializeRootDSERunnable.java:250) at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeAttributesRunnable.initializeAttributes(InitializeAttributesRunnable.java:226) at org.apache.directory.studio.ldapbrowser.core.jobs.InitializeAttributesRunnable.initializeAttributes(InitializeAttributesRunnable.java:204) at org.apache.directory.studio.ldapbrowser.core.BrowserConnectionListener.openBrowserConnection(BrowserConnectionListener.java:117) at org.apache.directory.studio.ldapbrowser.core.BrowserConnectionListener.connectionOpened(BrowserConnectionListener.java:64) at org.apache.directory.studio.connection.core.jobs.OpenConnectionsRunnable.runNotification(OpenConnectionsRunnable.java:132) at org.apache.directory.studio.connection.core.jobs.StudioConnectionJob.run(StudioConnectionJob.java:115) at org.eclipse.core.internal.jobs.Worker.run(Worker.java:54) java.lang.NullPointerException
        Hide
        Pierre-Arnaud Marcelot added a comment -

        Hi Brad,

        Sorry to get back to you so late.

        I've committed another potential fix.

        Could you give a try to this new snapshot version?
        http://people.apache.org/~pamarcelot/ApacheDirectoryStudio-win32-x86_64-2.0.0-SNAPSHOT.zip

        Thanks!

        Show
        Pierre-Arnaud Marcelot added a comment - Hi Brad, Sorry to get back to you so late. I've committed another potential fix. Could you give a try to this new snapshot version? http://people.apache.org/~pamarcelot/ApacheDirectoryStudio-win32-x86_64-2.0.0-SNAPSHOT.zip Thanks!
        Hide
        Brad Thurber added a comment -

        Hi,

        Tried new version. Seems to work well. I can now get connected and see the root of the directory tree - so I believe this ticket is solved.

        I still have separate issues when I start clicking around in the tree (for example Error while reading entry - ERR_04195 Unexpected character '*' at position 0. Excpected start of attributeType.) but these are clearly separate issues - and similar to DIRSTUDIO-866.

        Show
        Brad Thurber added a comment - Hi, Tried new version. Seems to work well. I can now get connected and see the root of the directory tree - so I believe this ticket is solved. I still have separate issues when I start clicking around in the tree (for example Error while reading entry - ERR_04195 Unexpected character '*' at position 0. Excpected start of attributeType.) but these are clearly separate issues - and similar to DIRSTUDIO-866 .
        Hide
        Pierre-Arnaud Marcelot added a comment -

        Thanks for the confirmation.

        Yeah, those other issues are related to invalid DNs returned by the directory server.
        I'm not sure we can do much about it, at the moment.

        I'm going to close this issue at least.

        Thanks!

        Show
        Pierre-Arnaud Marcelot added a comment - Thanks for the confirmation. Yeah, those other issues are related to invalid DNs returned by the directory server. I'm not sure we can do much about it, at the moment. I'm going to close this issue at least. Thanks!
        Hide
        Pierre-Arnaud Marcelot added a comment -

        Fixed at revisions 1439980 & 1459356.

        http://svn.apache.org/r1439980
        http://svn.apache.org/r1459356

        Show
        Pierre-Arnaud Marcelot added a comment - Fixed at revisions 1439980 & 1459356. http://svn.apache.org/r1439980 http://svn.apache.org/r1459356

          People

          • Assignee:
            Pierre-Arnaud Marcelot
            Reporter:
            Brad Thurber
          • Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development