Answer the question
In order to leave comments, you need to log in
What is the best way to implement automatic program updates in Delphi?
There were many ideas while it is worth updating through the site. That is, when the software is turned on, it checks the version, if the old version issues messages and downloads a new file from the site.
I wonder if there are any libraries for working with this in the search, I found WinSparkle, but as such I did not find an example of use specifically for Delphi.
Or tell me how you update your software, or what ideas you have.
Perhaps through a php script or otherwise.
Answer the question
In order to leave comments, you need to log in
The best way is using your site. Do not worry right away and do the office. software page for free hosting and use the TXT file in which the values (versions) will change. If the software version does not match the TXT content, update it. And use FTP to download updates, etc. do not use stupid solutions. The beam immediately has one link that will always be the same, regardless of whether the version has changed or not. (Example: site.ru/update/soft.exe), and your software will rename it as it should.
1) Use only HTTP and HTTPS, because 50% of your users are behind a proxy. HTTPS also removes
a lot of issues with the integrity of the updated code.
2) Please note that the user is not always an admin on his PC and, for good reason, does not have write access to the folder where the binaries are located, or may not have. Different software solves this problem in different ways (I consider the option to place the modified part of the binaries in the user's personal profile not serious, although some well-known manufacturers do not disdain this either) - many install an update service once, which has system privileges and periodically checks the installed version with the one posted on the site . It is good practice to implement a minimalistic management utility for this service in order to at least be able to control its behavior.
3) After 1000 active users, you will really want to a) distribute the update process over time to reduce the load; b) test the changes made not on all users at once, but on some part, for example, by 100 or 5%. From this we come to the conclusion that a static text file on the update server is not the best solution, after all, it should be a script (returning the recommended version for the client depending on its ID) that can be dynamically controlled (for example, increase or decrease the share of testers , or submit a new version for testing only for a certain group that satisfies some conditions).
4) Well, you may want to limit interaction with the version server below a certain one. But this is usually implemented in a client-server exchange protocol. Another thing is that in a good way, after the server refuses to connect due to a too old version of the software, it should be able to "push" the update service to an emergency update.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question