<?xml version="1.0" encoding="utf-8"?>
<feed xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xml:lang="en-us" xmlns="http://www.w3.org/2005/Atom">
  <title>.NET Meanderings</title>
  <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/" />
  <link rel="self" href="http://www.dotnetconsult.co.uk/weblog2/SyndicationService.asmx/GetAtom" />
  <icon>favicon.ico</icon>
  <updated>2013-04-08T13:08:10.4231250+02:00</updated>
  <author>
    <name>Richard Blewett</name>
  </author>
  <subtitle>Richard Blewett's wanderings around .NET</subtitle>
  <id>http://www.dotnetconsult.co.uk/weblog2/</id>
  <generator uri="http://www.dasblog.net" version="1.9.6264.0">DasBlog</generator>
  <entry>
    <title>Why Does WCF Reject Large Messages By Default?</title>
    <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,91fb7329-6604-4796-a4f1-f709db99229d.aspx" />
    <id>http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,91fb7329-6604-4796-a4f1-f709db99229d.aspx</id>
    <published>2013-04-08T13:08:10.4231250+02:00</published>
    <updated>2013-04-08T13:08:10.4231250+02:00</updated>
    <category term="WCF" label="WCF" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,WCF.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
If you have been working with WCF for a while you may have noticed that, by default,
messages over a certain size fail to get processed. The reason for this is that WCF
tries to protect the message receiver from getting swamped with messages that will
consume huge amounts of memory to process. The thing that controls this is the <font face="Courier New">maxReceivedMessageSize</font> on
the binding which defaults to 64Kb.
</p>
        <p>
Notice that <font face="Courier New">maxReceivedMessageSize</font> is only about the
receiver of the message, it doesn’t stop you sending a very large message. The idea
is that the sender is in control of what they send whereas the receiver has no way
to control the size of message it is being asked to deal with. There is no built in
way to limit the size of a message on the sender side, although you could use a <font face="Courier New">MessageInspector</font> for
this purpose as long as the message wasn’t being streamed.
</p>
        <p>
However, there are two ways to send messages: buffering and streaming. Buffered messages
get fully buffered in the channel layer before being handed to the service model layer
whereas streamed messages only buffer the SOAP headers and then pass the body as a
stream to the service model layer (this requires a service contract designed for streaming).
</p>
        <p>
Depending on the binding you may be able to change the maximum size of message that
can be dealt with purely by changing <font face="Courier New">maxReceivedMessageSize</font> however,
for bindings that support streaming (e.g. BasicHttpBinding) there is a second binding
parameter that may have to change - the <font face="Courier New">maxBufferSize</font>.
If you are buffering messages then the <font face="Courier New">maxReceivedMessageSize</font> and <font face="Courier New">maxBufferSize</font><font face="tre"> must
be the same. When streaming the <font face="Courier New">maxBufferSize</font><font face="tre"></font>must
be large enough to buffer the headers.</font></p>
        <p>
Once the binding allows messages larger than 64Kb that may not be the whole story
as there are other default limits in WCF: quotas and serializer limits. The quotas
control the maximum size of things like arrays and strings and are controlled by the <font face="Courier New">&lt;readerQuotas&gt;</font> element
under the binding. The serializer limit for the <font face="Courier New">DataContractSerializer</font> limits
the maximum number of objects in the object graph and is controlled by the <font face="Courier New">DataContractSerializer</font> service
behavior. Prior to WCF 4.5 these values often needed adjusting for large messages.
However, in WCF 4.5 these values were all defaulted to <font face="Courier New">int.MaxValue</font> as
the <font face="Courier New">maxReceivedMessageSize</font> already provides default
protection.
</p>
        <p>
If you suspect you are hitting on of these limits the quickest way normally to diagnose
this is to turn on tracing (I recorded a screencast <a href="http://rocksolidknowledge.com/ScreenCasts.mvc/Watch?video=WCFTracing.wmv">here</a> showing
how). It will show which limit has been breached.
</p>
        <p>
