Skip to content

Fix BeginSendRequest and EndSendRequest on LdapConnection#37774

Merged
joperezr merged 5 commits intomasterfrom
LdapConnectionAsync
Jun 12, 2020
Merged

Fix BeginSendRequest and EndSendRequest on LdapConnection#37774
joperezr merged 5 commits intomasterfrom
LdapConnectionAsync

Conversation

@joperezr
Copy link
Copy Markdown
Member

Fixes: #36690

cc: @tarekgh @stephentoub

LdapConnection had Async APM methods that never really worked in .NET Core as they were using Delegate.BeginInvoke and Delegate.EndInvoke which are not supported in .NET Core. These changes will make it so that they don't use that anymore and instead use Tasks and polling in order to not block a thread in the threadpool.

FYI: @blowdart @Tratcher @JunTaoLuo

@joperezr
Copy link
Copy Markdown
Member Author

Unfortunately the APM async methods can't be easily tested with our UnitTests without using an actual LDAP server, but I have ran them locally against one in all Windows, Linux and OSX and they all work now using APM methods.

@joperezr joperezr merged commit 0a42ca9 into master Jun 12, 2020
@joperezr joperezr deleted the LdapConnectionAsync branch June 12, 2020 15:40
@joperezr
Copy link
Copy Markdown
Member Author

Merging since the two test runs that are timing out are unrelated to this PR.

Thanks for the help with this @stephentoub

@ghost ghost locked as resolved and limited conversation to collaborators Dec 8, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

LdapConnection.BeginSendRequest uses defunct Delegate.BeginInvoke

3 participants