code & chips

general programming stuff…

WCF Setup Problems

leave a comment »

WCF has to be one of the most frustrating technologies I have ever used.  The problems I encountered tonight were in the setup.  Like most things development, the trick is in the setup.  Unfortunately, I spend a lot of time tweaking the settings on my new development machine install, but I never remember or even note down the tweaks I made to get things to work.  So when I rebuild my machine, I am back to square one.

The WCF configuration has too many things that not only look the same, but the declarative nature – while flexible – in most cases is just a pain in the ass and I found it easier to simply hard code the values as in my experience, they rarely change.

Anyway, setting up my WCF IIS host on a new development machine proved to be more involved than I initially credited it would be.

When setting up the IIS host for a WCF library you will need to create an SVC file.  But, this file extension may not be recognised by IIS – making things ‘tricky’. So here are some things to look out for in order:

  • Try installing the ASP components from the Windows Components in Programs & Services.
  • Try ServiceModelReg -ia to install all the WCF components onto your machine.
  • Try asp net-regiis -i to install the handler configurations to IIS.
  • Sometimes you get a problem where you do not have permissions to run the web application from the current – normally – default application pool.  So try setting the user account to LocalSystem in IIS for the corresponding application pool.

Written by Kam

August 19, 2011 at 12:43 am

Posted in Uncategorized

Tagged with ,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Connecting to %s

Follow

Get every new post delivered to your Inbox.