One final word on default endpoints introduced in WCF 4.0.If you have changed all
the relevant values and you are still seeing the <font face="Courier New">maxRecevedMessageSize</font> stopping
your messages make sure that you service config has the right name for the service.
If not, and you have a base address, the default endpoint functionality will use a
set of defaults anyway, ignoring your carefully crafted values.
</p>
        <img width="0" height="0" src="http://www.dotnetconsult.co.uk/weblog2/aggbug.ashx?id=91fb7329-6604-4796-a4f1-f709db99229d" />
      </div>
    </content>
  </entry>
  <entry>
    <title>The Architecture of WCF</title>
    <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,5421fea7-c54f-49f5-9ad4-df21fe40b32f.aspx" />
    <id>http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,5421fea7-c54f-49f5-9ad4-df21fe40b32f.aspx</id>
    <published>2013-04-07T21:28:47.1887500+02:00</published>
    <updated>2013-04-07T21:28:47.1887500+02:00</updated>
    <category term="WCF" label="WCF" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,WCF.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Before WCF it was, of course, possible for software running on different machines
to communicate. Over the lifetime of Windows there have been many technologies to
achieve this: sockets, DCOM, MSMQ, .NET Remoting, ASMX Web Services and more. The
problem is all of these have different APIs and different levels of capability. The
goal of WCF was to provide a unified API for communication and to be able to provide
a common level of service irrespective of the underlying transport.
</p>
        <p>
To understand the structure of WCF and why it looks the way it does  useful starting
point are <a href="http://msdn.microsoft.com/en-us/library/bb972954.aspx">the four
tenets of service orientation.</a> This is not because they are the one true definition
of service orientation but because they came from the team that  wrote WCF and,
therefore, give an insight to the thinking behind the architecture of WCF. Fundamentally
the internals of a service should not be visible to software consuming that service
and interaction between systems is based on passing platform independent messages.
</p>
        <p>
There are three core concepts at play whenever you use WCF: messages, channels and
encoders.
</p>
        <p>
          <strong>Messages</strong>
          <br />
Message is a first class construct in WCF and are modeled on <a href="http://www.w3.org/TR/soap/">SOAP</a> messages.
In other words they have a payload known as the body and an extensible collection
of contextual headers independent of the transport. They also support a specific header
called the action header which is defined in the <a href="http://www.w3.org/Submission/ws-addressing/">WS-Addressing</a> specification.
The action identifies the intent (purpose) of the message. Messages are represented
by the <font face="Courier New">System.ServiceModel.Channels.Message</font> class.
How messages are passed between two parties depends on the <em>Message Exchange Pattern</em>.
One way messaging means messages are passed on one direction only. Request/Response
means that there is a matching response message for each request message. Duplex means
that messages are passed freely in both directions without any required causality
between them. WCF supports all three of these patterns out of the box. 
</p>
        <p>
          <strong>Channels</strong>
          <br />
There are two types of channels in WCF: transport and protocol. Transport channels
are probably the most obvious: they move bytes from one place to another using some
transport protocol. WCF, as of 4.5, ships with the following transports: TCP, HTTP,
MSMQ, Named Pipes, UDP and WebSockets. It is, however, an extensible model and, for
example, there is an <a href="https://www.rabbitmq.com/dotnet.html">RabbitMQ AMQP
channel</a>. Protocol channels are designed to layer in functionality not supported
by the transport, for example, transaction flow of HTTP. The three core protocol channels
that come with WCF are security, transaction flow and reliable messaging. They are
implementations of Web Service specification such as WS-Security, WS-AtomicTransaction
and WS-ReliableMessaging and pass any required information to-and-fro using the message’s
Headers collection.
</p>
        <p>
          <strong>Encoders</strong>
          <br />
Messages are objects and transport channels move bytes. Something has to translate
between those two worlds and that something is called an encoder. The encoder controls
the format of a message on the wire. WCF comes with four encoders: Text, Binary, MTOM
and POX. The Text encoder puts textual XML SOAP messages on the wire. The Binary encoder
put a binary format of the SOAP message on the wire – this binary format is WCF specific
and is not designed to be interoperable with other platforms. The MTOM encoder implements
the <a href="http://www.w3.org/TR/soap12-mtom/">MTOM specification</a> and is a way
to transport binary payloads over SOAP without base 64 encoding them. The POX (Plain
Old XML) encoder strips of the SOAP pieces and just places the body of the message
on the wire and, as such, isn’t limited to XML.
</p>
        <p>
