Skip to main content

Posts

Showing posts from November, 2010

WCF 4 - File Less Activation, Default Endpoints and Default Bindings

Started going through WCF 4 a few months back, however, its today I got a chance to write down something about it So let me talk about something that was really interesting when I first read about it, File Less Activation of services. In WCF 3.5 when you wanted to host a service in IIS, you had to go through, adding endpoints, bindings and also a SVC file so that IIS can pick the request up. In WCF 4, this has been simplified so much, that you can get a service up and running in no time. Lets take an example, I created a service Service1 in a namespace DefaultEndpointSVC, and this is my web.config file.... <configuration> <system.serviceModel> <serviceHostingEnvironment> <serviceActivations> <add service="DefaultEndpointSVC.Service1" relativeAddress="myService.svc"/> </serviceActivations> </serviceHostingEnvironment> </system.serviceModel> </configuration> Now, if I go and deploy my service in IIS inside a vi

Running .NET code on a 64 bit Machine

Needed some information on how to develop .NET application for 64 bit machine, so I was doing the usual, reading a little bit of it, so before I forgot, i thought of posting it here for future reference. The main advantage of using a 64 bit machine over a 32 bit machine is that memory is not constrained to 4GB; in a 32 bit machine, the highest address that the CPU understands is around 4GB, but with a 64 bit machine, the address space become much more then this in the order of 2^64. Now lets talk about running .NET code, code that is 100% managed has no problem when it executes in a 64 bit, this is due to the fact that the CLR takes care of this. Going back to the basic, when you compile a piece of C# or VB.NET code, the compiler produces MSIL (Microsoft Intermediate Language) code, that contains enough information for the CLR (Common Language Runtime) to start execution, like meta data and the types used and so... When you start a program the windows loader, peeks at the assembly and