Version Control System
A version control system provides versions of not just the software but also of all the documents. Even if a software project consists of just one person, it is always healthy to maintain a version control system. It is good to maintain versions not just for the backup but also because it is easy to revert back changes by selecting any previous version that we want. Popular version control systems are CVS, SVN, VSS. A version control system also provides a method of creating branches, so that we can have development on one branch which we set as the stable version. And we can have a bug fixing branch where we fix bugs. Later once most of the bugs are fixed, we can merge the bug fixes into the stable branch.
Unit Test Framework
Following the concept of test driven development, one part of testing which is under the control of developers is unit testing. Ideally, unit tests should be written along with (or perhaps even before) the implementation. A particular tried and tested unit testing framework such as CUnit can be used. Many of us as developers tend to ignore unit testing and are satisfied by random testing of the system that we create. This is definitely an invitation for letting off unnecessary bugs which will come back far later in the project to haunt us.
Automated Build System
It should be possible to have in addition to manual builds, an automated build system which is triggered by certain events such as nightly builds, change in critical files, etc. An automated build system can help detect a break in the system early. Reports can be generated automatically and sent to the concerned personnel by email. Automated build systems can be created using scripting languages such as perl or python.
Automated Test Framework
One of the most important tools in a software project is the automated test framework. Ideally, the automated tests should be run after every nightly build has successfully completed. As with the build, the test reports if any failure can be generated automatically and sent by email. Automated Test frameworks may be specific to projects.
Task/Defect tracking system
Most useful when the project consists of several members. More so if the members are geographically distributed. A task management system helps to assign tasks, prioritize tasks, set the percentage completed. Charts can be generated to analyse the work done in the project. Microsoft Project is an example of task management or rather project management. A defect tracking system is useful for developers and testers to report bugs, track the progress of fixing those bugs and to analyse the overall defects in the system. Bugzilla, Jira are examples of defect tracking systems.
Wiki/site
Maintain a wiki, website or blog about your project. This can contain the project milestones that are set and achieved. Also information such as project presentations can be added. This can be used not just for team clarity in project achievements but also as a front end for management whenever they need a gist or status of the project.
| > | Sends output to a named file. If file does not exist, it creates one. Overwrites existing file | command > somefile |
| >> | Appends output to contents of a named file or creates a file if none exists | command >> somefile |
| < | Uses contents of a named file as input to a command | command < somefile |
| ¦ | Sends (”pipes”) the output of command1 to the input of command2 | command1 ¦ command2 |
| & | Used to combine two commands. Executes command1 and then command2 | command1 & command2 |
| && | A conditional combination. Executes command2 if command1 completes successfully | command1 && command2 |
| ¦¦ | Command2 executes only if command1 does not complete successfully. | command1 ¦¦ command2 |
| @ | Used in batch files at the beginning of a line to turn off the display of commands | @echo off |
Interesting article about writing highly available code:
Reliability Features of the .NET Framework
This article discusses:
* Understanding OutOfMemoryException, StackOverflowException, and ThreadAbortException
* Constrained Execution Regions
* Critical Finalizers and SafeHandle
* FailFast and MemoryGates
Did you know that Windows 7 has a GodMode? What GodMode does is enable you to have a place where you can get to all the settings without having to browse around and click through options and folders in control panel.
Add a new folder to your desktop and name it GodMode.{ED7BA470-8E54-465E-825C-99712043E01C}
Now when you click on that icon you it will open up the following folder…
Warning…although GodMode works on Vista 32 bit and 32 bit Windows Server 2008 it does not work on Vista 64 bit sp2 and 64 bit Windows Server 2008…
You’ve probably heard statistics about the “high cost of losing a customer.” The theory is simple and true (fact?): keeping existing customers and repeat business is much more profitable than attracting new customers. Here are a few facts from BusinessCoach.com:
- For every customer who bothers to complain, there are 26 others who remain silent.
- The average “wronged” customer will tell 8 to 16 people.
- 91% of unhappy customers will never purchase services from you again.
- It costs about five times as much to attract a new customer as it costs to keep an old one.
- Each one of your customers has a circle of influence of 250 people or potential customers who hear bad things about you!
The point of this post is simple: RETAIN YOUR GOOD DEVELOPERS. Getting someone up to speed on a legacy codebase takes a long time and is an expensive undertaking. A large part of the software coach’s or manager’s job is attracting, developing and keeping talent. And that talent becomes more valuable over time.
Yes, you might be able to replace someone at a lower annual salary, but you have to take into account the complexity of your code portfolio in how long it’ll take to make that person productive. A $60K/annum employee may very well take $120K before reaching the productivity level and contribution of the developer who left the team.
Also, the big red warning sign when you get rid of a developer for cost reasons is the hidden investment. You may be paying that developer 30K, but you’ve also spent (hopefully) on training and many other costs that are not as visible. This is investment and should be considered the same as investment in plant. When the developer disappears, so does that investment.
If you have more than one Skype account – say one for business and another for personal use – you can run two Skype applications at the same time! Provided you have Skype version 4 or better. The following “tip” applies only to Windows…
Step 1: Go to the location to where you installed Skype. For example:
C:\Program Files\Skype\Phone
Step 2: Right-click on the Skype.exe icon and select “Send to” -> “Desktop (as shortcut)” to create a new shortcut to it on your Desktop.
Step 3: Now go to your Desktop and right-click on the newly created shortcut. Select “Properties”.
Step 4: Append the following to the “Target:” text field without changing the existing text:
/secondary
Enjoy
[Conditional("DEBUG")]
void Foo() {
}
The advantage here is that the code is not reachable anymore if the condition is not met. This means that it will result in compile errors if you reference this method. #if … #endif does not enforce this constraint.
When using Http, proxy configuration madness is a fact of life. If misconfigured, you can wind up trying to decipher obtuse 502 (Bad Gateway) and 504 (Gateway Timeout) errors.
Fortunately there are a number of binding settings available in WCF to control your Http proxy usage. These settings are available directly on BasicHttpBinding and WsHttpBinding (as well as on HttpTransportBindingElement when you are using a CustomBinding).
* public bool UseDefaultWebProxy (default == true): if set to true, will use the global value HttpWebRequest.DefaultProxy as your proxy. HttpWebRequest.DefaultProxy is controllable through System.Net config, and defaults to using the system proxy settings (i.e. when you see in your Internet Explorer properties).
* public Uri ProxyAddress (default == null): If you want to specify a proxy directly you can set a proxy Uri directly here. To ensure no proxy is used you can specify “null†here. In both cases be sure to set UseDefaultWebProxy = false as well.
* public bool BypassProxyOnLocal (default == false): used in conjunction with ProxyAddress for when you specify a proxy. If you want “local” addresses (i.e. addresses on your intranet) to connect directly without using the proxy, set this value to true.
* public HttpProxyCredentialType HttpTransportSecurity.ProxyCredentialType (default == None): Specifies the authentication mode used with your Http proxy. For custom bindings the equivalent setting is public AuthenticationSchemes ProxyAuthenticationScheme (default == Anonymous) on HttpTransportBindingElement. For proxy authentication we will obtain the credential using the shared WCF provisioning framework (SecurityTokenProvider, etc). We simply pass in the proxy address (rather than the target address) for acquiring these credentials.
One last note about proxies: if you see a 502 or a 504 error returned to your client, then your client is using a proxy server. If this was not your intention, you can disable the server by setting UseDefaultWebProxy to false, and using the default ProxyAddress of null. The other possibility is that your proxy is misconfigured and you can use the above settings to rectify that situation.
Versioning with the Override and New Keywords (C# Programming Guide)
Anyway, I think keyword new for versioning should be avoided as much as possible..
Here is small example:
public static void RunSnippet()
{
Child child = new Child();
child.Run();
Intermediate intermediate = new Child();
intermediate.Run();
Base bs = new Child();
bs.Run();
IClass interf = new Child();
interf.Run();
IClass ch2 = new Child2();
ch2.Run();
}
public class Child2 : Intermediate, IClass
{
public new void Run()
{
WL("Child");
}
}
public class Child : Intermediate
{
public new void Run()
{
WL("Child");
}
}
public class Intermediate : Base
{
}
public class Base : IClass
{
public void Run()
{
WL("Base");
}
}
public interface IClass
{
void Run();
}
which produces output:
Child
Base
Base
Base
Child
An interesting resource with many free books about programming and more..