Browsing Archives of Author »Ariela Boursi«

Catching the real exception …

January 4, 2011

2

In the previous post (see whose-fault-is-it), I mentioned that there is a trick you can implement in order to enable your clients catch the exact exception thrown by the server instead of the generic FaultException. This contradicts the WCF pattern according to which the client should catch only FaultExceptions. The reason WCF promotes catching generic […]

Whose fault is it?

December 26, 2010

0

In this post I’m going to explain what is the SOAP Fault, and how it should be handled. There are 3 types of SOAP messages: Request Reply Fault when the client receives a fault message, it  indicates  that an error occurred on the server side which WCF translated to the client as a fault. It […]

IOperationBehavior–How to customize behaviors for the WCF operation?

December 22, 2010

1

IOperationBehavior which is located in System.ServiceModel.Description assembly allows to extend the behaviors of operations for both the client and the server sides.

IParameterInspector – How to inspect arguments and return values?

December 21, 2010

0

Overriding the IParameterInspector located in System.ServiceModel.Dispatcher namespace allows inspecting parameters passed in each operation before the call is executed and after the response is returned. IParameterInspector’s interface contains the following methods: public interface IParameterInspector { void AfterCall(string operationName, object[] outputs, object returnValue, object correlationState); object BeforeCall(string operationName, object[] inputs); } The ParameterInspector can be inserted […]

Extended WCF– Preview…

December 19, 2010

0

WCF can be extended through the extensibility points (see  https://wcfpro.wordpress.com/wcf-extensions/), but sometimes these points are not good enough. In the next posts under this category, I’m going to describe a way to extend WCF on the client side which does not use the extensibility points and by this allowing us to implement more advanced features. […]

IOperationInvoker–How to wrap each call in the server side?

December 15, 2010

0

IOperationInvoker is responsible for invoking the methods on the server side with the required parameters and generate the required output parameters and the method’s return value. Its interface contains the following methods:   public interface IOperationInvoker { object[] AllocateInputs(); object Invoke(object instance, object[] inputs, out object[] outputs); System.IAsyncResult InvokeBegin(object instance, object[] inputs, System.AsyncCallback callback, object […]

IDispatchOperationSelector–How to assign messages to operations?

December 12, 2010

0

When working with SOAP messages the dispatching in the server side is done according to the soap action header, which instructs the dispatcher what is the corresponding method which should handle the message. When there is a need to override the default way the server assigns incoming messages to operations, the IDispatchOperationSelector should be overridden. […]