-
-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Causing aroung 800ms delay between version 3.2.0 and 3.3.0 #16
Comments
SideNote: |
Hmmm, weird. @Deepanshu2017 could you try and change the order of the powershell and wmic command? |
@landsfiskalen But the thing is, I really don't know if I can do that in your code and push the deployment since it was on the Azure function app. The confirmed thing is, changing from 3.3.0 to 3.2.0 made resolved everything. |
One thing I can try is, try to run the 3.3.0 and 3.2.0 on my local system and check if I can replicate the issue on local. |
That would be great if you could! |
The scenario -
I had a production system running on Cosmos NodeJS package (version 3.6.2) and recently I made some changes and tried to deploy the new code over the production. I started to see the latency of around 800ms in cosmos DB insertion call. The cosmos DB package version was the same so the issue was in one of the dependency. I manually checked each and every package on which Cosmos DB and it's dependencies are dependent on (trust I checked a lot of code and releases) and could drill down to the specific version which is causing the issue.
The Windows-release package version 3.3.0 is causing the Cosmos to delay the result by 800ms to 1000ms. While with Windows-release package version 3.2.0 Cosmos DB doesn't show this much of delay. (Given that everything in the system was constant and every other factor which might impact the results had been eliminated).
When comparing Windows-release 3.3.0 with Windows-release 3.2.0, I found that the only part in the code that has been changed is the below snippet
windows-release/index.js
Lines 36 to 40 in 39b78e7
Basically Windows-release moved from
wmic
to usePowerShell
by default in this commit and in casePowerShell
fails, fallback towmic
and I suspect that due to this fallback and changing default fromwmic
toPowerShell
is causing the delay.The text was updated successfully, but these errors were encountered: