Tunnelling Software

BarbaTunnelProject Description

A layer that hide, redirect. forward, re-encrypt internet packet to keep VPN, Proxies and other p2p software hidden from Firewall. Free implementation for HTTP-Tunnel, UDP-Tunnel, port forwarding, port redirecting and packet re-encryption that can work in network data-link layer and transport layer.
ref: http://barbatunnel.codeplex.com


Using Service Bus on Windows Server

Service Bus 1.0 on windows Server


REDIS: Remote Dictionary Server, an in-memory, key-value data store

“Redis is an open-source, networked, in-memory, key-value data store with optional durability. It is written in ANSI C. The development of Redis has been sponsored by Pivotal since May 2013;[1] before that, it was sponsored by VMware.[2][3] According to the monthly ranking by DB-Engines.com, Redis is the most popular key-value store.[4]” ref: http://en.wikipedia.org/wiki/Redis

remote dictionary server

“Redis is an open source, BSD licensed, advanced key-value store. It is often referred to as a data structure server since keys can contain strings, hashes, lists, sets and sorted sets.”
ref: http://redis.io/

Quick start


How many requests per second can I get out of Redis?
How many requests per second can I get out of Redis?


Redis is a very powerful tool that can be used widely in building especially a large scaling system, as a distributed cache, NoSQL and message queue.

RestMQ: Redis based message queue



Redis vs MongoDB

Redis vs. MongoDB Performance

“MongoDB is an open source document database, and the leading NoSQL database which is written in C++ and Redis is also an open source NoSQL database but it is key-value store rather than document database. Redis is often referred to as a data structure server since keys can contain strings, hashes, lists, sets and sorted sets.

Results were measured using MongoDB 2.4.8 and Redis 2.6.16

Machine Specifications

  • Processor : 4x Intel(R) Core(TM) i5-3230M CPU @ 2.60GHz
  • Memory : 3892MB
  • Operating System : Ubuntu 13.04
  • Kernel -Version : Linux 3.8.0-33-generic (x86_64)
Redis Read Mongo Read Redis Write Mongo Write
10 2 5 5 8
100 13 11 8 34
1,000 38 93 31 153
10,000 238 980 220 1394
50,000 958 5218 979 8713

Calculated time in milliseconds (lower is better)”

MongoDB and Redis: a different interpretation of what’s wrong with Relational DBs


Redis as the primary data store? WTF?!




servicestack and other redis clients

servicestack redis client alternatives
“The free-quota limit on ‘6000 Redis requests per hour’ has been reached.”




scaling redis
How Twitter Uses Redis To Scale – 105TB RAM, 39MM QPS, 10,000+ Instances

Scaling Redis

Partitioning: how to split data among multiple Redis instances.

Redis cluster tutorial


WCF routing

Hello World routing sample

Bridging and Error Handling routing sample

Advanced Filters routing sample

Dynamic routing sample

Advanced error handling routing sample

Routing topic on MSDN — full coverage of services, contracts, filters, and scenarios

Routing Rules! Blog — the entire blog is about the routing service and the different scenarios it enables. Take a read through all the blog posts for sure.

Building a WCF Router, Part 1 on MSDN Magazine

Building a WCF Router, Part 2 on MSDN Magazine


Windows Communication Foundation (WCF) and Windows Workflow Foundation (WF) Samples for .NET Framework 4


Self-signed certificates with WCF

Using a self-signed certificate with .NET’s HttpWebRequest/Response
Turns out, if you just want to disable certificate validation altogether, you can change the ServerCertificateValidationCallback on the ServicePointManager, like so:
ServicePointManager.ServerCertificateValidationCallback = delegate { return true; };”
How to accept a self-signed SSL certificate in a WCF client?

C# Ignore certificate errors?


GIT Source Control System

A Short History of Git

10 Years of Git: An Interview with Git Creator Linus Torvalds

A year with Git

how to set up a centralized Git repository

Simple git server for Windows: http://bonobogitserver.com/

Git Stack – Git Server for Windows


git – the simple guide
“just a simple guide for getting started with git.”


3 Reasons to Switch to Git from Subversion
“1) Git creates a full repository with this command. With Subversion, you’re just checking out the files in the repository.
2) With each branch, no new files are created in the project file hierarchy on your system. Since you have a full local repository, Git creates the files you need on the fly by processing the recorded changes. With Subversion, you have to create every branch remotely on the server. This can get messy depending on the size of your team. If you decide to control branching to keep things clean, you forfeit the power branching offers.
3) With Git, we only push our work to the server AFTER collaboration (more below). With Subversion, it all hits the server.
4) Again, no file system work. Since we’re using a local repository, we let Git handle the details of removing the branch. With Subversion, you still have the old copy until you update. You either have to clean up manually, or “update” to clean up local and remote copies.”
Why You Should Switch from Subversion to Git
GitSvnComparison: A summary of differences
“Git is much faster than Subversion
Subversion allows you to check out just a subtree of a repository; Git requires you to clone the entire repository (including history) and create a working copy that mirrors at least a subset of the items under version control.
Git’s repositories are much smaller than Subversions (for the Mozilla project, 30x smaller)
Git was designed to be fully distributed from the start, allowing each developer to have full local control
Git branches are simpler and less resource heavy than Subversion’s
Git branches carry their entire history
Merging in Git does not require you to remember the revision you merged from (this benefit was obviated with the release of Subversion 1.5)
Git provides better auditing of branch and merge events
Git’s repo file formats are simple, so repair is easy and corruption is rare.
Backing up Subversion repositories centrally is potentially simpler – since you can choose to distributed folders within a repo in git
Git repository clones act as full repository backups
Subversion’s UI is more mature than Git’s
Walking through versions is simpler in Subversion because it uses sequential revision numbers (1,2,3,..); Git uses unpredictable SHA-1 hashes. Walking backwards in Git is easy using the “^” syntax, but there is no easy way to walk forward.”
“DVCS proponents point to several advantages of distributed version control systems over the traditional centralized model:
Allows users to work productively even when not connected to a network
Makes most operations much faster since no network is involved
Allows participation in projects without requiring permissions from project authorities, and thus arguably better fosters culture of meritocracy instead of requiring “committer” status
Allows private work, so users can use their revision control system even for early drafts they do not want to publish
Avoids relying on a single physical machine as a single point of failure.
Still permits centralized control of the “release version” of the project”


