dotnet/runtime

Principal.FindByIdentity() method is extremely slow

オープン

#34,598 opened on 2020/04/06

 (10 件のコメント) (0 件のリアクション) (1 人の担当者)C# (5,445 件のフォーク)batch import
area-System.DirectoryServiceshelp wantedtenet-performance

Repository metrics

Stars
 (17,886 個のスター)
PR merge metrics
 (平均マージ 12d 11h) (30d で 661 merged PRs)

説明

In PowerShell repo we started porting Microsoft.PowerShell.LocalAccounts module to System.DirectoryServices.AccountManagement API (from p/invokes). We had to use workarounds because Principal.FindByIdentity() methods is extremely slow - up to 100x(!) vs Principal.PrincipalSearcher().

On my notebook Get-LocalUser name ported cmdlet takes 2.8 sec(!) vs 25 ms if a workaround is used.

コントリビューターガイド