Protocol channels, encoders and transport channels are composed in a channel stack
controlling how messages are passed between a sender and receiver.
</p>
        <p>
          <a href="http://www.dotnetconsult.co.uk/weblog2/content/binary/WindowsLiveWriter/TheArchitectureofWCF_B673/image_2.png">
            <img title="image" style="border-top: 0px; border-right: 0px; border-bottom: 0px; float: none; margin-left: auto; border-left: 0px; display: block; margin-right: auto" border="0" alt="image" src="http://www.dotnetconsult.co.uk/weblog2/content/binary/WindowsLiveWriter/TheArchitectureofWCF_B673/image_thumb.png" width="240" height="116" />
          </a> <br />
As you can probably tell, the channel stacks on both sides of the communication need
to be compatible. Messages, Channels and Encoders make up the WCF <em>Channel Layer</em>. 
</p>
        <p>
Programming at the channel layer, however, is relatively heavy lifting and so, generally,
we work at a higher level of abstraction that takes care of much of the inherent complexity.
This abstraction sits on top of the channel layer and is called the <em>Service Model
Layer</em>. With the service model layer there are only two things we have to build
(we can build more if we choose to), the code that consumes the service functionality
and the implementation of that functionality. All of the plumbing can be automated.
</p>
        <p>
          <a href="http://www.dotnetconsult.co.uk/weblog2/content/binary/WindowsLiveWriter/TheArchitectureofWCF_B673/image_4.png">
            <img title="image" style="border-top: 0px; border-right: 0px; border-bottom: 0px; float: none; margin-left: auto; border-left: 0px; display: block; margin-right: auto" border="0" alt="image" src="http://www.dotnetconsult.co.uk/weblog2/content/binary/WindowsLiveWriter/TheArchitectureofWCF_B673/image_thumb_1.png" width="387" height="199" />
          </a>
        </p>
        <p>
The service model layer has two concepts: endpoints and behaviors. Endpoints are those
things that are agreed between the consumer and the service. Behaviors are local functionality
that is not visible to the other side of the communication (e.g. how requests are
mapped to threads). 
</p>
        <p>
You will often hear people talk about the ABCs of WCF. This is because the three component
parts of an endpoint are Address, Binding and Contract.
</p>
        <p>
          <strong>Contracts</strong>
          <br />
This defines what functionality an endpoint supports: the operations and the messages
they expect and may return. In WCF contracts are defined by using the <font face="Courier New">[ServiceContract]</font> and <font face="Courier New">[OperationContract]</font> attributes
on interfaces or classes. Interfaces are commonly used as it allows a single service
to implement many contracts.
</p>
        <p>
          <strong>Bindings</strong>
          <br />
Bindings specify the “how” of the communication: what transport protocol; how security
is configured; what the messages look like on the wire, etc. In other words it defines
what the channel layer looks like. There are a number of standard bindings modeling
common scenarios and you can also define custom ones if you have other requirements.
You can find a list of the standard bindings in WCF 4.5 <a href="http://msdn.microsoft.com/en-gb/library/ms730879.aspx">here</a>. 
</p>
        <p>
          <strong>Addresses</strong>
          <br />
The address of the endpoint is where the service is listening and where the consumer
will send messages. Address structure is determines by the transport protocol being
used, for example HTTP based addresses start with http:// and have a machine name
and potentially a port number in the address whereas MSMQ address start with net.msmq://
and contain the machine and queue name. 
</p>
        <p>
In the service model layer, a service is simply a class that implements one or more
contracts. However, something must actively start listening for incoming messages.
The <font face="Courier New">ServiceHost</font> class is responsible for instantiating
the set of objects that listen at the address and dispatch the messages as method
calls to the service implementation. You can either create the <font face="Courier New">ServiceHost</font> instance
yourself and call <font face="Courier New">Open</font> on it (known as self hosting)
or you can get the Windows Process Activation Service to do this (formally known as
WAS hosting). WAS hosting is also commonly referred to as IIS hosting as the service
is configured via IIS manager and the ASP.NET infrastructure.
</p>
        <p>
Clients use proxy objects to make calls to services. These can be obtained in one
of two ways: shared assembly and metadata.
</p>
        <p>
          <strong>Shared Assembly</strong>
          <br />
Remember that the client must have the same endpoint definition as the service. In
that case where does the client’s view of the contract come from? sharing an assembly
between client and service gives both the definition of the contract. Then, using
the same binding and address, the client creates an instance of the ChannelFactory&lt;T&gt;
class (where T is the contract) and then calls CreateChannel to create the proxy. 
</p>
        <p>
          <strong>Metadata</strong>
          <br />
