question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Binding only works sometimes

See original GitHub issue

Binding fails ~9/10 times. Not sure if I am improperly using the node-ldapjs client, or if there is a problem with the server I am connecting to.

My code:

var client = ldap.createClient({
  url: 'ldap://main.ad.rit.edu',
});    

client.bind(credentials.username, credentials.password, function (err) {
  if (err) {
    console.log("[ERROR] when binding:");
    console.log(err, err.dn, err.code, err.name, err.message);
  } else {
    ...
  }
}

Output (on failure case):

[ERROR] when binding:
{ [ConnectionError: ldap://main.ad.rit.edu closed]
  dn: [Getter],
  code: [Getter],
  name: [Getter],
  message: [Getter] } '' 128 'ConnectionError' 'ldap://main.ad.rit.edu closed'

Otherwise, when it succeeds, I can run queries and the client functions as expected.

Issue Analytics

  • State:closed
  • Created 9 years ago
  • Comments:9 (2 by maintainers)

github_iconTop GitHub Comments

1reaction
petermikitshcommented, Sep 3, 2017

@bhshkh As stated before, it’s likely an issue with the LDAP server you are connecting to and not the node-ldapjs client.

0reactions
bhshkhcommented, Sep 3, 2017

Any update on how to resolve this?

Read more comments on GitHub >

github_iconTop Results From Across the Web

WPF Binding works only once - MSDN - Microsoft
I've created a Binding with converter, but it updates target only once - when it is setted. I've try to change modes, access...
Read more >
Binding sometimes fails, depending on position of {Binding} in ...
I suppose it does not work because when you write {Binding} , the context of the data to be bound is inherited from...
Read more >
Modbus binding only works sometimes (CRC error)
I'm a modbus noob and currently trying to get a simple test-setup running. I just want to control the onboard LED (Pin 13)...
Read more >
Debugging data bindings - The complete WPF tutorial
Since data bindings are evaluated at runtime, and no exceptions are thrown when they fail, a bad binding can sometimes be very hard...
Read more >
WinUI 3 Desktop - Binding does not work · Issue #2630 - GitHub
After the NestedViewModel property was initialized, only the button with x:Bind and Mode=OneWay can be executed. Bindings.zip. Hopefully this ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found