CodeHulk
CodeHulk

Reputation: 111

Smart deployment of dll's in .net

We currently have an application that is roughly 22 megs total. Our current deployment methodology is deploying the application to each of our clients servers and using a small update program go and copy all of the files to the local pcs if a new version is available. The issue is that 22 megs is taking a bit more time than we would like to push updates. Especially since we do an update every 2 weeks. We are looking for a way to cut that time down.

Our initial thought was for the local pcs to only copy the dlls that have been changed since the last time we deployed. We are having some trouble with this as timestamps make it difficult to take accurate hashes of the file for comparisons. Versions numbers could possibly work ok, but we would have to find a way to only version a file if it's code has changed.

Just wondering if anybody has had success or recommendations for handling a similar process.

Upvotes: 4

Views: 370

Answers (3)

Will Dean
Will Dean

Reputation: 39500

We do a lot of pushing files internationally, to pieces of equipment we're working on remotely.

Our solution was to create a custom tool to do this (it actually does lots of other stuff), which does a sort of 'delta copy' - i.e. only pushes the parts of files which have changed.

That frees you from worrying about file timestamps, etc - the file you end up with at the far end is byte-for-byte identical to the near one, but if the only thing which as actually changed is an internal timestamp, then very little data will need to move across the wire.

We used an algorithm based roughly on the way rsync works ( http://samba.anu.edu.au/rsync/tech_report/ ), though we wrote it from scratch in C#.

However, in your situation, it might actually be that the effort of setting up rsync and a batchfile to invoke it with the right environment/options would be simpler. There is a Win32 version of rsync here: http://www.itefix.no/i2/node/10650 which I use successfully.

Upvotes: 3

Zesty
Zesty

Reputation: 2981

See if ClickOnce deployment will meet your needs.

Upvotes: 0

Steven Sudit
Steven Sudit

Reputation: 19620

Timestamps have no effect on hashes, but updating the version number would certainly change the hash.

Upvotes: 1

Related Questions