Skip to main content


Showing posts from June, 2009

WCF Instance Context Mode and Bindings

As well known, the instance context mode property of Service Behavior can have these three values.
PerCall - New instance is created for each client request.PerSession -  New instance is created for each new client session, and will be available throughout the sessionSingle - Only one instance handles for all client requests throughout the application  Example:

[ServiceBehavior( InstanceContextMode = InstanceContextMode.PerSession)] public class Service1 : IService1 { ... }
Now, what is the default value for the InstanceContextMode? I wrote a quick WCF app, and drilled down in debug mode.

As you might see, if you examine OperationContext.Current.InstanceContext and examine the Behaviour, you'll find useSession set to true, which means, it is PerSession.

But wait, let me change the binding to basicHttpBinding from wsHttpBinding - and let us have a look again.

Now you'll find that useSession is false, which means, the context mode is defaulting to PerCall…

Weekend Hacks - .NET Soup for the passionate Soul

About Week End Hacks - Most weekends I do some digging around new and emerging technology and geek stuff. I do this by picking the links I bookmarked, or by going through the tweets I Favorited in Twitter.

This weekend, it was some real fun and seems that I was frantically going through various stuff, partly related to a fun project I'm doing with SL and Live Mesh.

I was just going through my browser history, and got amazed with the stuff I went through this weekend. Here is a couple of useful links you might want to check out.

1Managed Extensibility Framework - Home - MEF enables greater reuse of applications and components. Using MEF, .NET applications can make the shift from being statically compiled to dynamically composed. If you are building extensible applications, extensible frameworks and application extensions, then MEF is for you.

2.NET "must-have" development tools - Stack Overflow - A good list of free tools available for .NET development

 3Microsoft Health Commo…

Skillset required for working in a Silverlight Project

Recently I was requested by the sourcing team to list down the skill set required for candidates for a Silverlight project. Here is something that I wrote as Job Descriptions, for each role.
UX Designer Profile
Ability to visualize and create user experiences, and to translate them to UI designs using Expression BlendExcellent understanding of XAML and capabilities of SilverlightExcellent understanding of creating and applying styles and templatesIdeal candidate will have been working with Silverlight 1.0 since its inception, with examples showing level of expertise with an understanding of enhancements made with 2.0 and 3.0. Silverlight Architect
Ability to guide the team by putting in place the required tools and frameworks (end to end) for Silverlight specific projectsExperience using Expression Blend and Visual Studio for Silverlight application developmentGood understanding of XAML Styles, Triggers, Observable Collection, Data Binding Methods, Model View View-Model (MVVM) pattern,…

Published Software Design Patterns For Everyone Ebook

Aggregated some of my earlier articles on design patterns (I published in code project), and published an e-book on the same over Scribd. The objective is to introduce software design patterns to you in a simple, human readable, and funny (?) way - in the context of designing a soccer engine - By discussing the thought process behind applying design patternsThis book is actually the compilation of two articles I wrote on ‘Applying Design Patterns’ – Part I & 2 and Part 3 & 4You can now download the PDF directly here. It is also available via Scribd.
Software Design Patterns Made Simple