SlideShare une entreprise Scribd logo
1  sur  20
Overview of REST Service
and ASP.NET WEB API
From: Pankaj Bajaj
Agenda
• Why Services ?
• Type of Services ?
• What is REST ?
• Features of REST
• Web API Overview
• SOAP vs. REST
Continuous learning is the minimum requirement for success in any field.
Why we need Services
Continuous learning is the minimum requirement for success in any field.
Service & SOA
Service ?
o A Service is a self-contained unit of software that performs a specific task.
o A Service is a reusable component.
o A Service changes business data from one state to another.
o If you can describe a component in WSDL, it is a Service.
SOA is a software architecture model
in which business functionality are logically grouped and encapsulated into
• self contained,
• distinct and reusable units called services that
• represent a high level business concept
• can be distributed over a network
• can be reused to create new business applications
• contain contract with specification of the purpose, functionality,
interfaces constraints, usage of the business functional
Continuous learning is the minimum requirement for success in any field.
Type of Services
Big Web Services:
Big web services are based on SOAP standard and often contain
a WSDL to describe the interface that the web service offers. The
details of the contract may include messages, operations,
bindings, and the location of the web service.
A- Address
B- Binding
C-Contract
REST Services:
RESTful web services are based on the way how web works. REST
is neither a standard nor a protocol. It is just an architectural style
like say for example client-server architecture. It’s based on HTTP.
Continuous learning is the minimum requirement for success in any field.
What is REST
REST: Representational State Transfer
“REST is an architectural style not an protocol.”
The term representational state transfer was introduced and
defined in year 2000 by Roy Fielding during his research in PhD
programme. REST has been applied to describe desired web
architecture, to identify existing problems, to compare
alternative solutions and to ensure that protocol extensions
would not violate the core constraints that make the web
successful.
Continuous learning is the minimum requirement for success in any field.
Resource Oriented Architecture (ROA)
An Entity, Item or just a thing you want to expose is a Resource
Resource-oriented architecture (ROA) is a style of software architecture
and programming paradigm for designing and developing software in
the form of resources with "RESTful" interfaces. These resources are
software components (discrete pieces of code and/or data structures)
which can be reused for different purposes.
Features of ROA:
• Addressability: Addressable applications expose a URI for every
piece of information they might conceivably serve.
• Statelessness : Statelessness means that every HTTP request happens
in complete isolation. The server never relies on information from
previous requests.
.
• A uniform interface : Resource should be called using an HTTP Verbs
(Get POST,PUT,DELETE)
Continuous learning is the minimum requirement for success in any field.
Features of REST
• Platform-independent (you don't care if the server is Unix, the
client is a Mac, or anything else)
• Language-independent (C# can talk to Java, etc.)
• HTTP Based
• Can easily be used in the presence of firewalls.
• Limited bandwidth and resources
• Totally stateless operations
• Caching
• Reach More Clients(Mobile , Tablet etc.)
• Lightweight hosting and scalable with Cloud
Continuous learning is the minimum requirement for success in any field.
ASP.net WEB API
Continuous learning is the minimum requirement for success in any field.
ASP.NET Web API
ASP.Net Web API is a framework that makes it easy to
build HTTP Services that reach a broad range of
clients, including browsers and mobile devices. It's an
ideal platform for building RESTFul Services on .Net
Framework
Continuous learning is the minimum requirement for success in any field.
Features of WEB API
• Strong Support for URL Routing to produce clean URLs using
familiar MVC style routing semantics
• Content Negotiation based on Accept headers for request
and response serialization
• Support for a host of supported output formats including JSON,
XML, ATOM
• ODATA Support
• Strong default support for REST semantics
• Very extensible, based on MVC like extensibility model of
Formatters and Filters
• Self-hostable in non-Web applications
• Testable using testing concepts similar to MVC
Continuous learning is the minimum requirement for success in any field.
HTTP Verbs
• GET
This is used to retrieve resourceresources.
• POST
This is used to add new resource.
• PUT
This is used to update resource.
• DELETE
This is used to delete resource.
Continuous learning is the minimum requirement for success in any field.
SOAP vs. REST
Continuous learning is the minimum requirement for success in any field.
SOAP Features
• Asynchronous processing and invocation;
• Formal contracts;
• Stateful operations
• Supports Messaging Pattern
Continuous learning is the minimum requirement for success in any field.
SOAP vs. REST
Continuous learning is the minimum requirement for success in any field.
SOAP REST
In SOAP along with data a lot of
other meta data also needs to get
transferred with each request and
response. This makes the payload
heavy even for small data
only the data will be traveling to and
fro from the server because the
capabilities of the service are
mapped to the URIs and protocols
In SOAP there is need to create the
proxy at client side. These proxies
will do the marshaling and un-
marshaling of SOAP WSDL and
make the communication between
the application and the web service
possible. The problem with this
proxy is that if the service is updated
and the proxy on the client is not
then the application might behave
incorrectly
there is no need to have a proxy at
the client end because its only data
that is coming and the application
can directly receive and process the
data
SOAP vs. REST
Continuous learning is the minimum requirement for success in any field.
Usage
SOAP REST
When designing an application of
service oriented architecture which
interconnects many systems and uses
many transport channels, it is better to
use SOAP.
When we plan to design an
application to be used exclusively on
the web, and also when we need a
quick client integration.
Complex Applications which need
different kind of bindings and
protocols
Simple applications which major
depends on CRUD operations.
Continuous learning is the minimum requirement for success in any field.
ASP.Net Web API vs. WCF
Feature ASP.Net Web API WCF
Transport Channel HTTP(s) TCP, UDP, MSMQ, NamedPipes,
HTTP(s), Custom
Protocol HTTP WS-*
Types CLR Types DataContract
Message Format Text (xml, json) SOAP+XML
Service Interface HTTPMethod, URLPattern Service Contract
State Management Stateless Stateless with Per Call
Cache Built-n to HTTP Prefer
application control
Handled by application
Error Handling Exceptions, HTTP Status
codes filters
Faults, Behaviors
Hosting IIS, Self Host IIS, Self Host
Client IApiExplorer
Shared Libraries
Proxy Class
Shared Libraries
Continuous learning is the minimum requirement for success in any field.
WCF REST Service vs. ASP.net Web API
WCF REST Service ASP.NET Web API
Service => Web API controller
Operation => Action
Service contract => n/a
Endpoint => n/a
URI Template => ASP.NET Routing
Message handlers => Same
Formatters => Same
Operation handlers => Filters, model binders
Continuous learning is the minimum requirement for success in any field.
• No Metadata
• Only HTTP Security
• Complexity kills
Continuous learning is the minimum requirement for success in any field.
Disadvantage of REST

Contenu connexe

Tendances

REST API Design & Development
REST API Design & DevelopmentREST API Design & Development
REST API Design & DevelopmentAshok Pundit
 
REST-API introduction for developers
REST-API introduction for developersREST-API introduction for developers
REST-API introduction for developersPatrick Savalle
 
Rest & RESTful WebServices
Rest & RESTful WebServicesRest & RESTful WebServices
Rest & RESTful WebServicesPrateek Tandon
 
Introduction to API
Introduction to APIIntroduction to API
Introduction to APIrajnishjha29
 
Api gateway in microservices
Api gateway in microservicesApi gateway in microservices
Api gateway in microservicesKunal Hire
 
Best Practices in Web Service Design
Best Practices in Web Service DesignBest Practices in Web Service Design
Best Practices in Web Service DesignLorna Mitchell
 
Web Services (SOAP, WSDL, UDDI)
Web Services (SOAP, WSDL, UDDI)Web Services (SOAP, WSDL, UDDI)
Web Services (SOAP, WSDL, UDDI)Peter R. Egli
 
Angular vs React vs Vue | Javascript Frameworks Comparison | Which One You Sh...
Angular vs React vs Vue | Javascript Frameworks Comparison | Which One You Sh...Angular vs React vs Vue | Javascript Frameworks Comparison | Which One You Sh...
Angular vs React vs Vue | Javascript Frameworks Comparison | Which One You Sh...Edureka!
 
ASP.NET Web API
ASP.NET Web APIASP.NET Web API
ASP.NET Web APIhabib_786
 
Understanding REST
Understanding RESTUnderstanding REST
Understanding RESTNitin Pande
 
Windows Communication Foundation (WCF)
Windows Communication Foundation (WCF)Windows Communication Foundation (WCF)
Windows Communication Foundation (WCF)Peter R. Egli
 

Tendances (20)

REST API
REST APIREST API
REST API
 
REST API Design & Development
REST API Design & DevelopmentREST API Design & Development
REST API Design & Development
 
An Introduction To REST API
An Introduction To REST APIAn Introduction To REST API
An Introduction To REST API
 
REST-API introduction for developers
REST-API introduction for developersREST-API introduction for developers
REST-API introduction for developers
 
Rest & RESTful WebServices
Rest & RESTful WebServicesRest & RESTful WebServices
Rest & RESTful WebServices
 
Introduction to API
Introduction to APIIntroduction to API
Introduction to API
 
C# REST API
C# REST APIC# REST API
C# REST API
 
Windows Communication Foundation (WCF)
Windows Communication Foundation (WCF)Windows Communication Foundation (WCF)
Windows Communication Foundation (WCF)
 
Java Spring
Java SpringJava Spring
Java Spring
 
Api gateway in microservices
Api gateway in microservicesApi gateway in microservices
Api gateway in microservices
 
Best Practices in Web Service Design
Best Practices in Web Service DesignBest Practices in Web Service Design
Best Practices in Web Service Design
 
Web api
Web apiWeb api
Web api
 
Web Services (SOAP, WSDL, UDDI)
Web Services (SOAP, WSDL, UDDI)Web Services (SOAP, WSDL, UDDI)
Web Services (SOAP, WSDL, UDDI)
 
Angular vs React vs Vue | Javascript Frameworks Comparison | Which One You Sh...
Angular vs React vs Vue | Javascript Frameworks Comparison | Which One You Sh...Angular vs React vs Vue | Javascript Frameworks Comparison | Which One You Sh...
Angular vs React vs Vue | Javascript Frameworks Comparison | Which One You Sh...
 
.Net Core
.Net Core.Net Core
.Net Core
 
ASP.NET Web API
ASP.NET Web APIASP.NET Web API
ASP.NET Web API
 
Rest api with node js and express
Rest api with node js and expressRest api with node js and express
Rest api with node js and express
 
Understanding REST
Understanding RESTUnderstanding REST
Understanding REST
 
Windows Communication Foundation (WCF)
Windows Communication Foundation (WCF)Windows Communication Foundation (WCF)
Windows Communication Foundation (WCF)
 
React introduction
React introductionReact introduction
React introduction
 

En vedette

C# ASP.NET WEB API APPLICATION DEVELOPMENT
C# ASP.NET WEB API APPLICATION DEVELOPMENTC# ASP.NET WEB API APPLICATION DEVELOPMENT
C# ASP.NET WEB API APPLICATION DEVELOPMENTDr. Awase Khirni Syed
 
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
 
The ASP.NET Web API for Beginners
The ASP.NET Web API for BeginnersThe ASP.NET Web API for Beginners
The ASP.NET Web API for BeginnersKevin Hazzard
 
REST and ASP.NET Web API (Tunisia)
REST and ASP.NET Web API (Tunisia)REST and ASP.NET Web API (Tunisia)
REST and ASP.NET Web API (Tunisia)Jef Claes
 
WCF tutorial
WCF tutorialWCF tutorial
WCF tutorialAbhi Arya
 
The Full Power of ASP.NET Web API
The Full Power of ASP.NET Web APIThe Full Power of ASP.NET Web API
The Full Power of ASP.NET Web APIEyal Vardi
 
ASP.NET Mvc 4 web api
ASP.NET Mvc 4 web apiASP.NET Mvc 4 web api
ASP.NET Mvc 4 web apiTiago Knoch
 
ASP.NET Web API and HTTP Fundamentals
ASP.NET Web API and HTTP FundamentalsASP.NET Web API and HTTP Fundamentals
ASP.NET Web API and HTTP FundamentalsIdo Flatow
 
Colin Bowern - The Not So Scary Side Of Asp.Net – Model View Controller In Th...
Colin Bowern - The Not So Scary Side Of Asp.Net – Model View Controller In Th...Colin Bowern - The Not So Scary Side Of Asp.Net – Model View Controller In Th...
Colin Bowern - The Not So Scary Side Of Asp.Net – Model View Controller In Th...Refresh Events
 
Jonathan Dunn - Talking You Down from the Bleeding Edge
Jonathan Dunn - Talking You Down from the Bleeding EdgeJonathan Dunn - Talking You Down from the Bleeding Edge
Jonathan Dunn - Talking You Down from the Bleeding EdgeRefresh Events
 
Cloud Based Enterprise Apps using Everlive
Cloud Based Enterprise Apps using EverliveCloud Based Enterprise Apps using Everlive
Cloud Based Enterprise Apps using EverliveDhananjay Kumar
 
Glance at Visual Studio 2013 ASP.NET and Web tools 2013
Glance at Visual Studio 2013  ASP.NET and Web tools 2013Glance at Visual Studio 2013  ASP.NET and Web tools 2013
Glance at Visual Studio 2013 ASP.NET and Web tools 2013Shravan Kumar Kasagoni
 
Ankoder System Architecture
Ankoder System ArchitectureAnkoder System Architecture
Ankoder System ArchitectureRex Chung
 
OAuth-as-a-service using ASP.NET Web API and Windows Azure Access Control
OAuth-as-a-service using ASP.NET Web API and Windows Azure Access ControlOAuth-as-a-service using ASP.NET Web API and Windows Azure Access Control
OAuth-as-a-service using ASP.NET Web API and Windows Azure Access ControlMaarten Balliauw
 

En vedette (20)

C# ASP.NET WEB API APPLICATION DEVELOPMENT
C# ASP.NET WEB API APPLICATION DEVELOPMENTC# ASP.NET WEB API APPLICATION DEVELOPMENT
C# ASP.NET WEB API APPLICATION DEVELOPMENT
 
ASP.NET WEB API
ASP.NET WEB APIASP.NET WEB API
ASP.NET WEB API
 
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
 
Excellent rest using asp.net web api
Excellent rest using asp.net web apiExcellent rest using asp.net web api
Excellent rest using asp.net web api
 
The ASP.NET Web API for Beginners
The ASP.NET Web API for BeginnersThe ASP.NET Web API for Beginners
The ASP.NET Web API for Beginners
 
REST and ASP.NET Web API (Tunisia)
REST and ASP.NET Web API (Tunisia)REST and ASP.NET Web API (Tunisia)
REST and ASP.NET Web API (Tunisia)
 
WCF tutorial
WCF tutorialWCF tutorial
WCF tutorial
 
The Full Power of ASP.NET Web API
The Full Power of ASP.NET Web APIThe Full Power of ASP.NET Web API
The Full Power of ASP.NET Web API
 
ASP.NET Mvc 4 web api
ASP.NET Mvc 4 web apiASP.NET Mvc 4 web api
ASP.NET Mvc 4 web api
 
ASP.NET Web API and HTTP Fundamentals
ASP.NET Web API and HTTP FundamentalsASP.NET Web API and HTTP Fundamentals
ASP.NET Web API and HTTP Fundamentals
 
Colin Bowern - The Not So Scary Side Of Asp.Net – Model View Controller In Th...
Colin Bowern - The Not So Scary Side Of Asp.Net – Model View Controller In Th...Colin Bowern - The Not So Scary Side Of Asp.Net – Model View Controller In Th...
Colin Bowern - The Not So Scary Side Of Asp.Net – Model View Controller In Th...
 
Jonathan Dunn - Talking You Down from the Bleeding Edge
Jonathan Dunn - Talking You Down from the Bleeding EdgeJonathan Dunn - Talking You Down from the Bleeding Edge
Jonathan Dunn - Talking You Down from the Bleeding Edge
 
Excellent rest met de web api
Excellent rest met de web apiExcellent rest met de web api
Excellent rest met de web api
 
Treeview listview
Treeview listviewTreeview listview
Treeview listview
 
Cloud Based Enterprise Apps using Everlive
Cloud Based Enterprise Apps using EverliveCloud Based Enterprise Apps using Everlive
Cloud Based Enterprise Apps using Everlive
 
Glance at Visual Studio 2013 ASP.NET and Web tools 2013
Glance at Visual Studio 2013  ASP.NET and Web tools 2013Glance at Visual Studio 2013  ASP.NET and Web tools 2013
Glance at Visual Studio 2013 ASP.NET and Web tools 2013
 
Ankoder System Architecture
Ankoder System ArchitectureAnkoder System Architecture
Ankoder System Architecture
 
REST != WebAPI
REST != WebAPIREST != WebAPI
REST != WebAPI
 
OAuth-as-a-service using ASP.NET Web API and Windows Azure Access Control
OAuth-as-a-service using ASP.NET Web API and Windows Azure Access ControlOAuth-as-a-service using ASP.NET Web API and Windows Azure Access Control
OAuth-as-a-service using ASP.NET Web API and Windows Azure Access Control
 
Active x
Active xActive x
Active x
 

Similaire à Overview of Rest Service and ASP.NET WEB API

REST Introduction.ppt
REST Introduction.pptREST Introduction.ppt
REST Introduction.pptKGSCSEPSGCT
 
Modern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdfModern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdfAparna Sharma
 
Connecting to Data from Windows Phone 8
Connecting to Data from Windows Phone 8Connecting to Data from Windows Phone 8
Connecting to Data from Windows Phone 8Woodruff Solutions LLC
 
Connecting to Data from Windows Phone 8 VSLive! Redmond 2013
Connecting to Data from Windows Phone 8 VSLive! Redmond 2013Connecting to Data from Windows Phone 8 VSLive! Redmond 2013
Connecting to Data from Windows Phone 8 VSLive! Redmond 2013Woodruff Solutions LLC
 
Connecting to Data from Windows Phone 8
Connecting to Data from Windows Phone 8Connecting to Data from Windows Phone 8
Connecting to Data from Windows Phone 8Woodruff Solutions LLC
 
Role of Rest vs. Web Services and EI
Role of Rest vs. Web Services and EIRole of Rest vs. Web Services and EI
Role of Rest vs. Web Services and EIWSO2
 
Best practices and advantages of REST APIs
Best practices and advantages of REST APIsBest practices and advantages of REST APIs
Best practices and advantages of REST APIsAparna Sharma
 
REST & RESTful APIs: The State of Confusion
REST & RESTful APIs: The State of ConfusionREST & RESTful APIs: The State of Confusion
REST & RESTful APIs: The State of ConfusionGlenn Antoine
 
Secc tutorials development and deployment of rest web services in java_v2.0
Secc tutorials development and deployment of rest web services in java_v2.0Secc tutorials development and deployment of rest web services in java_v2.0
Secc tutorials development and deployment of rest web services in java_v2.0Aravindharamanan S
 
Restful web services by Sreeni Inturi
Restful web services by Sreeni InturiRestful web services by Sreeni Inturi
Restful web services by Sreeni InturiSreeni I
 
Introduction to APIs (Application Programming Interface)
Introduction to APIs (Application Programming Interface) Introduction to APIs (Application Programming Interface)
Introduction to APIs (Application Programming Interface) Vibhawa Nirmal
 
Unit 3-SOA Technologies
Unit 3-SOA TechnologiesUnit 3-SOA Technologies
Unit 3-SOA Technologiesssuser3a47cb
 
APIs Design - Creation - Management.pdf
APIs Design - Creation - Management.pdfAPIs Design - Creation - Management.pdf
APIs Design - Creation - Management.pdfWilliamELKAIMPhd
 
RESTful applications: The why and how by Maikel Mardjan
RESTful applications: The why and how by Maikel MardjanRESTful applications: The why and how by Maikel Mardjan
RESTful applications: The why and how by Maikel MardjanJexia
 
Web service Introduction
Web service IntroductionWeb service Introduction
Web service IntroductionMadhukar Kumar
 

Similaire à Overview of Rest Service and ASP.NET WEB API (20)

Mini-Training: Let's have a rest
Mini-Training: Let's have a restMini-Training: Let's have a rest
Mini-Training: Let's have a rest
 
Wt unit 6 ppts web services
Wt unit 6 ppts web servicesWt unit 6 ppts web services
Wt unit 6 ppts web services
 
REST Introduction.ppt
REST Introduction.pptREST Introduction.ppt
REST Introduction.ppt
 
Modern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdfModern REST API design principles and rules.pdf
Modern REST API design principles and rules.pdf
 
Connecting to Data from Windows Phone 8
Connecting to Data from Windows Phone 8Connecting to Data from Windows Phone 8
Connecting to Data from Windows Phone 8
 
Connecting to Data from Windows Phone 8 VSLive! Redmond 2013
Connecting to Data from Windows Phone 8 VSLive! Redmond 2013Connecting to Data from Windows Phone 8 VSLive! Redmond 2013
Connecting to Data from Windows Phone 8 VSLive! Redmond 2013
 
Connecting to Data from Windows Phone 8
Connecting to Data from Windows Phone 8Connecting to Data from Windows Phone 8
Connecting to Data from Windows Phone 8
 
Api design part 1
Api design part 1Api design part 1
Api design part 1
 
Role of Rest vs. Web Services and EI
Role of Rest vs. Web Services and EIRole of Rest vs. Web Services and EI
Role of Rest vs. Web Services and EI
 
Rest web service
Rest web serviceRest web service
Rest web service
 
Best practices and advantages of REST APIs
Best practices and advantages of REST APIsBest practices and advantages of REST APIs
Best practices and advantages of REST APIs
 
REST full API Design
REST full API DesignREST full API Design
REST full API Design
 
REST & RESTful APIs: The State of Confusion
REST & RESTful APIs: The State of ConfusionREST & RESTful APIs: The State of Confusion
REST & RESTful APIs: The State of Confusion
 
Secc tutorials development and deployment of rest web services in java_v2.0
Secc tutorials development and deployment of rest web services in java_v2.0Secc tutorials development and deployment of rest web services in java_v2.0
Secc tutorials development and deployment of rest web services in java_v2.0
 
Restful web services by Sreeni Inturi
Restful web services by Sreeni InturiRestful web services by Sreeni Inturi
Restful web services by Sreeni Inturi
 
Introduction to APIs (Application Programming Interface)
Introduction to APIs (Application Programming Interface) Introduction to APIs (Application Programming Interface)
Introduction to APIs (Application Programming Interface)
 
Unit 3-SOA Technologies
Unit 3-SOA TechnologiesUnit 3-SOA Technologies
Unit 3-SOA Technologies
 
APIs Design - Creation - Management.pdf
APIs Design - Creation - Management.pdfAPIs Design - Creation - Management.pdf
APIs Design - Creation - Management.pdf
 
RESTful applications: The why and how by Maikel Mardjan
RESTful applications: The why and how by Maikel MardjanRESTful applications: The why and how by Maikel Mardjan
RESTful applications: The why and how by Maikel Mardjan
 
Web service Introduction
Web service IntroductionWeb service Introduction
Web service Introduction
 

Dernier

Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Modelsaagamshah0812
 
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...SelfMade bd
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfVishalKumarJha10
 
Chinsurah Escorts ☎️8617697112 Starting From 5K to 15K High Profile Escorts ...
Chinsurah Escorts ☎️8617697112  Starting From 5K to 15K High Profile Escorts ...Chinsurah Escorts ☎️8617697112  Starting From 5K to 15K High Profile Escorts ...
Chinsurah Escorts ☎️8617697112 Starting From 5K to 15K High Profile Escorts ...Nitya salvi
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfproinshot.com
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsJhone kinadey
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park masabamasaba
 
The title is not connected to what is inside
The title is not connected to what is insideThe title is not connected to what is inside
The title is not connected to what is insideshinachiaurasa2
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionOnePlan Solutions
 
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfonteinmasabamasaba
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park masabamasaba
 
Generic or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisionsGeneric or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisionsBert Jan Schrijver
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisamasabamasaba
 
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...masabamasaba
 
Architecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the pastArchitecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the pastPapp Krisztián
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisamasabamasaba
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...harshavardhanraghave
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesVictorSzoltysek
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...Shane Coughlan
 

Dernier (20)

Unlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language ModelsUnlocking the Future of AI Agents with Large Language Models
Unlocking the Future of AI Agents with Large Language Models
 
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
Crypto Cloud Review - How To Earn Up To $500 Per DAY Of Bitcoin 100% On AutoP...
 
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdfintroduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
introduction-to-automotive Andoid os-csimmonds-ndctechtown-2021.pdf
 
Chinsurah Escorts ☎️8617697112 Starting From 5K to 15K High Profile Escorts ...
Chinsurah Escorts ☎️8617697112  Starting From 5K to 15K High Profile Escorts ...Chinsurah Escorts ☎️8617697112  Starting From 5K to 15K High Profile Escorts ...
Chinsurah Escorts ☎️8617697112 Starting From 5K to 15K High Profile Escorts ...
 
Exploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdfExploring the Best Video Editing App.pdf
Exploring the Best Video Editing App.pdf
 
Right Money Management App For Your Financial Goals
Right Money Management App For Your Financial GoalsRight Money Management App For Your Financial Goals
Right Money Management App For Your Financial Goals
 
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park %in kempton park+277-882-255-28 abortion pills for sale in kempton park
%in kempton park+277-882-255-28 abortion pills for sale in kempton park
 
The title is not connected to what is inside
The title is not connected to what is insideThe title is not connected to what is inside
The title is not connected to what is inside
 
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) SolutionIntroducing Microsoft’s new Enterprise Work Management (EWM) Solution
Introducing Microsoft’s new Enterprise Work Management (EWM) Solution
 
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
%in kaalfontein+277-882-255-28 abortion pills for sale in kaalfontein
 
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park %in ivory park+277-882-255-28 abortion pills for sale in ivory park
%in ivory park+277-882-255-28 abortion pills for sale in ivory park
 