Using a shared assembly works fine when it is reasonable for the service and client
to share code but cannot be used if the service and client are different technologies
and may want to be avoided if the client and service are maintained by unrelated teams.
In these situations we can use metadata in the form of WSDL or WS-MetadataExchange
to provide the client with a description of the endpoint which tools (Add Service
Reference in Visual Studio and svcutil.exe from the command line) can consume and
build the necessary code and configuration to invoke the service. Metadata is not
turned on by default and must be enabled using the <font face="Courier New">ServiceMetadataBehavior</font> behavior
in the service.
</p>
        <p>
That then is a broad brush for how WCF hangs together. There are many other factors
that need to be considered when building services but the raw plumbing of network
communication isn’t something with which service developers need to get involved.
Of course, there is nothing to stop developers getting involved at many of the extensibility
points of WCF but fortunately that is not a <em>requirement</em> to get clients and
services talking to each other.
</p>
        <img width="0" height="0" src="http://www.dotnetconsult.co.uk/weblog2/aggbug.ashx?id=5421fea7-c54f-49f5-9ad4-df21fe40b32f" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Devweek 2013</title>
    <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,e897f3f2-aac6-4a3f-a8e7-c458c6574c1e.aspx" />
    <id>http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,e897f3f2-aac6-4a3f-a8e7-c458c6574c1e.aspx</id>
    <published>2013-03-09T10:12:53.5518750+01:00</published>
    <updated>2013-03-09T10:12:53.5518750+01:00</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Thanks to everyone who attended my sessions at Devweek 2013 – I had a lot of fun delivering
them. It was also great to catch up with old friends and make a few new ones.
</p>
        <p>
As promised I have uploaded all of my slides and demos to the cloud and they can be
downloaded here
</p>
        <p>
          <a href="http://rocksolidknowledge.blob.core.windows.net/demos/Devweek2013WCF.zip">WCF
Preconference Workshop</a>
          <br />
          <a href="http://rocksolidknowledge.blob.core.windows.net/demos/Devweek2013Rx.zip">Reactive
Framework</a>
          <br />
          <a href="http://rocksolidknowledge.blob.core.windows.net/demos/Devweek2013GC.zip">Living
with the GC</a>
          <br />
          <a href="http://rocksolidknowledge.blob.core.windows.net/demos/Devweek2013workflow45.zip">Workflow
4.5</a>
          <br />
          <a href="http://rocksolidknowledge.blob.core.windows.net/demos/Devweek2013WCF45.zip">WCF
4.5</a> (remember you’ll need to be running Windows 8 for the WebSockets demos)<br /><a href="http://rocksolidknowledge.blob.core.windows.net/demos/Devweek2013UnitTestingVS2012.zip">What’s
new in Unit Testing in VS 2012</a> (remember that Fakes is only in VS Ultimate SKU)
</p>
        <img width="0" height="0" src="http://www.dotnetconsult.co.uk/weblog2/aggbug.ashx?id=e897f3f2-aac6-4a3f-a8e7-c458c6574c1e" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Devweek 2013&amp;ndash;WCF Crash Course</title>
    <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,42e4897d-bffa-4f79-9fe3-96032f1b897d.aspx" />
    <id>http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,42e4897d-bffa-4f79-9fe3-96032f1b897d.aspx</id>
    <published>2013-03-05T09:50:40.9436250+01:00</published>
    <updated>2013-03-05T09:50:40.9436250+01:00</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Thanks to everyone who attended my Devweek 2013 pre-conference session on WCF.
</p>
        <p>
You can get the slides and demos <a href="http://rocksolidknowledge.blob.core.windows.net/demos/Devweek2013WCF.zip">here</a></p>
        <img width="0" height="0" src="http://www.dotnetconsult.co.uk/weblog2/aggbug.ashx?id=42e4897d-bffa-4f79-9fe3-96032f1b897d" />
      </div>
    </content>
  </entry>
  <entry>
    <title>A Question of Chocolate and Cheese</title>
    <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,0829357a-7205-4a1b-a9d5-f2a063afa0da.aspx" />
    <id>http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,0829357a-7205-4a1b-a9d5-f2a063afa0da.aspx</id>
    <published>2012-10-06T23:39:01.5041250+02:00</published>
    <updated>2012-10-06T23:39:01.5041250+02:00</updated>
    <category term="Life" label="Life" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,Life.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
          <a href="http://www.hanselman.com/blog/Windows8ProductivityWhoMovedMyCheeseOhThereItIs.aspx">“Who
moved my Cheese”</a> was how a number of people at Microsoft have characterized people’s
reaction to Windows 8. In other words – “all the stuff you need is there, I know its
uncomfortable that we changed things but its just cosmetic”. 
</p>
        <p>
To a degree this characterization is right that mostly existing functionality it there
just you access it in different ways – and there is new functionality that we didn’t
have before. However there is a bigger issue with Windows 8 – one of chocolate. 
</p>
        <p>
The Windows 8 desktop is cheese – that’s users’ familiar world prior to Windows 8.
But in Windows 8 we have another way to access functionality – one that’s tablet friendly,
iPad user friendly, touch friendly – that’s not cheese, that’s chocolate – people
love chocolate! Finally Windows has a world that means they are not offering cheese
to those chocophiles and that can only be a good thing from Microsoft’s perspective. 
</p>
        <p>
I’m a professional software developer basing most of my work in the Windows world.
I’ve used Windows heavily since Windows 3.1 and I’ve (mostly) liked the evolution
of the operating system. I currently run a big multicore machine with two high-resolution
monitors for software development. The important thing for me is being able to have
my development environment (Visual Studio 2012 now) as my focus but have my email,
browser windows, Skype, a few Windows explorer windows, VSphere, Excel, Powerpoint
and many other applications running concurrently and being able to have many of the
visible at the same time correlating data between them - all of these are cheese applications. 
</p>
        <p>
I have been running Windows 8 for a while and really like the immersive nature of
many of the “Modern Windows” (or Chocolate) applications – especially as I can run
these on one monitor and have my Cheese applications running on the other monitor.
And if I need to, both of my monitors can be cheese based if I have a bunch of cheese
like things going on. 
</p>
        <p>
The problem is I just don’t like Windows 8. 
</p>
        <p>
It’s the damn Windows key. 
</p>
        <p>
If I’m in the mood for chocolate then I really like chocolate – and if you always
offer me chocolate I’m very happy. 
</p>
        <p>
But actually I’m a savory guy – I spend most of my time wanting cheese. When I press
the windows key you offer me chocolate and I select cheese – if I had to do that once
I would be OK with that but <strong>every single time I want cheese you say “Aha!
I think you want some chocolate”</strong> Dammit! I’ve chosen cheese every time for
the last hour I obviously don’t want chocolate at the moment! 
</p>
        <p>
OK I’ve done that metaphor to death. The problem with windows 8 is you force me to
context switch every time I want to run another desktop application. It is disruptive
and painful as a user experience. If I’m in the desktop world then please, please
let me start another desktop application without going via Metro.
</p>
        <img width="0" height="0" src="http://www.dotnetconsult.co.uk/weblog2/aggbug.ashx?id=0829357a-7205-4a1b-a9d5-f2a063afa0da" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Certificate Validation and Setting up Service Bus 1.0 Beta for Windows Server</title>
    <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,50861acd-6bd1-4283-9fdc-7a611a440829.aspx" />
    <id>http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,50861acd-6bd1-4283-9fdc-7a611a440829.aspx</id>
    <published>2012-07-25T18:04:54.4808750+02:00</published>
    <updated>2012-07-25T18:04:54.4808750+02:00</updated>
    <category term=".NET" label=".NET" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,.NET.aspx" />
    <category term="Azure" label="Azure" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,Azure.aspx" />
    <category term="ServiceBus" label="ServiceBus" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,ServiceBus.aspx" />
    <category term="WCF" label="WCF" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,WCF.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Microsoft recently announced the beta of Service Bus 1.0 for Windows Server. This
is the on-premise version of the Azure Service Bus that so many have been asking for.
There is a good walkthrough of the new beta in the MSDN documentation <a href="http://msdn.microsoft.com/library/jj193022(Azure.10).aspx">here</a> including
how to install it. 
</p>
        <p>
So why this blog post? Well if you install the beta on a Windows Server 2008 R2 box
and you actually develop on another machine then there’s a couple of things not mentioned
in the documentation that you need to do (having previously spent long hour glaring
at certificate errors allowed me to resolve things pretty quickly)
</p>
        <p>
First a little background into why there is an issue. Certificate validation has a
number of steps to it for a certificate to be considered valid:
</p>
        <ol>
          <li>
The issuer of the cert must be trusted. In fact the issuer of the issuer must also
be trusted. In fact the issuer of the issuer of the issuer must be trusted. In fact
… well you get the picture. In other words, when a certificate is validated all certificates
in the chain of issuers must be trusted back to a trusted root CA (normally bodies
like Verisign or your corporate certificate server). You will find these in your certificate
store in the “Trusted Root Certificate Authorities” section. This mechanism is known
as <strong>chain trust</strong>.</li>
          <li>
The certificate must be in date (between the valid from and valid to dates)</li>
          <li>
The usage of the certificate must be correct for the supported purposes of the cert
(server authentication, client authentication, code signing, etc)</li>
          <li>
For a server authentication cert (often known as an SSL cert) the subject of the cert
must be the same as the server DNS name</li>
          <li>
The certificate must not be revoked (if a cert is compromised the issuer can revoke
the cert and publishes this in a revocation list) according to the issuers revocation
list</li>
        </ol>
        <p>
For 1. there is an alternative called <strong>Peer Trust</strong> where the presented
certificate must be in the clients Trusted People section of their certificate store
</p>
        <p>
There may be other forms of validation but these are the ones that typically fail
</p>
        <p>
So the issue is that the installer of Service Bus (SB), if you just run through the
default install, generates a Certificate Authority cert and puts it into the target
machine’s Trusted CA store – it obviously doesn’t put it in the client’s Trusted CA
store because it knows nothing about that. It also generates a server authentication
cert with the machine name you are installing on. This causes two issues: no cert
issued by the CA will be trusted and so an SSL failure will happen the first time
you try to talk to SB, the generated SSL cert will have problems generally validating
due to, for example, no revocation list
</p>
        <p>
The first of these issues can be fixed by exporting the generated CA cert and importing
it into the Trusted CA Store ion the dev machine
</p>
        <p>
          <a href="http://www.dotnetconsult.co.uk/weblog2/content/binary/Windows-Live-Writer/Setting-up-Ser.0-Beta-for-Windows-Server_D6B6/CA_2.png">
            <img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="CA" border="0" alt="CA" src="http://www.dotnetconsult.co.uk/weblog2/content/binary/Windows-Live-Writer/Setting-up-Ser.0-Beta-for-Windows-Server_D6B6/CA_thumb.png" width="573" height="89" />
          </a>
        </p>
        <p>
The second can be fixed by exporting the SSL cert and importing it into the trusted
people store on the dev machine
</p>
        <p>
          <a href="http://www.dotnetconsult.co.uk/weblog2/content/binary/Windows-Live-Writer/Setting-up-Ser.0-Beta-for-Windows-Server_D6B6/SSL_2.png">
            <img style="background-image: none; border-bottom: 0px; border-left: 0px; padding-left: 0px; padding-right: 0px; display: inline; border-top: 0px; border-right: 0px; padding-top: 0px" title="SSL" border="0" alt="SSL" src="http://www.dotnetconsult.co.uk/weblog2/content/binary/Windows-Live-Writer/Setting-up-Ser.0-Beta-for-Windows-Server_D6B6/SSL_thumb.png" width="576" height="71" />
          </a>
        </p>
        <p>
With these in place the Getting Started / Brokered Messaging / QueuesOnPrem sample
should work fine
</p>
        <img width="0" height="0" src="http://www.dotnetconsult.co.uk/weblog2/aggbug.ashx?id=50861acd-6bd1-4283-9fdc-7a611a440829" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Demos from TechEd EMEA</title>
    <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,89baa03d-47ee-4c9e-8705-c04f2df5518d.aspx" />
    <id>http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,89baa03d-47ee-4c9e-8705-c04f2df5518d.aspx</id>
    <published>2012-07-02T15:13:14.5140000+02:00</published>
    <updated>2012-10-06T10:19:27.7072500+02:00</updated>
    <category term=".NET" label=".NET" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,.NET.aspx" />
    <category term="WCF" label="WCF" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,WCF.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
The demos from DEV 326 – my talk on WCF 4.5 at TechEd EMEA are available <a href="http://rocksolidknowledge.blob.core.windows.net/demos/DEV326%20-%20Demos.zip">here</a>.
The session was also recorded and the video is now on Channel9 <a href="http://channel9.msdn.com/Events/TechEd/Europe/2012/DEV326">here</a></p>
        <img width="0" height="0" src="http://www.dotnetconsult.co.uk/weblog2/aggbug.ashx?id=89baa03d-47ee-4c9e-8705-c04f2df5518d" />
      </div>
    </content>
  </entry>
  <entry>
    <title>DevelopMentor Moorgate Office Launch</title>
    <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,c45cebe0-f3b4-4c0b-8f98-0c31a068a17b.aspx" />
    <id>http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,c45cebe0-f3b4-4c0b-8f98-0c31a068a17b.aspx</id>
    <published>2012-01-17T09:18:38.0675000+01:00</published>
    <updated>2012-01-17T09:18:38.0675000+01:00</updated>
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
To celebrate <a href="http://www.develop.com/">DevelopMentor’s</a> move to offices
at 120 Moorgate in London, myself and <a href="http://www.rocksolidknowledge.com/Blog.mvc/ViewBlog?blogName=Andy%20Clymer">Andy
Clymer</a> are presenting an evening of C# 5 Async. The next version of the C# language
has built-in support for async processing. We’ll show you how it improves over the
previous models and how it works under the covers.
</p>
        <p>
This event is on Monday the 6th February from 5-7 and is free to attend, just register
with the DevelopMentor office on 01242 525 108 or email <a href="mailto:salesuk@develop.com">salesuk@develop.com</a></p>
        <img width="0" height="0" src="http://www.dotnetconsult.co.uk/weblog2/aggbug.ashx?id=c45cebe0-f3b4-4c0b-8f98-0c31a068a17b" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Demos from Basta 2011</title>
    <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,a5b8a66a-b880-46eb-b656-e33ce7d78c9b.aspx" />
    <id>http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,a5b8a66a-b880-46eb-b656-e33ce7d78c9b.aspx</id>
    <published>2011-09-29T00:46:31.7790000+02:00</published>
    <updated>2011-09-29T00:46:31.7790000+02:00</updated>
    <category term=".NET" label=".NET" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,.NET.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Thanks to everyone for attending my sessions on the Reactive Framework and Garbage
Collection at <a href="http://basta.net/">Basta 2011</a>, you can download the demos
here:
</p>
        <p>
          <a href="http://rocksolidknowledge.blob.core.windows.net/demos/Basta2011Rx.zip">Reactive
Framework</a>
        </p>
        <p>
          <a href="http://rocksolidknowledge.blob.core.windows.net/demos/Basta2011GC.zip">Garbage
Collection</a>
        </p>
        <img width="0" height="0" src="http://www.dotnetconsult.co.uk/weblog2/aggbug.ashx?id=a5b8a66a-b880-46eb-b656-e33ce7d78c9b" />
      </div>
    </content>
  </entry>
  <entry>
    <title>Self Hosted Web API / Nuget Gotcha</title>
    <link rel="alternate" type="text/html" href="http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,d69307a4-76c2-4a38-b317-1c15fb189acc.aspx" />
    <id>http://www.dotnetconsult.co.uk/weblog2/PermaLink,guid,d69307a4-76c2-4a38-b317-1c15fb189acc.aspx</id>
    <published>2011-06-15T11:21:33.5306250+02:00</published>
    <updated>2011-06-15T11:21:33.5306250+02:00</updated>
    <category term=".NET" label=".NET" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,.NET.aspx" />
    <category term="REST" label="REST" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,REST.aspx" />
    <category term="WCF" label="WCF" scheme="http://www.dotnetconsult.co.uk/weblog2/CategoryView,category,WCF.aspx" />
    <content type="xhtml">
      <div xmlns="http://www.w3.org/1999/xhtml">
        <p>
Just a heads up that when self hosting the new WCF Web API. By default if you try
to add the Web API references via Nuget you will get a failure (E_FAIL returned from
a COM component).
</p>
        <p>
This is due to the likely project types (Console, Windows Service, WPF) defaulting
to the client profile rather than the full framework. If you change the project to
the full framework the Nuget packages install correctly
</p>
        <p>
Yet again bitten by the Client Profile 
</p>
        <img width="0" height="0" src="http://www.dotnetconsult.co.uk/weblog2/aggbug.ashx?id=d69307a4-76c2-4a38-b317-1c15fb189acc" />
      </div>
    </content>
  </entry>
</feed>