You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In Helper.cs, the function GetCommandInfo checks the commandInfoCache for a given command, and - if it does not exist in the cache - retrieves the info from a powershell session. Unlike in the deprecated function GetCommandInfoLegacy, however the command info is never added to the commandInfoCache dictionary. (Compare lines 750 and 776)
I'd like to open a PR to correct this, assuming this is indeed a bug.
This should help marginally with performance issues due to contentions from the locks in the GetCommandInfo and GetCommandInfoLegacy functions.
The text was updated successfully, but these errors were encountered:
@Blackbaud-ShaydeNofziger PR #953 already attempted to fix this but we struggled due to concurrency/locking bugs in the existing code base.
This new-ish method was being added for a new function where we could not populate the cache due to those bugs.
We would appreciate it if you can come up with a solution where all tests still pass. Feel free to open a WIP PR so that you get test results against all systems to allow you to get easy and quick feedback but from my experience just getting it in Windows PowerShell 5.1 to work was hard enough and it seemed that resolving the locking issues (locks are being held too long and in inappropriate places) would probably help tackle this issue.
@bergmeister Agreed that the locking issues are the primary hiccup here. Apologies for not seeing the existing PR. I would really like to help address the locking issues, so I'll dig into that.
Awesome, thanks, we really appreciate your help. Those concurrency issues in PSSA are really bad as they can also lead to sporadic failures (that I have even seen myself in the CI pipeline that I maintain at work)
In
Helper.cs
, the functionGetCommandInfo
checks the commandInfoCache for a given command, and - if it does not exist in the cache - retrieves the info from a powershell session. Unlike in the deprecated functionGetCommandInfoLegacy
, however the command info is never added to the commandInfoCache dictionary. (Compare lines 750 and 776)I'd like to open a PR to correct this, assuming this is indeed a bug.
This should help marginally with performance issues due to contentions from the locks in the
GetCommandInfo
andGetCommandInfoLegacy
functions.The text was updated successfully, but these errors were encountered: