Skip to content

Commit

Permalink
dont connect ldap on startup
Browse files Browse the repository at this point in the history
Signed-off-by: jkoberg <jkoberg@owncloud.com>
  • Loading branch information
kobergj committed Jun 21, 2023
1 parent 70b64d8 commit eb9d2bc
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 4 deletions.
5 changes: 5 additions & 0 deletions changelog/unreleased/dont-connect-ldap-on-startup.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
Bugfix: Don't connect to ldap on startup

This leads to misleading error messages. Instead we connect on first request

https://github.com/owncloud/ocis/pull/6565
8 changes: 4 additions & 4 deletions services/graph/pkg/identity/ldap/reconnect.go
Original file line number Diff line number Diff line change
Expand Up @@ -205,10 +205,10 @@ func (c ConnWithReconnect) GetConnection() (*ldap.Conn, error) {
}

func (c ConnWithReconnect) ldapAutoConnect(config Config) {
l, err := c.ldapConnect(config)
if err != nil {
c.logger.Error().Err(err).Msg("autoconnect could not get ldap Connection")
}
var (
l *ldap.Conn
err error
)

for {
select {
Expand Down

0 comments on commit eb9d2bc

Please sign in to comment.