.net - Windows Service user.config lost by Win10 update -


i have .net windows service uses user-scope settings. since windows service running under system account corresponding user.config file not stored usual at:

c:\users\{user name}\appdata\roaming\{company name}\{assembly name}_url_{hash}\{assembly version} 

but instead at:

c:\windows\syswow64\config\systemprofile\appdata\local\{company name}\{assembly name}_url_{hash}\{assembly version} 

as turns out, @ windows 10 upgrade (in case 1703 creators update), whole folder c:\windows\ copied/moved c:\windows.old\.

with user.config file being moved (not copied) c:\windows.old , therefore not being detected anymore service. consequence, service automatically fall default settings, causing problems customers.

i knowingly chose user-scope settings when first developed service, because changing settings @ run time (via system tray app communicating via inter-process communication service). has been working fine years now. under windows 10 making troubles.

so questions are:

  • is there practical workaround problem? maybe way tell windows make sure user.config file stays @ original location?
  • or there better strategy storing editable settings windows service?

please note in case service in use , love stick nice , handy configurationmanager settings vs integration. other approach, simple serializable settings class, require kind of transition mechanism keeping customers current settings alive. , know coding custom settingsprovider challenging task.


Comments

Popular posts from this blog

angular - Ionic slides - dynamically add slides before and after -

minify - Minimizing css files -

Add a dynamic header in angular 2 http provider -