WHAT IS WCF?
 Integration of several Microsoft
Technologies:
 Web services (ASMX)
 Web service extensions (WSE)
 WS-Security
 WS-Reliability
 WS-Addressing
 .NET Remoting
 MSMQ messaging
 COM+ Transactions
WCF DESIGN PRINCIPLES
 Boundaries are explicit
 No attempt to hide communication
 Services are autonomous
 Deployed, managed, and versioned independently
 Services share contracts and schemas, not
types
 Contracts define behavior, schemas define data
 Compatibility is policy-based
 Policy supports separation of behavior from access
constraints
CHANNEL MODEL
 WCF supports three types of channel
activity:
 Asynchronous one-way
 Request, wait for reply
 Full duplex two-way
STRUCTURE
 Service
 Contract
 Service contract – RPC Interface
 Data contract – Type serialization
 Message contract – Soap message
 Binding
 Transport – HTTP, TCP, MSMQ, …
 Channel type – one-way, duplex, request-reply
 Encoding – XML, binary, MTOM (msg trans optim mech)
 WS-* protocols – WS-Security, …
CHANNEL INTERFACES
 public interface IOutputChannel : IChannel
{ void Send(Message msg); }
 public interface IInputChannel : IChannel
{ Message Receive(); }
 public interface IDuplexChannel :
IOutputChannel, IInputChannel {}
 public interface IRequestChannel : IChannel
{ Message Request(Message msg); }
 public interface IReplyChannel : IChannel
{ IRequestContext ReceiveRequest(); }
 public interface IRequestContext : Idisposable
{ Message RequestMessage { get; }
void Reply(Message msg); }
SERVICE CONTRACT
 <%@ ServiceHost Language=“C#”
Service=“MyService” %>
[ServiceContract]
public interface IMyService
{
[OperationContract]
string Hello( string name);
}
public class MyService : IMyService
{
public string Hello(string name)
{ return “Hello “ + name; }
}
HOSTS
 WCF Services can be hosted in:
 Internet Information Services (IIS)
 Very similar to web services
 Windows services
 Exposing windows service in style of WS
 Console and Winform applications
 New style for socket like functionality
OTHER TOPICS
 WCF Security
 Credentials and claims (evidence)
 Transport-level security
 Message-level security
 Federated security model
 Authorization
 Auditing
OTHER FEATURES
 WCF Supports transactions
 ACID properties
 Atomicity
 composite operations treated as a unit
 Consistency
 Operations succeed or the system is returned to
prior state
 Isolation
 Each transaction is independent and isolated from
other transactions
 Durability
 If an operation succeeds it becomes durable, e.g.,
committed to a database or other persistant store
CONCLUSION
 Convergence of programming models
 Desktop Application
 Web Application
 Windows Services
 Flexible hosting options
 Flexible abstractions
we provide online and classroom training for WCF
For More Details
www.asit.amcsquare.com
Wise Machines India Pvt Ltd
#360, Sri Sai Padma Arcade,
Varthur Main Road,
Ramagondanahalli,
Whitefiled ,Bangalore – 560066.
We also having Branches in Hyderabad & Chennai

Learn WCF at ASIT

  • 2.
    WHAT IS WCF? Integration of several Microsoft Technologies:  Web services (ASMX)  Web service extensions (WSE)  WS-Security  WS-Reliability  WS-Addressing  .NET Remoting  MSMQ messaging  COM+ Transactions
  • 3.
    WCF DESIGN PRINCIPLES Boundaries are explicit  No attempt to hide communication  Services are autonomous  Deployed, managed, and versioned independently  Services share contracts and schemas, not types  Contracts define behavior, schemas define data  Compatibility is policy-based  Policy supports separation of behavior from access constraints
  • 5.
    CHANNEL MODEL  WCFsupports three types of channel activity:  Asynchronous one-way  Request, wait for reply  Full duplex two-way
  • 6.
    STRUCTURE  Service  Contract Service contract – RPC Interface  Data contract – Type serialization  Message contract – Soap message  Binding  Transport – HTTP, TCP, MSMQ, …  Channel type – one-way, duplex, request-reply  Encoding – XML, binary, MTOM (msg trans optim mech)  WS-* protocols – WS-Security, …
  • 8.
    CHANNEL INTERFACES  publicinterface IOutputChannel : IChannel { void Send(Message msg); }  public interface IInputChannel : IChannel { Message Receive(); }  public interface IDuplexChannel : IOutputChannel, IInputChannel {}  public interface IRequestChannel : IChannel { Message Request(Message msg); }  public interface IReplyChannel : IChannel { IRequestContext ReceiveRequest(); }  public interface IRequestContext : Idisposable { Message RequestMessage { get; } void Reply(Message msg); }
  • 9.
    SERVICE CONTRACT  <%@ServiceHost Language=“C#” Service=“MyService” %> [ServiceContract] public interface IMyService { [OperationContract] string Hello( string name); } public class MyService : IMyService { public string Hello(string name) { return “Hello “ + name; } }
  • 10.
    HOSTS  WCF Servicescan be hosted in:  Internet Information Services (IIS)  Very similar to web services  Windows services  Exposing windows service in style of WS  Console and Winform applications  New style for socket like functionality
  • 11.
    OTHER TOPICS  WCFSecurity  Credentials and claims (evidence)  Transport-level security  Message-level security  Federated security model  Authorization  Auditing
  • 12.
    OTHER FEATURES  WCFSupports transactions  ACID properties  Atomicity  composite operations treated as a unit  Consistency  Operations succeed or the system is returned to prior state  Isolation  Each transaction is independent and isolated from other transactions  Durability  If an operation succeeds it becomes durable, e.g., committed to a database or other persistant store
  • 13.
    CONCLUSION  Convergence ofprogramming models  Desktop Application  Web Application  Windows Services  Flexible hosting options  Flexible abstractions
  • 14.
    we provide onlineand classroom training for WCF For More Details www.asit.amcsquare.com Wise Machines India Pvt Ltd #360, Sri Sai Padma Arcade, Varthur Main Road, Ramagondanahalli, Whitefiled ,Bangalore – 560066. We also having Branches in Hyderabad & Chennai