-
Notifications
You must be signed in to change notification settings - Fork 219
Retry extraction of bundle to avoid issues with locked files by AV #7135
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
640KB50s should be enough for everybody.
Seems to be a robust workaround. Even though it's in a platform-independent area, this shouldn't affect platforms where AV software is less common (which, coincidentally, are also platforms where files can be moved around even if some process have them open.)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
500 tries at 100ms seems reasonable, but may depend a lot on the size of the bundle and the load on the machine.
Address some memory leaks
50s is actually good, McAffee's default timeout for on-access scanning is 45s, so the files "should" be unlocked 45s after writing 🤞 |
The HostModel implements services for updating the AppHost DLL - Write App-dll name - Set GUI/CUI bit - Read/Write BundleHeader marker These updates involve multiple file open/close operations. An Antivirus scanner may intercept in-between and cause these operations to fail with IO-Error. So, this change adds a few retries to the IO operations, similar to dotnet#7135 Fix for #7597
The HostModel implements services for updating the AppHost DLL - Write App-dll name - Set GUI/CUI bit - Read/Write BundleHeader marker These updates involve multiple file open/close operations. An Antivirus scanner may intercept in-between and cause these operations to fail with IO-Error. So, this change adds a few retries to the IO operations, similar to dotnet#7135 Fix for #7597
The HostModel implements services for updating the AppHost DLL - Write App-dll name - Set GUI/CUI bit - Read/Write BundleHeader marker These updates involve multiple file open/close operations. An Antivirus scanner may intercept in-between and cause these operations to fail with IO-Error. So, this change adds a few retries to the IO operations, similar to dotnet#7135 Fix for #7597
The HostModel implements services for updating the AppHost DLL - Write App-dll name - Set GUI/CUI bit - Read/Write BundleHeader marker These updates involve multiple file open/close operations. An Antivirus scanner may intercept in-between and cause these operations to fail with IO-Error. So, this change adds a few retries to the IO operations, similar to dotnet#7135 Fix for #7597
The HostModel implements services for updating the AppHost DLL - Write App-dll name - Set GUI/CUI bit - Read/Write BundleHeader marker These updates involve multiple file open/close operations. An Antivirus scanner may intercept in-between and cause these operations to fail with IO-Error. So, this change adds a few retries to the IO operations, similar to dotnet#7135 Fix for #7597
The HostModel implements services for updating the AppHost DLL - Write App-dll name - Set GUI/CUI bit - Read/Write BundleHeader marker These updates involve multiple file open/close operations. An Antivirus scanner may intercept in-between and cause these operations to fail with IO-Error. So, this change adds a few retries to the IO operations, similar to dotnet#7135 Fix for #7597
* HostModel: Retry updates on IO error The HostModel implements services for updating the AppHost DLL - Write App-dll name - Set GUI/CUI bit - Read/Write BundleHeader marker These updates involve multiple file open/close operations. An Antivirus scanner may intercept in-between and cause these operations to fail with IO-Error. So, this change adds a few retries to the IO operations, similar to #7135 Fix for #7597
* HostModel: Retry updates on IO error The HostModel implements services for updating the AppHost DLL - Write App-dll name - Set GUI/CUI bit - Read/Write BundleHeader marker These updates involve multiple file open/close operations. An Antivirus scanner may intercept in-between and cause these operations to fail with IO-Error. So, this change adds a few retries to the IO operations, similar to dotnet#7135 Fix for #7597
* HostModel: Retry updates on IO error (#7617) The HostModel implements services for updating the AppHost DLL - Write App-dll name - Set GUI/CUI bit - Read/Write BundleHeader marker These updates involve multiple file open/close operations. An Antivirus scanner may intercept in-between and cause these operations to fail with IO-Error. So, this change adds a few retries to the IO operations, similar to #7135 On Win32 PE files, the SDK copies resources on the AppHost binary from the intermediate assembly. This update is performed using native Win32 operations. This change also adds retries to the resource update, if the operation fails because the file is locked (say because of AntiVirus scan). The Retry logic is factored out to the RetryUtil class. Currently the HostWriter is the only client for the class. But it is made public because other components (like Bundler) may use it in future.
…otnet/core-setup#7135) Retry extraction of bundle to avoid issues with locked files by AV software Address some memory leaks Commit migrated from dotnet/core-setup@552dba1
* HostModel: Retry updates on IO error The HostModel implements services for updating the AppHost DLL - Write App-dll name - Set GUI/CUI bit - Read/Write BundleHeader marker These updates involve multiple file open/close operations. An Antivirus scanner may intercept in-between and cause these operations to fail with IO-Error. So, this change adds a few retries to the IO operations, similar to dotnet/core-setup#7135 Fix for dotnet/core-setup#7597 Commit migrated from dotnet/core-setup@f19be99
Fixes https://github.com/dotnet/core-setup/issues/7070