Solved

Solution for Installing and the updating an application similar to how ClickOnce Works

Posted on 2012-04-02
5
696 Views
Last Modified: 2012-04-08
I'm building a client/server application. I'm looking for a solution to distribute both the client and server applications. Whatever I end up doing must include an update service along the same lines as ClickOnce updates.

Basically I have 45-50 sites where the server application will be installed and there will be fairly frequent updates to both the server and client side applications. I'm happy enough using clickonce for the client side application. In fact that makes perfect sense as many of the users won't have admin rights.

But ClickOnce will not be suitable for the server side application as it will need to be installed into a specified folder on a server and the installer will need admin rights.

Is there anything out there that provides ClickOnce type update/installation functionality but with MSI like installation? The ability to do Automatic updating from a folder on a website would be ideal.

I have access to all the latest MS development products.
I'm currently using VS 2010 but would consider VS 11 if there is something worth looking at.
Happy enough to pay for a product as long as it's not unreasonably expensive.
Would consider code based solution if one exists.
0
Comment
Question by:shanejh
  • 2
  • 2
5 Comments
 
LVL 53

Accepted Solution

by:
Dhaest earned 250 total points
ID: 37799420
0
 
LVL 40

Assisted Solution

by:Jacques Bourgeois (James Burger)
Jacques Bourgeois (James Burger) earned 250 total points
ID: 37801862
Since .NET components do not need to be registered, after the initial installation, many applications require only a file copy to be updated.

It depends on the structure of the application, and whether it is entirely .NET or not, but before ClickOnce, I used a very simple update system for one of my customers that is still working after many years in production. I have known of a few programmers who also used a similar system. This scenario is easier to work with if you design your application so that all the required dlls are installed in the same directory as the application.

The application was not started as such. The user never knew, but when they thought they were starting the application, they were starting an updater. We had with the application a simple text file that contained only the version number. The updater compared that file in the installation directory with the same one on the distribution server and could thus detect that a new version was available. If not, it simply launched the application. Otherwise it simply ran a simple application on the server that made a copy of all the files that needed to be changed.

I understand that you want something that works with a server that might be running full time, so you could not check at launch because you might not launch the server often. You could have a timer running in the background that would make the comparison between both files at regular intervals and detects that a new version is available. It would then trigger an update.

The way to update a server can be different depending on the way the server application is used and accessed.

If the server is called only for short operations, you could simply turn it off, update and turn it back on. The client application could detect that the server is updating and send a waiting message to the user. Unless your server application is huge, copying a few files should not take that long.

If the server cannot be shut down while in use, you would need something else. Applications would connect to the server through some mechanism that would give them the current location of the server. You would work with 2 directories, one for the current server and one for the new updated version. Applications that are already connected could continue working on the current server while you are copying the updated one into the adjacent directory. Once the application is updated, you adjust the connection mechanism so that it points to the new location. Applications already running will still use the old server until they are shut down, but will be redirected to the new one when relaunched.

If you often release a simultaneous update of both the server and the client, then you have to make sure that the servers are updated before the client. Just make sure that the timer you used to trigger the server update is set to a short interval, and always update the distribution server with the server application updates a few minutes before you do so with the client application.

Naturally, there could be many variations of these scenarios. But due to the fact that .NET applications and dlls do not need to be registered to work together, it is quite easy to implement your personal version of ClickOnce.

There is also a System.Configuration.Install.Installer class in the framework that you might want to explore.
0
 
LVL 2

Assisted Solution

by:shanejh
shanejh earned 0 total points
ID: 37803718
Thanks for the responses. Definitely helpful.

They have made me realize that I just needed to be looking for the right thing, Auto Update Frameworks.

I have found the following:


I like the look of wyUpdate at this stage. It seems like managing updates would be fairly easy with it and although you need to pay for it the source code is available as it is open source. They provide some nice code examples too.

Are there any other update frameworks out there? Again I don't care to pay for a good solution.
0
 
LVL 53

Expert Comment

by:Dhaest
ID: 37804484
You can close the question by yourself
0
 
LVL 2

Author Closing Comment

by:shanejh
ID: 37820935
All comments lead to my final solution. Depending on what you are after all the information above is relevant.
0

Featured Post

Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

Join & Write a Comment

Introduction Hi all and welcome to my first article on Experts Exchange. A while ago, someone asked me if i could do some tutorials on object oriented programming. I decided to do them on C#. Now you may ask me, why's that? Well, one of the re…
For those of you who don't follow the news, or just happen to live under rocks, Microsoft Research released a beta SDK (http://www.microsoft.com/en-us/download/details.aspx?id=27876) for the Xbox 360 Kinect. If you don't know what a Kinect is (http:…
This is Part 3 in a 3-part series on Experts Exchange to discuss error handling in VBA code written for Excel. Part 1 of this series discussed basic error handling code using VBA. http://www.experts-exchange.com/videos/1478/Excel-Error-Handlin…
This demo shows you how to set up the containerized NetScaler CPX with NetScaler Management and Analytics System in a non-routable Mesos/Marathon environment for use with Micro-Services applications.

760 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now