Please. Stop Using Git. – Matthew McCullough


Git Large File Storage





Sorting Algorithms

Sorting Match betwwen Quicksort and Bubble Sort

Three Beautiful Quicksorts

Visual Demonstration of the QuickSort Algorithm


Tutorial on Nant How to install and configure

Building and Deploying Using NAnt


NaNT .build file Intellisense

A Brief Introduction to NAnt

NAnt 0.92: log4net:ERROR XmlConfiguratorAttribute: Exception getting ConfigurationFileLocation
Download “streams” from http://technet.microsoft.com/en-us/sysinternals/bb897440.aspx and execute:  streams -s -d <Nant Folder>
ref: http://gisbiz.com/2012/12/nant-0-92-log4neterror-xmlconfiguratorattribute-exception-getting-configurationfilelocation/

How to discover multi threading related bugs and debug them?

Multi threaded applications are great, they provide high performance, high throughput but tackling concurrency issues are sometimes  not easy. Especially preemption related bug cannot be easily reproduced. Thus Microsoft created a useful tool called CHESS, to simulate all possible preemptions for your multi threaded application.

How to correctly implement multi-threading in C#

Tools And Techniques to Identify Concurrency Issues


Custom Trace Listener and multiple threads


CHESS: Systematic Concurrency Testing

CHESS is a tool for systematic and disciplined concurrency testing. Given a concurrent test, CHESS systematically enumerates the possible thread schedules to find hard-to-find concurrency errors, including assertion violations, deadlocks, data-races, and atomicity violations.
ref: http://chesstool.codeplex.com/

CHESS: An Automated Concurrency Testing Tool

CHESS: Find and Reproduce Heisenbugs in Concurrent Programs

CHESS: An Automated Concurrency Testing Tool



Unit Testing Asynchronous Code: Three Solutions for Better Tests

Improved Multithreaded Unit Testing



SOLID Principles with Examples in C#

Implementing the Inversion of Control Pattern in C#

SOLID Principles in C# – An Overview

SOLID principles with real world examples


ref: http://en.wikipedia.org/wiki/SOLID_(object-oriented_design)

Initial Stands for
Single responsibility principle
class should have only a single responsibility.
Open/closed principle
“software entities … should be open for extension, but closed for modification”.
Liskov substitution principle
“objects in a program should be replaceable with instances of their subtypes without altering the correctness of that program”. See also design by contract.
Interface segregation principle
“many client-specific interfaces are better than one general-purpose interface.”[5]
Dependency inversion principle
one should “Depend upon Abstractions. Do not depend upon concretions.”[5]
Dependency injection is one method of following this principle.


What’s the difference between the Dependency Injection and Service Locator patterns?
“The difference may seem slight, but even with the ServiceLocator, the class is still responsible for creating its dependencies. It just uses the service locator to do it. With DI, the class is given it’s dependencies. It neither knows, nor cares where they come from. One important result of this is that the DI example is much easier to unit test — because you can pass it mock implementations of its dependent objects. You could combine the two — and inject the service locator (or a factory), if you wanted.”


The Principles of Good Programming

3 Key Software Principles You Must Understand



Liskov Substitution Principle

Can you explain Liskov Substitution Principle with a good C# example?

Simplifying the Liskov Substitution Principle of SOLID in C#

Liskov Substitution Principle in C#






Moscow Prioritisation

MoSCoW Principle: Must, Should, Could, Would
“MoSCoW is a technique used in management, business analysis, and software development to reach a common understanding with stakeholders on the importance they place on the delivery of each requirement – also known as MoSCoW prioritization or MoSCoW analysis.
According to A Guide to the Business Analysis Body of Knowledge, version 2.0,[1] section, the MoSCoW categories are as follows:”

Moscow Prioritisation
“Must Have, Should Have, Could Have, Won’t Have this time”





Interesting Features in C#

New features in C# 4.5 and C# 5.0

C# 5.0: More Than Just Async

An Introduction to New Features in C# 5.0

What Happens in an Async Method

Asynchronous Programming in C# 5.0 using async and await


closure in c#

C# Closures Explained

The Beauty of Closures