Sep 18 2007

WCF netTcpBinding service in WS2008 Beta 2

Category: .NetRory Primrose @ 16:35

Yesterday I got the opportunity to start playing with WCF net.tcp services hosted in WAS on Windows Server 2008 (Beta 2). There were a couple of hiccups, but it was surprisingly painless.

Firstly, I got the service up and running over wsHttpBinding. One thing I noticed about this is that, unlike XP Pro (and I think Vista), IIS7 on WS2008 doesn't need anonymous set against the svc file for the service endpoint when the rest of the site was running under Windows Authentication. Straight away, this service was working using a remote client over http.

Next up was trying netTcpBinding. First job was getting the required features installed. This MSDN article provides the details as:

To install the WCF non-HTTP Activation Components

  1. From the Start button, click the Control Panel, click Programs, and then click Programs and Features.

  2. From the Tasks menu, click Turn Windows features on or off.

  3. Find the Microsoft.NET Framework 3.0 node, select and expand it.

  4. Select the WCF Non-Http Activation Components box and save the setting.

A few configuration changes were required in the host web.config. Because I wanted to use the same svc endpoint, I had to provide specific addresses in the configuration for each of the bindings because they have different base addresses.

Next I added the net.tcp binding to the site in IIS. This is done through the "Site Bindings" dialog of the site. So what is the format of the "Binding Information" field? I had no idea off the top of my head and unfortunately the help documentation only describes http/https binding configurations. After a quick web search, Nicholas Allen to the rescue:

The format for TCP was picked to be as similar as possible to what already existed for HTTP. We have two parts to configure, again separated by colons. There is no equivalent for the list of addresses. The two parts are

  1. Port number
  2. Host name comparison mode (blank or a wildcard symbol)

I chose a port number and entered 8081:* as my binding information. Now my site bindings look like this:

Running my remote client using the new address and binding didn't work. No connection. Windows Firewall gets me every time. To test if the firewall is the issue, I usually turn off the firewall temporarily and run the client. In this case, the connection was successful. I turned the firewall back on (very important!) and added the TCP port 8081 as an exception in the firewall rules. I also added 8080 as I moved away from the default port 80 for my http binding.

Now I have a connection, but I get an error saying that the protocol net.tcp is not supported. After a quick web search, I found this MSDN article (same as above). It indicates some commands that need to be run. The one that stood out to me is:

%windir%\system32\inetsrv\appcmd.exe set app "Default Web Site/<WCF Application>" /enabledProtocols:http,net.tcp

One of the things I am trying to do is to avoid command executions. So with the hint of "enabledProtocols", I go searching through the IIS admin UI. I stumble across the "Advanced Settings" dialog for the site. I added net.tcp to the enabled protocols.

Job done, service up and running over both http and net.tcp.

Tags:

Sep 6 2007

The pain and rudeness of Windows Live (Writer)

Category: IT RelatedRory Primrose @ 06:56

I think that Windows Live Writer is a great product, but I suspect that the team has been forced into doing things a certain way. I'm sure the Windows Live Writer team is not totally to blame for this, but the impact is the same regardless.

Beta 3 has just been released. I'm really happy about this announcement and I head off to download it. Now this is the part I am not happy about. Here are the issues I have with the installer:

  1. It isn't a direct installer for Windows Live Writer, just a downloader
  2. I am asked to make Live Search my default searcher in IE, selected by default
    • Ok, problem here is that people already have a default for a reason. It is fine to offer this as an option, but it is rude to select it by default and burn the people that just click Next, Next, Next.
    • I unselect this and after the installer fails, my default search in IE is now Live Search instead of Google. HELLO!
  3. I am asked to help with feedback. Again, selected by default
  4. I am asked if I want to install Messenger, Mail, Toolbar, Photo Gallery. Again and again, selected by default
  5. Write fails to download
    • No support for direct downloads
  6. Sign-in Assistant fails to download
    • No support for direct downloads

My issues with this installer are mostly that installer options that are selected by default. Users should be able to opt-in for these options, rather than having to opt-out. I think this is just rude. Doubly rude for reassigning my default search provider when I explicitly said not to. Finally, I obviously have some restriction in my environment (outside of my control) such that the automatic downloader can't get the real installers. There doesn't appear that there are direct download links available. So in the end, I can't install this product.

Hopefully, there is a direct download link available. Anyone know?

Tags:

Sep 4 2007

Virtual CloneDrive

Category: ApplicationsRory Primrose @ 09:20

Just came across a nice little utility for mounting ISO images called Virtual CloneDrive. I have used DAEMON Tools for a long time, but the lack of explorer integration is annoying. Last time I used it, it also contained malware which is concerning. After a quick test, Virtual CloneDrive is really easy to use and super fast.

Tags: