SlideShare a Scribd company logo
1 of 14
Download to read offline
Naresh 
Information 
Technologies 
Nagaraju Bende 
MCPD.NET Sr Consultant,Trainer 
http://nbende.wordpress.com
Agenda – Session 4 
Consuming WCF Services 
VS.NET Role in building WCF Apps 
WCF Service Library & WCF Service
Data Contracts
Addresses 
system.serviceModel 
services 
endpoint 
address = http://localhost:8000/CustomerManager 
binding = basicHttpBinding 
contract = IContactManager 
/endpoint 
/services 
/system.serviceModel
system.serviceModel 
services 
endpoint 
address = net.tcp://localhost:8001/CustomerManager/ 
binding = netTcpBinding 
contract = IContactManager 
/endpoint 
/services 
/system.serviceModel
Agenda – Session 5 
Develop Real World WCF Service Library 
WCFTESTCLIENT.exe / WCFSVCHost.exe 
Host in Windows Service 
Configure more bindings
Agenda – Session 6 
WCF Service using Web Template 
Hosting in Web Server 
LinqToSql/ADO.NET Entities/WCF
Demo
IIS Hosting – simple 3 steps 
1 Create Virtual Directory in 
IIS 
Create .svc file for service
2 implementation 
3 Configuration of 
web.config for services
Agenda – Session 9 
Web Programming using WCF 
WCF for ASP.NET AJAX apps 
webHttpBinding new in 3.5, VS.NET role 
SOAP, JSON, POX, REST styles
Demo
webHttpBinding 
• New “web-friendly” WCF Binding in Fx 3.5 
– Allows for the development of RESTful services 
– Does not use SOAP envelopes 
– HTTP and HTTPS Transports Only 
• Supports several wire formats:
– XML 
– JSON 
– Binary (streams)

More Related Content

What's hot

Rails 4 & server sent events
Rails 4 & server sent eventsRails 4 & server sent events
Rails 4 & server sent eventsPiotr Karbownik
 
Server-Sent Events in Action
Server-Sent Events in ActionServer-Sent Events in Action
Server-Sent Events in ActionAndrei Rusu
 
Host, deploy & scale Blazor Server Apps
Host, deploy & scale Blazor Server AppsHost, deploy & scale Blazor Server Apps
Host, deploy & scale Blazor Server AppsJose Javier Columbie
 
Stored procedure in Mule
Stored procedure in MuleStored procedure in Mule
Stored procedure in MuleKhasim Saheb
 
WebSocketson WildFly
WebSocketson WildFly WebSocketson WildFly
WebSocketson WildFly JBUG London
 
Mule compatible technologies
Mule compatible technologiesMule compatible technologies
Mule compatible technologieshimajareddys
 
Websocket + Redis pubsub
Websocket + Redis pubsubWebsocket + Redis pubsub
Websocket + Redis pubsubKai Hsu
 
SOAP To REST API Proxy
SOAP To REST API ProxySOAP To REST API Proxy
SOAP To REST API ProxyVince Soliza
 
Mulesoft Using Groovy Component
Mulesoft Using Groovy ComponentMulesoft Using Groovy Component
Mulesoft Using Groovy Componentkumar gaurav
 
Live Streaming & Server Sent Events
Live Streaming & Server Sent EventsLive Streaming & Server Sent Events
Live Streaming & Server Sent Eventstkramar
 
Realtime web experience with signal r
Realtime web experience with signal rRealtime web experience with signal r
Realtime web experience with signal rRan Wahle
 
001. Introduction about React
001. Introduction about React001. Introduction about React
001. Introduction about ReactBinh Quan Duc
 
PharoDAYS 2015: Web 2.0 by Esteban Lorenzano
PharoDAYS 2015: Web 2.0 by Esteban LorenzanoPharoDAYS 2015: Web 2.0 by Esteban Lorenzano
PharoDAYS 2015: Web 2.0 by Esteban LorenzanoPharo
 
Automated Web App Performance Testing Using WebDriver
Automated Web App Performance Testing Using WebDriverAutomated Web App Performance Testing Using WebDriver
Automated Web App Performance Testing Using WebDriverseleniumconf
 
Applying microservices principles to front end
Applying microservices principles to front endApplying microservices principles to front end
Applying microservices principles to front endAhmed Elharouny
 

What's hot (20)

Rails 4 & server sent events
Rails 4 & server sent eventsRails 4 & server sent events
Rails 4 & server sent events
 
Introduction presentation
Introduction presentationIntroduction presentation
Introduction presentation
 
Server-Sent Events in Action
Server-Sent Events in ActionServer-Sent Events in Action
Server-Sent Events in Action
 
Host, deploy & scale Blazor Server Apps
Host, deploy & scale Blazor Server AppsHost, deploy & scale Blazor Server Apps
Host, deploy & scale Blazor Server Apps
 
Stored procedure in Mule
Stored procedure in MuleStored procedure in Mule
Stored procedure in Mule
 
WebSocketson WildFly
WebSocketson WildFly WebSocketson WildFly
WebSocketson WildFly
 
Mule and web services
Mule and web servicesMule and web services
Mule and web services
 
Mule compatible technologies
Mule compatible technologiesMule compatible technologies
Mule compatible technologies
 
Websocket + Redis pubsub
Websocket + Redis pubsubWebsocket + Redis pubsub
Websocket + Redis pubsub
 
SOAP To REST API Proxy
SOAP To REST API ProxySOAP To REST API Proxy
SOAP To REST API Proxy
 
Mulesoft Using Groovy Component
Mulesoft Using Groovy ComponentMulesoft Using Groovy Component
Mulesoft Using Groovy Component
 
Live Streaming & Server Sent Events
Live Streaming & Server Sent EventsLive Streaming & Server Sent Events
Live Streaming & Server Sent Events
 
Increase automation to rest
Increase automation to restIncrease automation to rest
Increase automation to rest
 
Vert.x
Vert.xVert.x
Vert.x
 
Realtime web experience with signal r
Realtime web experience with signal rRealtime web experience with signal r
Realtime web experience with signal r
 
001. Introduction about React
001. Introduction about React001. Introduction about React
001. Introduction about React
 
PharoDAYS 2015: Web 2.0 by Esteban Lorenzano
PharoDAYS 2015: Web 2.0 by Esteban LorenzanoPharoDAYS 2015: Web 2.0 by Esteban Lorenzano
PharoDAYS 2015: Web 2.0 by Esteban Lorenzano
 
Automated Web App Performance Testing Using WebDriver
Automated Web App Performance Testing Using WebDriverAutomated Web App Performance Testing Using WebDriver
Automated Web App Performance Testing Using WebDriver
 
Applying microservices principles to front end
Applying microservices principles to front endApplying microservices principles to front end
Applying microservices principles to front end
 
Mule technologies
Mule technologiesMule technologies
Mule technologies
 

Similar to Wcf remaining

Building+restful+webservice
Building+restful+webserviceBuilding+restful+webservice
Building+restful+webservicelonegunman
 
.Net3.5 Overview
.Net3.5 Overview.Net3.5 Overview
.Net3.5 Overviewllangit
 
ASP.NET Presentation
ASP.NET PresentationASP.NET Presentation
ASP.NET PresentationRasel Khan
 
Web API or WCF - An Architectural Comparison
Web API or WCF - An Architectural ComparisonWeb API or WCF - An Architectural Comparison
Web API or WCF - An Architectural ComparisonAdnan Masood
 
Net35 Overview
Net35 OverviewNet35 Overview
Net35 Overviewllangit
 
Dev con kolkata 2012 websockets
Dev con kolkata 2012   websocketsDev con kolkata 2012   websockets
Dev con kolkata 2012 websocketsSANKARSAN BOSE
 
Java servlet technology
Java servlet technologyJava servlet technology
Java servlet technologyMinal Maniar
 
Web Development using ASP.NET MVC at HEC
Web Development using ASP.NET MVC at HECWeb Development using ASP.NET MVC at HEC
Web Development using ASP.NET MVC at HECAdil Mughal
 
Building RESTful Services with WCF 4.0
Building RESTful Services with WCF 4.0Building RESTful Services with WCF 4.0
Building RESTful Services with WCF 4.0Saltmarch Media
 
Learning ASP.NET 5 and MVC 6
Learning ASP.NET 5 and MVC 6Learning ASP.NET 5 and MVC 6
Learning ASP.NET 5 and MVC 6Ido Flatow
 
All About Asp Net 4 0 Hosam Kamel
All About Asp Net 4 0  Hosam KamelAll About Asp Net 4 0  Hosam Kamel
All About Asp Net 4 0 Hosam KamelHosam Kamel
 
Usability AJAX and other ASP.NET Features
Usability AJAX and other ASP.NET FeaturesUsability AJAX and other ASP.NET Features
Usability AJAX and other ASP.NET FeaturesPeter Gfader
 
Using MVC with Kentico 8
Using MVC with Kentico 8Using MVC with Kentico 8
Using MVC with Kentico 8Thomas Robbins
 
ASP.NET - Building Web Application..in the right way!
ASP.NET - Building Web Application..in the right way!ASP.NET - Building Web Application..in the right way!
ASP.NET - Building Web Application..in the right way!Fioriela Bego
 

Similar to Wcf remaining (20)

Building+restful+webservice
Building+restful+webserviceBuilding+restful+webservice
Building+restful+webservice
 
Philly Tech Fest Iis
Philly Tech Fest IisPhilly Tech Fest Iis
Philly Tech Fest Iis
 
.Net3.5 Overview
.Net3.5 Overview.Net3.5 Overview
.Net3.5 Overview
 
ASP.NET Presentation
ASP.NET PresentationASP.NET Presentation
ASP.NET Presentation
 
Web API or WCF - An Architectural Comparison
Web API or WCF - An Architectural ComparisonWeb API or WCF - An Architectural Comparison
Web API or WCF - An Architectural Comparison
 
ASP.NET WEB API Training
ASP.NET WEB API TrainingASP.NET WEB API Training
ASP.NET WEB API Training
 
RESTful WCF Services
RESTful WCF ServicesRESTful WCF Services
RESTful WCF Services
 
Net35 Overview
Net35 OverviewNet35 Overview
Net35 Overview
 
Dev con kolkata 2012 websockets
Dev con kolkata 2012   websocketsDev con kolkata 2012   websockets
Dev con kolkata 2012 websockets
 
Java servlet technology
Java servlet technologyJava servlet technology
Java servlet technology
 
06 web api
06 web api06 web api
06 web api
 
Day7
Day7Day7
Day7
 
Web Development using ASP.NET MVC at HEC
Web Development using ASP.NET MVC at HECWeb Development using ASP.NET MVC at HEC
Web Development using ASP.NET MVC at HEC
 
Building RESTful Services with WCF 4.0
Building RESTful Services with WCF 4.0Building RESTful Services with WCF 4.0
Building RESTful Services with WCF 4.0
 
Learning ASP.NET 5 and MVC 6
Learning ASP.NET 5 and MVC 6Learning ASP.NET 5 and MVC 6
Learning ASP.NET 5 and MVC 6
 
ASP.NET OVERVIEW
ASP.NET OVERVIEWASP.NET OVERVIEW
ASP.NET OVERVIEW
 
All About Asp Net 4 0 Hosam Kamel
All About Asp Net 4 0  Hosam KamelAll About Asp Net 4 0  Hosam Kamel
All About Asp Net 4 0 Hosam Kamel
 
Usability AJAX and other ASP.NET Features
Usability AJAX and other ASP.NET FeaturesUsability AJAX and other ASP.NET Features
Usability AJAX and other ASP.NET Features
 
Using MVC with Kentico 8
Using MVC with Kentico 8Using MVC with Kentico 8
Using MVC with Kentico 8
 
ASP.NET - Building Web Application..in the right way!
ASP.NET - Building Web Application..in the right way!ASP.NET - Building Web Application..in the right way!
ASP.NET - Building Web Application..in the right way!
 

Recently uploaded

Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr LapshynFwdays
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machinePadma Pradeep
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 3652toLead Limited
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxhariprasad279825
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitecturePixlogix Infotech
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek SchlawackFwdays
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024Lorenzo Miniero
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxNavinnSomaal
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024The Digital Insurer
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentationphoebematthew05
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsMiki Katsuragi
 

Recently uploaded (20)

Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
"Federated learning: out of reach no matter how close",Oleksandr Lapshyn
 
Install Stable Diffusion in windows machine
Install Stable Diffusion in windows machineInstall Stable Diffusion in windows machine
Install Stable Diffusion in windows machine
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort ServiceHot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
 
Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365Ensuring Technical Readiness For Copilot in Microsoft 365
Ensuring Technical Readiness For Copilot in Microsoft 365
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
Artificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptxArtificial intelligence in cctv survelliance.pptx
Artificial intelligence in cctv survelliance.pptx
 
Understanding the Laravel MVC Architecture
Understanding the Laravel MVC ArchitectureUnderstanding the Laravel MVC Architecture
Understanding the Laravel MVC Architecture
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptxE-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
E-Vehicle_Hacking_by_Parul Sharma_null_owasp.pptx
 
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
"Subclassing and Composition – A Pythonic Tour of Trade-Offs", Hynek Schlawack
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024SIP trunking in Janus @ Kamailio World 2024
SIP trunking in Janus @ Kamailio World 2024
 
SAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptxSAP Build Work Zone - Overview L2-L3.pptx
SAP Build Work Zone - Overview L2-L3.pptx
 
My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024My INSURER PTE LTD - Insurtech Innovation Award 2024
My INSURER PTE LTD - Insurtech Innovation Award 2024
 
costume and set research powerpoint presentation
costume and set research powerpoint presentationcostume and set research powerpoint presentation
costume and set research powerpoint presentation
 
Vertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering TipsVertex AI Gemini Prompt Engineering Tips
Vertex AI Gemini Prompt Engineering Tips
 

Wcf remaining

  • 1. Naresh Information Technologies Nagaraju Bende MCPD.NET Sr Consultant,Trainer http://nbende.wordpress.com
  • 2. Agenda – Session 4 Consuming WCF Services VS.NET Role in building WCF Apps WCF Service Library & WCF Service
  • 4. Addresses system.serviceModel services endpoint address = http://localhost:8000/CustomerManager binding = basicHttpBinding contract = IContactManager /endpoint /services /system.serviceModel
  • 5. system.serviceModel services endpoint address = net.tcp://localhost:8001/CustomerManager/ binding = netTcpBinding contract = IContactManager /endpoint /services /system.serviceModel
  • 6. Agenda – Session 5 Develop Real World WCF Service Library WCFTESTCLIENT.exe / WCFSVCHost.exe Host in Windows Service Configure more bindings
  • 7. Agenda – Session 6 WCF Service using Web Template Hosting in Web Server LinqToSql/ADO.NET Entities/WCF
  • 9. IIS Hosting – simple 3 steps 1 Create Virtual Directory in IIS Create .svc file for service
  • 10. 2 implementation 3 Configuration of web.config for services
  • 11. Agenda – Session 9 Web Programming using WCF WCF for ASP.NET AJAX apps webHttpBinding new in 3.5, VS.NET role SOAP, JSON, POX, REST styles
  • 12. Demo
  • 13. webHttpBinding • New “web-friendly” WCF Binding in Fx 3.5 – Allows for the development of RESTful services – Does not use SOAP envelopes – HTTP and HTTPS Transports Only • Supports several wire formats:
  • 14. – XML – JSON – Binary (streams)
  • 15. What is JSON? • JavaScript Object Notation • Format for bridging JavaScript and objects – Easier for browsers than XML • ASP.NET AJAX other AJAX toolkits use it – Other web-aware clients also (Silverlight, etc.)
  • 16. !
  • 17. WCF / AJAX Integration • WCF AJAX support in Visual Studio – Script manager, VS Project Templates • WCF automatically generates JS proxy • Usage pattern similar to existing one: – Add service to Script Manager control – Write JavaScript code to work with proxy • Configuration not required – Via the WebScriptServiceHostFactory (.svc file)
  • 18. Agenda – Session 10 SOAP, JSON, POX, REST styles WebGet and WebInvoke UriTemplate in 3.5
  • 19. Demo
  • 20. [WebGet] And [WebInvoke] • Binds a WCF operation to URI space and HTTP method • Indicate the HTTP Method for the operation – WebGet – Don’t make me write it – WebInvoke – All verbs other than GET (Method parameter takes in the name of the Verb)
  • 21. • Other Parameters – BodyStyle – Indicates whether the Request/ Response are wrapped or not – RequestFormat – Json or Xml – ResponseFormat – Json or Xml – UriTemplate – Rich binding to URI
  • 22. UriTemplate • String that allows you to define the structure of the URI, as well as to define “Holes” – The “Holes” are variables – You Bind the template with parameters to fill the holes
  • 23. • {productId} hole / variable gets bound to productId parameter in operation
  • 24. WCF REST Starter Kit • Microsoft.ServiceModel.Web.dll – New features supporting RESTful services • Visual Studio 2008 Templates – REST Collections/Singleton Services – Atom Feed/Atom Publishing Protocol – HTTP/POX Services
  • 25. • REST Samples • Codeplex Project – Released at PDC – Written by WCF team – Features may be included in .NET 4.0