Search code examples
client-sideauto-update

Best Practices for Self Updating Desktop Application in a network environment


I have searched through google and SO for possible answers to this question, but can only find small bits of information scattered around the place, most of which appear to be personal opinion.

I'm aware that this question could be considered subjective, but I'm not looking for personal opinion, rather facts with reasons (e.g. past experience) or even a single link to a blog/wiki which describes best practices for this (this is what I'd prefer to be honest). What I'm not looking for is how to make this work, I know how to create a self updating desktop application.

I want to know about the best practices for creating a self updating desktop application. The sort of best practices I'm especially curious about are:

  • Do you force an update if the clients software is out of date, but not going to break when trying to communicate with other version of the software or the database itself? If so how do you signify this breaking change?
  • How often should you check for updates? Weekly/daily/hourly and exactly why?
  • Should the update be visible to the user or run behind the scenes from a UI point of view?
  • Should you even notify the user that there is an update available if it is not a major update? (for instance fixing a single button in a remote part of the application which only one user actually requires)
  • Should you try to patch the application or do you re-download the entire application from scratch Macintosh style?
  • Should you allow users to update from a central location or only allow updating through the specified application? (for closed business applications).

Surely there is some written rules/suggestions about this stuff? One of the most annoying things about a lot of applications is the updating, as it's hard to find a good balance between "out of date" and "in the users face".

If it helps consider this to be written in .net C# for a single client, running on machines with constant available connectivity to the update server, all of these machines talk to each other through the application, and all also talk to a central database server.


Solution

  • It's hard to give a general answer. It depends on the context: criticality of the update, what kind of app is it, user preferences, #users, network width, etc. Here are some of the options/trade-offs.

    • Do you force an update if the clients software is out of date, but not going to break when trying to communicate with other version of the software or the database itself? If so how do you signify this breaking change?

      As a developer your best interest is to have all apps out there to be as up to date as possible. This reduces your maintenance effort. Thus, if the user does not mind you should update.

    • How often should you check for updates? Weekly/daily/hourly and exactly why?

      If the updates are transparent to the user, do not require an immediate restart of the app, then I'd suggest that you do it as often as your the communication bandwidth allows (considering both the update check-frequent but small-and the download-infrequent but large)

    • Should the update be visible to the user or run behind the scenes from a UI point of view?

      Depends on the user preferences but also on the type of the update: bug fixes vs. functionality/UI changes (the user will be puzzled to see the look and feel has changed with no previous alert)

    • Should you even notify the user that there is an update available if it is not a major update? (for instance fixing a single button in a remote part of the application which only one user actually requires)

      same arguments as the previous question

    • Should you try to patch the application or do you re-download the entire application from scratch Macintosh style?

      if app size is small download it from scratch. This will prevent all sort of weird bugs created to mismatch between the different patches ("DLL hell"). However, this may require large download times or impose heavy toll on your network.

    • Should you allow users to update from a central location or only allow updating through the specified application? (for closed business applications).

      I think both