SlideShare a Scribd company logo
1 of 26
Download to read offline
XML-RPC and SOAP
An introduction to two RPC system that use
open Internet standards.
What is RPC?
RPC stands for Remote Procedure Call.
RPC is a mechanism for making a procedure
call across applications or machines.
An RPC call involves calling a function with
certain parameters and expecting a result.
Both sides must agree on the format in
which data is passed to and fro.
What is XML-RPC?
XML-RPC implements RPC using open Web
standards.
Data is encoded (“marshalled”) in XML using
a special DTD for XML-RPC.
The RPC call is made using HTTP.
The application exporting the function must
implement or be attached to a HTTP server.
History of XML-RPC
XML-RPC was created
by Userland Software.
First implementation:
Frontier in April 1998.
Supported universally
now.
Userland also created
SOAP and RSS.
The Mechanics
Caller asks library to call a function on a
server with a parameter set.
Library encodes parameters in XML and
makes the call.
Server processes request and returns
results.
Library decodes results from XML and
returns results to caller.
Example Python Client
[jace@Jace jace]$ python
Python 2.2.2 (#1, 01/12/03, 07:51:34)
[GCC Apple cpp-precomp 6.14] on darwin
Type "help", "copyright", "credits" or "license" for
more information.
>>> from xmlrpclib import Server
>>>
Example Python Client
[jace@Jace jace]$ python
Python 2.2.2 (#1, 01/12/03, 07:51:34)
[GCC Apple cpp-precomp 6.14] on darwin
Type "help", "copyright", "credits" or "license" for
more information.
>>> from xmlrpclib import Server
>>> betty = Server("http://betty.userland.com")
>>>
Example Python Client
[jace@Jace jace]$ python
Python 2.2.2 (#1, 01/12/03, 07:51:34)
[GCC Apple cpp-precomp 6.14] on darwin
Type "help", "copyright", "credits" or "license" for
more information.
>>> from xmlrpclib import Server
>>> betty = Server("http://betty.userland.com")
>>> print betty.examples.getStateName(41)
Example Python Client
[jace@Jace jace]$ python
Python 2.2.2 (#1, 01/12/03, 07:51:34)
[GCC Apple cpp-precomp 6.14] on darwin
Type "help", "copyright", "credits" or "license" for
more information.
>>> from xmlrpclib import Server
>>> betty = Server("http://betty.userland.com")
>>> print betty.examples.getStateName(41)
South Dakota
>>>
Example Request
POST /RPC2 HTTP/1.0
Host: betty.userland.com
Content-Type: text/xml
...
<?xml version="1.0"?>
<methodCall>
<methodName>examples.getStateName</methodName>
<params>
<param>
<value><i4>41</i4></value>
</param>
</params>
</methodCall>
Example Response
HTTP/1.1 200 OK
Content-Type: text/xml
...
<?xml version="1.0"?>
<methodResponse>
<params>
<param>
<value><string>South Dakota</string></value>
</param>
</params>
</methodResponse>
Basic Parameter Types
Integer (4-byte, signed) <i4> or <int>
Boolean <boolean>
String <string>
Double Precision Floating Point <double>
Date/Time <dateTime.iso8601>
Binary <base64>
More Parameter Types
Array <array>
Collection of items of any data type.
Multiple types are allowed in one array.
Structure <struct>
A structure is a named array, also called a
dictionary or a hash table.
Example Array
Original:
[12, 'Egypt', FALSE, -31]
<array>
<data>
<value><i4>12</i4></value>
<value><string>Egypt</string></value>
<value><boolean>0</boolean></value>
<value><i4>-31</i4></value>
</data>
</array>
Example Structure
Original:
{'lowerBound': 18, 'upperBound': 139}
<struct>
<member>
<name>lowerBound</name>
<value><i4>18</i4></value>
</member>
<member>
<name>upperBound</name>
<value><i4>139</i4></value>
</member>
</struct>
Fault Responses
A function call may fail for some reason.
A failed response also uses HTTP code 200.
Instead of a <params> tag containing
results, a <fault> tag containing a fault
code and fault string is returned.
Both code and string are server defined.
Limitations
No introspection available.
No access to properties or variables. Only
function calls.
Can’t pass an object as a parameter. No
named parameters either.
HTTP and XML both have processing
overheads. Text consumes more bandwidth.
Advantages
Really simple. You can write a client in
minutes, a server in a little longer.
Lightweight. XML-RPC builds on existing
HTTP and XML server and client libraries.
Secure. HTTP already offers basic
authentication, SSL/TLS and cookie auth.
Who Uses XML-RPC?
Prominent Examples:
UserLand Software (Manila, Radio)
LiveJournal (now has an XML-RPC API)
Zope (transparent support for XML-RPC)
The KDE Project (kxmlrpc)
Microsoft (Windows NT API; unverified)
SOAP
Stands for Simple Object Access Protocol.
Attempts to overcome XML-RPC’s limits.
Is a W3C candidate recommendation.
Created by DevelopMentor, IBM, Lotus,
Microsoft and UserLand Software.
SOAP Over XML-RPC
SOAP provides for user-defined data types,
unlike XML-RPC’s limit of eight types.
SOAP with WSDL (Web Services
Description Language) supports object
introspection.
SOAP allows named parameters.
SOAP allows extensive customisation.
SOAP Over Others
Is firewall friendly. DCOM and CORBA
dynamically assign ports. SOAP doesn’t.
SOAP is vendor and platform independent.
Is not bound to a protocol. Can be
implemented over HTTP or FTP or SMTP.
HTTP is scalable and easy to administer.
Limitations of SOAP
Is neither simple nor lightweight nor easyto-use.
Specification not guaranteed stable yet.
Documentation contains errors.
Too many cooks working on the specification,
not co-operating with each other very well.
Not Covered Here
Defining an XML-RPC server.
Detailed examples of XML-RPC requests and
responses.
Details on SOAP.
Links
XML-RPC Specification:
http://www.xmlrpc.com/spec
SOAP Specification:
http://www.w3.org/TR/SOAP/
XML-RPC vs SOAP:
http://weblog.masukomi.org/
writings/xml-rpc_vs_soap.htm
Q&A

More Related Content

What's hot

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 apiMaurice De Beijer [MVP]
 
Rest presentation
Rest  presentationRest  presentation
Rest presentationsrividhyau
 
Restful webservices
Restful webservicesRestful webservices
Restful webservicesLuqman Shareef
 
ASP.NET WEB API
ASP.NET WEB APIASP.NET WEB API
ASP.NET WEB APIThang Chung
 
Web Services Tutorial
Web Services TutorialWeb Services Tutorial
Web Services TutorialLorna Mitchell
 
SOAP--Simple Object Access Protocol
SOAP--Simple Object Access ProtocolSOAP--Simple Object Access Protocol
SOAP--Simple Object Access ProtocolMasud Rahman
 
REST & RESTful Web Service
REST & RESTful Web ServiceREST & RESTful Web Service
REST & RESTful Web ServiceHoan Vu Tran
 
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
 
Overview of Rest Service and ASP.NET WEB API
Overview of Rest Service and ASP.NET WEB APIOverview of Rest Service and ASP.NET WEB API
Overview of Rest Service and ASP.NET WEB APIPankaj Bajaj
 
REST and ASP.NET Web API (Milan)
REST and ASP.NET Web API (Milan)REST and ASP.NET Web API (Milan)
REST and ASP.NET Web API (Milan)Jef Claes
 
Introduction to the Web API
Introduction to the Web APIIntroduction to the Web API
Introduction to the Web APIBrad Genereaux
 
Web services soap and rest by mandakini for TechGig
Web services soap and rest by mandakini for TechGigWeb services soap and rest by mandakini for TechGig
Web services soap and rest by mandakini for TechGigMandakini Kumari
 
RESTful web
RESTful webRESTful web
RESTful webAlvin Qi
 
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
 
Consuming RESTful services in PHP
Consuming RESTful services in PHPConsuming RESTful services in PHP
Consuming RESTful services in PHPZoran Jeremic
 

What's hot (20)

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
 
Rest presentation
Rest  presentationRest  presentation
Rest presentation
 
Restful webservices
Restful webservicesRestful webservices
Restful webservices
 
SOAP vs REST
SOAP vs RESTSOAP vs REST
SOAP vs REST
 
ASP.NET WEB API
ASP.NET WEB APIASP.NET WEB API
ASP.NET WEB API
 
Web Services Tutorial
Web Services TutorialWeb Services Tutorial
Web Services Tutorial
 
SOAP--Simple Object Access Protocol
SOAP--Simple Object Access ProtocolSOAP--Simple Object Access Protocol
SOAP--Simple Object Access Protocol
 
REST & RESTful Web Service
REST & RESTful Web ServiceREST & RESTful Web Service
REST & RESTful Web Service
 
ASP.NET WEB API Training
ASP.NET WEB API TrainingASP.NET WEB API Training
ASP.NET WEB API Training
 
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
 
Soap vs rest
Soap vs restSoap vs rest
Soap vs rest
 
Overview of Rest Service and ASP.NET WEB API
Overview of Rest Service and ASP.NET WEB APIOverview of Rest Service and ASP.NET WEB API
Overview of Rest Service and ASP.NET WEB API
 
REST and ASP.NET Web API (Milan)
REST and ASP.NET Web API (Milan)REST and ASP.NET Web API (Milan)
REST and ASP.NET Web API (Milan)
 
Overview of java web services
Overview of java web servicesOverview of java web services
Overview of java web services
 
Introduction to the Web API
Introduction to the Web APIIntroduction to the Web API
Introduction to the Web API
 
Web services soap and rest by mandakini for TechGig
Web services soap and rest by mandakini for TechGigWeb services soap and rest by mandakini for TechGig
Web services soap and rest by mandakini for TechGig
 
L18 REST API Design
L18 REST API DesignL18 REST API Design
L18 REST API Design
 
RESTful web
RESTful webRESTful web
RESTful web
 
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
 
Consuming RESTful services in PHP
Consuming RESTful services in PHPConsuming RESTful services in PHP
Consuming RESTful services in PHP
 

Similar to XML-RPC and SOAP (April 2003)

What I learned about APIs in my first year at Google
What I learned about APIs in my first year at GoogleWhat I learned about APIs in my first year at Google
What I learned about APIs in my first year at GoogleTim Burks
 
Networked APIs with swift
Networked APIs with swiftNetworked APIs with swift
Networked APIs with swiftTim Burks
 
CocoaConf: The Language of Mobile Software is APIs
CocoaConf: The Language of Mobile Software is APIsCocoaConf: The Language of Mobile Software is APIs
CocoaConf: The Language of Mobile Software is APIsTim Burks
 
Use perl creating web services with xml rpc
Use perl creating web services with xml rpcUse perl creating web services with xml rpc
Use perl creating web services with xml rpcJohnny Pork
 
Rapid java backend and api development for mobile devices
Rapid java backend and api development for mobile devicesRapid java backend and api development for mobile devices
Rapid java backend and api development for mobile devicesciklum_ods
 
Intro to web services
Intro to web servicesIntro to web services
Intro to web servicesNeil Ghosh
 
jkljklj
jkljkljjkljklj
jkljkljhoefo
 
Open Source XMPP for Cloud Services
Open Source XMPP for Cloud ServicesOpen Source XMPP for Cloud Services
Open Source XMPP for Cloud Servicesmattjive
 
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...apidays
 
Network programming in Java
Network programming in JavaNetwork programming in Java
Network programming in JavaTushar B Kute
 
apidays LIVE Jakarta - REST the events: REST APIs for Event-Driven Architectu...
apidays LIVE Jakarta - REST the events: REST APIs for Event-Driven Architectu...apidays LIVE Jakarta - REST the events: REST APIs for Event-Driven Architectu...
apidays LIVE Jakarta - REST the events: REST APIs for Event-Driven Architectu...apidays
 
Rpc Case Studies (Distributed computing)
Rpc Case Studies (Distributed computing)Rpc Case Studies (Distributed computing)
Rpc Case Studies (Distributed computing)Sri Prasanna
 
Java Networking
Java NetworkingJava Networking
Java NetworkingSunil OS
 
ASP.NET Core 3.0 Deep Dive
ASP.NET Core 3.0 Deep DiveASP.NET Core 3.0 Deep Dive
ASP.NET Core 3.0 Deep DiveJon Galloway
 
Networking Java Socket Programming
Networking Java Socket ProgrammingNetworking Java Socket Programming
Networking Java Socket ProgrammingMousmi Pawar
 
What you need to know about .NET Core 3.0 and beyond
What you need to know about .NET Core 3.0 and beyondWhat you need to know about .NET Core 3.0 and beyond
What you need to know about .NET Core 3.0 and beyondJon Galloway
 
Creating Great REST and gRPC API Experiences (in Swift)
Creating Great REST and gRPC API Experiences (in Swift)Creating Great REST and gRPC API Experiences (in Swift)
Creating Great REST and gRPC API Experiences (in Swift)Tim Burks
 
Connect Magento & OpenERP
Connect Magento & OpenERPConnect Magento & OpenERP
Connect Magento & OpenERPOpenerp VN
 
Soap Toolkit Dcphp
Soap Toolkit DcphpSoap Toolkit Dcphp
Soap Toolkit DcphpMichael Tutty
 

Similar to XML-RPC and SOAP (April 2003) (20)

What I learned about APIs in my first year at Google
What I learned about APIs in my first year at GoogleWhat I learned about APIs in my first year at Google
What I learned about APIs in my first year at Google
 
Networked APIs with swift
Networked APIs with swiftNetworked APIs with swift
Networked APIs with swift
 
CocoaConf: The Language of Mobile Software is APIs
CocoaConf: The Language of Mobile Software is APIsCocoaConf: The Language of Mobile Software is APIs
CocoaConf: The Language of Mobile Software is APIs
 
Use perl creating web services with xml rpc
Use perl creating web services with xml rpcUse perl creating web services with xml rpc
Use perl creating web services with xml rpc
 
Rapid java backend and api development for mobile devices
Rapid java backend and api development for mobile devicesRapid java backend and api development for mobile devices
Rapid java backend and api development for mobile devices
 
Intro to web services
Intro to web servicesIntro to web services
Intro to web services
 
jkljklj
jkljkljjkljklj
jkljklj
 
Open Source XMPP for Cloud Services
Open Source XMPP for Cloud ServicesOpen Source XMPP for Cloud Services
Open Source XMPP for Cloud Services
 
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...
apidays LIVE Helsinki - Implementing OpenAPI and GraphQL Services with gRPC b...
 
Network programming in Java
Network programming in JavaNetwork programming in Java
Network programming in Java
 
apidays LIVE Jakarta - REST the events: REST APIs for Event-Driven Architectu...
apidays LIVE Jakarta - REST the events: REST APIs for Event-Driven Architectu...apidays LIVE Jakarta - REST the events: REST APIs for Event-Driven Architectu...
apidays LIVE Jakarta - REST the events: REST APIs for Event-Driven Architectu...
 
Rpc Case Studies (Distributed computing)
Rpc Case Studies (Distributed computing)Rpc Case Studies (Distributed computing)
Rpc Case Studies (Distributed computing)
 
Java Networking
Java NetworkingJava Networking
Java Networking
 
ASP.NET Core 3.0 Deep Dive
ASP.NET Core 3.0 Deep DiveASP.NET Core 3.0 Deep Dive
ASP.NET Core 3.0 Deep Dive
 
Networking Java Socket Programming
Networking Java Socket ProgrammingNetworking Java Socket Programming
Networking Java Socket Programming
 
What you need to know about .NET Core 3.0 and beyond
What you need to know about .NET Core 3.0 and beyondWhat you need to know about .NET Core 3.0 and beyond
What you need to know about .NET Core 3.0 and beyond
 
Switch to Backend 2023
Switch to Backend 2023Switch to Backend 2023
Switch to Backend 2023
 
Creating Great REST and gRPC API Experiences (in Swift)
Creating Great REST and gRPC API Experiences (in Swift)Creating Great REST and gRPC API Experiences (in Swift)
Creating Great REST and gRPC API Experiences (in Swift)
 
Connect Magento & OpenERP
Connect Magento & OpenERPConnect Magento & OpenERP
Connect Magento & OpenERP
 
Soap Toolkit Dcphp
Soap Toolkit DcphpSoap Toolkit Dcphp
Soap Toolkit Dcphp
 

More from Kiran Jonnalagadda

AirJaldi photo rout (April 2008)
AirJaldi photo rout (April 2008)AirJaldi photo rout (April 2008)
AirJaldi photo rout (April 2008)Kiran Jonnalagadda
 
The medium without the message (April 2008)
The medium without the message (April 2008)The medium without the message (April 2008)
The medium without the message (April 2008)Kiran Jonnalagadda
 
Understanding technology in e-governance (December 2007)
Understanding technology in e-governance (December 2007)Understanding technology in e-governance (December 2007)
Understanding technology in e-governance (December 2007)Kiran Jonnalagadda
 
Namma service cash tracking system (January 2007)
Namma service cash tracking system (January 2007)Namma service cash tracking system (January 2007)
Namma service cash tracking system (January 2007)Kiran Jonnalagadda
 
What ails the Sarai Reader List? (August 2005)
What ails the Sarai Reader List? (August 2005)What ails the Sarai Reader List? (August 2005)
What ails the Sarai Reader List? (August 2005)Kiran Jonnalagadda
 
On blogging as a career (June 2005)
On blogging as a career (June 2005)On blogging as a career (June 2005)
On blogging as a career (June 2005)Kiran Jonnalagadda
 
Python's dynamic nature (rough slides, November 2004)
Python's dynamic nature (rough slides, November 2004)Python's dynamic nature (rough slides, November 2004)
Python's dynamic nature (rough slides, November 2004)Kiran Jonnalagadda
 
Python and Zope: An introduction (May 2004)
Python and Zope: An introduction (May 2004)Python and Zope: An introduction (May 2004)
Python and Zope: An introduction (May 2004)Kiran Jonnalagadda
 
Human database relations (March 2004)
Human database relations (March 2004)Human database relations (March 2004)
Human database relations (March 2004)Kiran Jonnalagadda
 
The technology of the Human Protein Reference Database (draft, 2003)
The technology of the Human Protein Reference Database (draft, 2003)The technology of the Human Protein Reference Database (draft, 2003)
The technology of the Human Protein Reference Database (draft, 2003)Kiran Jonnalagadda
 
Introduction to Plone (November 2003)
Introduction to Plone (November 2003)Introduction to Plone (November 2003)
Introduction to Plone (November 2003)Kiran Jonnalagadda
 
ZODB, the Zope Object Database (May 2003)
ZODB, the Zope Object Database (May 2003)ZODB, the Zope Object Database (May 2003)
ZODB, the Zope Object Database (May 2003)Kiran Jonnalagadda
 
Some dope on Zope (Jan 2002, Bangalore LUG)
Some dope on Zope (Jan 2002, Bangalore LUG)Some dope on Zope (Jan 2002, Bangalore LUG)
Some dope on Zope (Jan 2002, Bangalore LUG)Kiran Jonnalagadda
 
User Management with LastUser
User Management with LastUserUser Management with LastUser
User Management with LastUserKiran Jonnalagadda
 
Sustainability and bit-rot
Sustainability and bit-rotSustainability and bit-rot
Sustainability and bit-rotKiran Jonnalagadda
 
e-Governance in Karnataka: An introduction
e-Governance in Karnataka: An introductione-Governance in Karnataka: An introduction
e-Governance in Karnataka: An introductionKiran Jonnalagadda
 

More from Kiran Jonnalagadda (17)

AirJaldi photo rout (April 2008)
AirJaldi photo rout (April 2008)AirJaldi photo rout (April 2008)
AirJaldi photo rout (April 2008)
 
The medium without the message (April 2008)
The medium without the message (April 2008)The medium without the message (April 2008)
The medium without the message (April 2008)
 
Understanding technology in e-governance (December 2007)
Understanding technology in e-governance (December 2007)Understanding technology in e-governance (December 2007)
Understanding technology in e-governance (December 2007)
 
Namma service cash tracking system (January 2007)
Namma service cash tracking system (January 2007)Namma service cash tracking system (January 2007)
Namma service cash tracking system (January 2007)
 
What ails the Sarai Reader List? (August 2005)
What ails the Sarai Reader List? (August 2005)What ails the Sarai Reader List? (August 2005)
What ails the Sarai Reader List? (August 2005)
 
On blogging as a career (June 2005)
On blogging as a career (June 2005)On blogging as a career (June 2005)
On blogging as a career (June 2005)
 
Python's dynamic nature (rough slides, November 2004)
Python's dynamic nature (rough slides, November 2004)Python's dynamic nature (rough slides, November 2004)
Python's dynamic nature (rough slides, November 2004)
 
Python and Zope: An introduction (May 2004)
Python and Zope: An introduction (May 2004)Python and Zope: An introduction (May 2004)
Python and Zope: An introduction (May 2004)
 
Human database relations (March 2004)
Human database relations (March 2004)Human database relations (March 2004)
Human database relations (March 2004)
 
The technology of the Human Protein Reference Database (draft, 2003)
The technology of the Human Protein Reference Database (draft, 2003)The technology of the Human Protein Reference Database (draft, 2003)
The technology of the Human Protein Reference Database (draft, 2003)
 
Introduction to Plone (November 2003)
Introduction to Plone (November 2003)Introduction to Plone (November 2003)
Introduction to Plone (November 2003)
 
ZODB, the Zope Object Database (May 2003)
ZODB, the Zope Object Database (May 2003)ZODB, the Zope Object Database (May 2003)
ZODB, the Zope Object Database (May 2003)
 
Some dope on Zope (Jan 2002, Bangalore LUG)
Some dope on Zope (Jan 2002, Bangalore LUG)Some dope on Zope (Jan 2002, Bangalore LUG)
Some dope on Zope (Jan 2002, Bangalore LUG)
 
User Management with LastUser
User Management with LastUserUser Management with LastUser
User Management with LastUser
 
Sustainability and bit-rot
Sustainability and bit-rotSustainability and bit-rot
Sustainability and bit-rot
 
e-Governance in Karnataka: An introduction
e-Governance in Karnataka: An introductione-Governance in Karnataka: An introduction
e-Governance in Karnataka: An introduction
 
Cyberpunk Sci-Fi
Cyberpunk Sci-FiCyberpunk Sci-Fi
Cyberpunk Sci-Fi
 

Recently uploaded

TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherRemote DBA Services
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...apidays
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbuapidays
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Zilliz
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native ApplicationsWSO2
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...apidays
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...apidays
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdflior mazor
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...apidays
 

Recently uploaded (20)

TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
+971581248768>> SAFE AND ORIGINAL ABORTION PILLS FOR SALE IN DUBAI AND ABUDHA...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu SubbuApidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
Apidays Singapore 2024 - Modernizing Securities Finance by Madhu Subbu
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 

XML-RPC and SOAP (April 2003)

  • 1. XML-RPC and SOAP An introduction to two RPC system that use open Internet standards.
  • 2. What is RPC? RPC stands for Remote Procedure Call. RPC is a mechanism for making a procedure call across applications or machines. An RPC call involves calling a function with certain parameters and expecting a result. Both sides must agree on the format in which data is passed to and fro.
  • 3. What is XML-RPC? XML-RPC implements RPC using open Web standards. Data is encoded (“marshalled”) in XML using a special DTD for XML-RPC. The RPC call is made using HTTP. The application exporting the function must implement or be attached to a HTTP server.
  • 4. History of XML-RPC XML-RPC was created by Userland Software. First implementation: Frontier in April 1998. Supported universally now. Userland also created SOAP and RSS.
  • 5. The Mechanics Caller asks library to call a function on a server with a parameter set. Library encodes parameters in XML and makes the call. Server processes request and returns results. Library decodes results from XML and returns results to caller.
  • 6. Example Python Client [jace@Jace jace]$ python Python 2.2.2 (#1, 01/12/03, 07:51:34) [GCC Apple cpp-precomp 6.14] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> from xmlrpclib import Server >>>
  • 7. Example Python Client [jace@Jace jace]$ python Python 2.2.2 (#1, 01/12/03, 07:51:34) [GCC Apple cpp-precomp 6.14] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> from xmlrpclib import Server >>> betty = Server("http://betty.userland.com") >>>
  • 8. Example Python Client [jace@Jace jace]$ python Python 2.2.2 (#1, 01/12/03, 07:51:34) [GCC Apple cpp-precomp 6.14] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> from xmlrpclib import Server >>> betty = Server("http://betty.userland.com") >>> print betty.examples.getStateName(41)
  • 9. Example Python Client [jace@Jace jace]$ python Python 2.2.2 (#1, 01/12/03, 07:51:34) [GCC Apple cpp-precomp 6.14] on darwin Type "help", "copyright", "credits" or "license" for more information. >>> from xmlrpclib import Server >>> betty = Server("http://betty.userland.com") >>> print betty.examples.getStateName(41) South Dakota >>>
  • 10. Example Request POST /RPC2 HTTP/1.0 Host: betty.userland.com Content-Type: text/xml ... <?xml version="1.0"?> <methodCall> <methodName>examples.getStateName</methodName> <params> <param> <value><i4>41</i4></value> </param> </params> </methodCall>
  • 11. Example Response HTTP/1.1 200 OK Content-Type: text/xml ... <?xml version="1.0"?> <methodResponse> <params> <param> <value><string>South Dakota</string></value> </param> </params> </methodResponse>
  • 12. Basic Parameter Types Integer (4-byte, signed) <i4> or <int> Boolean <boolean> String <string> Double Precision Floating Point <double> Date/Time <dateTime.iso8601> Binary <base64>
  • 13. More Parameter Types Array <array> Collection of items of any data type. Multiple types are allowed in one array. Structure <struct> A structure is a named array, also called a dictionary or a hash table.
  • 14. Example Array Original: [12, 'Egypt', FALSE, -31] <array> <data> <value><i4>12</i4></value> <value><string>Egypt</string></value> <value><boolean>0</boolean></value> <value><i4>-31</i4></value> </data> </array>
  • 15. Example Structure Original: {'lowerBound': 18, 'upperBound': 139} <struct> <member> <name>lowerBound</name> <value><i4>18</i4></value> </member> <member> <name>upperBound</name> <value><i4>139</i4></value> </member> </struct>
  • 16. Fault Responses A function call may fail for some reason. A failed response also uses HTTP code 200. Instead of a <params> tag containing results, a <fault> tag containing a fault code and fault string is returned. Both code and string are server defined.
  • 17. Limitations No introspection available. No access to properties or variables. Only function calls. Can’t pass an object as a parameter. No named parameters either. HTTP and XML both have processing overheads. Text consumes more bandwidth.
  • 18. Advantages Really simple. You can write a client in minutes, a server in a little longer. Lightweight. XML-RPC builds on existing HTTP and XML server and client libraries. Secure. HTTP already offers basic authentication, SSL/TLS and cookie auth.
  • 19. Who Uses XML-RPC? Prominent Examples: UserLand Software (Manila, Radio) LiveJournal (now has an XML-RPC API) Zope (transparent support for XML-RPC) The KDE Project (kxmlrpc) Microsoft (Windows NT API; unverified)
  • 20. SOAP Stands for Simple Object Access Protocol. Attempts to overcome XML-RPC’s limits. Is a W3C candidate recommendation. Created by DevelopMentor, IBM, Lotus, Microsoft and UserLand Software.
  • 21. SOAP Over XML-RPC SOAP provides for user-defined data types, unlike XML-RPC’s limit of eight types. SOAP with WSDL (Web Services Description Language) supports object introspection. SOAP allows named parameters. SOAP allows extensive customisation.
  • 22. SOAP Over Others Is firewall friendly. DCOM and CORBA dynamically assign ports. SOAP doesn’t. SOAP is vendor and platform independent. Is not bound to a protocol. Can be implemented over HTTP or FTP or SMTP. HTTP is scalable and easy to administer.
  • 23. Limitations of SOAP Is neither simple nor lightweight nor easyto-use. Specification not guaranteed stable yet. Documentation contains errors. Too many cooks working on the specification, not co-operating with each other very well.
  • 24. Not Covered Here Defining an XML-RPC server. Detailed examples of XML-RPC requests and responses. Details on SOAP.
  • 26. Q&A