Generic or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisionsGeneric or specific? Making sensible software design decisions
Generic or specific? Making sensible software design decisions
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
%+27788225528 love spells in Atlanta Psychic Readings, Attraction spells,Brin...
 
Architecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the pastArchitecture decision records - How not to get lost in the past
Architecture decision records - How not to get lost in the past
 
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa%in tembisa+277-882-255-28 abortion pills for sale in tembisa
%in tembisa+277-882-255-28 abortion pills for sale in tembisa
 
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
Reassessing the Bedrock of Clinical Function Models: An Examination of Large ...
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM TechniquesAI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
AI Mastery 201: Elevating Your Workflow with Advanced LLM Techniques
 
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
OpenChain - The Ramifications of ISO/IEC 5230 and ISO/IEC 18974 for Legal Pro...
 

Overview of Rest Service and ASP.NET WEB API

  • 1. Overview of REST Service and ASP.NET WEB API From: Pankaj Bajaj
  • 2. Agenda • Why Services ? • Type of Services ? • What is REST ? • Features of REST • Web API Overview • SOAP vs. REST Continuous learning is the minimum requirement for success in any field.
  • 3. Why we need Services Continuous learning is the minimum requirement for success in any field.
  • 4. Service & SOA Service ? o A Service is a self-contained unit of software that performs a specific task. o A Service is a reusable component. o A Service changes business data from one state to another. o If you can describe a component in WSDL, it is a Service. SOA is a software architecture model in which business functionality are logically grouped and encapsulated into • self contained, • distinct and reusable units called services that • represent a high level business concept • can be distributed over a network • can be reused to create new business applications • contain contract with specification of the purpose, functionality, interfaces constraints, usage of the business functional Continuous learning is the minimum requirement for success in any field.
  • 5. Type of Services Big Web Services: Big web services are based on SOAP standard and often contain a WSDL to describe the interface that the web service offers. The details of the contract may include messages, operations, bindings, and the location of the web service. A- Address B- Binding C-Contract REST Services: RESTful web services are based on the way how web works. REST is neither a standard nor a protocol. It is just an architectural style like say for example client-server architecture. It’s based on HTTP. Continuous learning is the minimum requirement for success in any field.
  • 6. What is REST REST: Representational State Transfer “REST is an architectural style not an protocol.” The term representational state transfer was introduced and defined in year 2000 by Roy Fielding during his research in PhD programme. REST has been applied to describe desired web architecture, to identify existing problems, to compare alternative solutions and to ensure that protocol extensions would not violate the core constraints that make the web successful. Continuous learning is the minimum requirement for success in any field.
  • 7. Resource Oriented Architecture (ROA) An Entity, Item or just a thing you want to expose is a Resource Resource-oriented architecture (ROA) is a style of software architecture and programming paradigm for designing and developing software in the form of resources with "RESTful" interfaces. These resources are software components (discrete pieces of code and/or data structures) which can be reused for different purposes. Features of ROA: • Addressability: Addressable applications expose a URI for every piece of information they might conceivably serve. • Statelessness : Statelessness means that every HTTP request happens in complete isolation. The server never relies on information from previous requests. . • A uniform interface : Resource should be called using an HTTP Verbs (Get POST,PUT,DELETE) Continuous learning is the minimum requirement for success in any field.
  • 8. Features of REST • Platform-independent (you don't care if the server is Unix, the client is a Mac, or anything else) • Language-independent (C# can talk to Java, etc.) • HTTP Based • Can easily be used in the presence of firewalls. • Limited bandwidth and resources • Totally stateless operations • Caching • Reach More Clients(Mobile , Tablet etc.) • Lightweight hosting and scalable with Cloud Continuous learning is the minimum requirement for success in any field.
  • 9. ASP.net WEB API Continuous learning is the minimum requirement for success in any field.
  • 10. ASP.NET Web API ASP.Net Web API is a framework that makes it easy to build HTTP Services that reach a broad range of clients, including browsers and mobile devices. It's an ideal platform for building RESTFul Services on .Net Framework Continuous learning is the minimum requirement for success in any field.
  • 11. Features of WEB API • Strong Support for URL Routing to produce clean URLs using familiar MVC style routing semantics • Content Negotiation based on Accept headers for request and response serialization • Support for a host of supported output formats including JSON, XML, ATOM • ODATA Support • Strong default support for REST semantics • Very extensible, based on MVC like extensibility model of Formatters and Filters • Self-hostable in non-Web applications • Testable using testing concepts similar to MVC Continuous learning is the minimum requirement for success in any field.
  • 12. HTTP Verbs • GET This is used to retrieve resourceresources. • POST This is used to add new resource. • PUT This is used to update resource. • DELETE This is used to delete resource. Continuous learning is the minimum requirement for success in any field.
  • 13. SOAP vs. REST Continuous learning is the minimum requirement for success in any field.
  • 14. SOAP Features • Asynchronous processing and invocation; • Formal contracts; • Stateful operations • Supports Messaging Pattern Continuous learning is the minimum requirement for success in any field.
  • 15. SOAP vs. REST Continuous learning is the minimum requirement for success in any field. SOAP REST In SOAP along with data a lot of other meta data also needs to get transferred with each request and response. This makes the payload heavy even for small data only the data will be traveling to and fro from the server because the capabilities of the service are mapped to the URIs and protocols In SOAP there is need to create the proxy at client side. These proxies will do the marshaling and un- marshaling of SOAP WSDL and make the communication between the application and the web service possible. The problem with this proxy is that if the service is updated and the proxy on the client is not then the application might behave incorrectly there is no need to have a proxy at the client end because its only data that is coming and the application can directly receive and process the data
  • 16. SOAP vs. REST Continuous learning is the minimum requirement for success in any field.
  • 17. Usage SOAP REST When designing an application of service oriented architecture which interconnects many systems and uses many transport channels, it is better to use SOAP. When we plan to design an application to be used exclusively on the web, and also when we need a quick client integration. Complex Applications which need different kind of bindings and protocols Simple applications which major depends on CRUD operations. Continuous learning is the minimum requirement for success in any field.
  • 18. ASP.Net Web API vs. WCF Feature ASP.Net Web API WCF Transport Channel HTTP(s) TCP, UDP, MSMQ, NamedPipes, HTTP(s), Custom Protocol HTTP WS-* Types CLR Types DataContract Message Format Text (xml, json) SOAP+XML Service Interface HTTPMethod, URLPattern Service Contract State Management Stateless Stateless with Per Call Cache Built-n to HTTP Prefer application control Handled by application Error Handling Exceptions, HTTP Status codes filters Faults, Behaviors Hosting IIS, Self Host IIS, Self Host Client IApiExplorer Shared Libraries Proxy Class Shared Libraries Continuous learning is the minimum requirement for success in any field.
  • 19. WCF REST Service vs. ASP.net Web API WCF REST Service ASP.NET Web API Service => Web API controller Operation => Action Service contract => n/a Endpoint => n/a URI Template => ASP.NET Routing Message handlers => Same Formatters => Same Operation handlers => Filters, model binders Continuous learning is the minimum requirement for success in any field.
  • 20. • No Metadata • Only HTTP Security • Complexity kills Continuous learning is the minimum requirement for success in any field. Disadvantage of REST