ams confidential & proprietary international business and technology consultants 1 xml as a...
TRANSCRIPT
![Page 1: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/1.jpg)
1AMS confidential & proprietary
International Business and Technology Consultants
XML as a Document Exchange Format
Tom Loukas
AMS Center for Advanced Technologies
September 26th, 2001
![Page 2: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/2.jpg)
2AMS confidential & proprietary
Why XML?
To exchange data you must speak a common language
XML is well on its way to becoming that language
— Flexible self-describing language— Worldwide sanctioning bodies— Supported by most major software vendors— Already adopted by many industries
![Page 3: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/3.jpg)
3AMS confidential & proprietary
What is XML?
Extensible Markup Language Structured language using tags to
describe data elements with a document Designed to facilitate data exchange
over the internet Version 1.0 of spec released in 1998 by
World Wide Web Consortium (W3C) Many additions to spec since then
![Page 4: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/4.jpg)
4AMS confidential & proprietary
Some Design Goals for XML
Straightforward use over the Internet Support a wide variety of applications Ease of programmatic processing XML documents should be human-legible
and reasonably clear XML documents shall be easy to create
![Page 5: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/5.jpg)
5AMS confidential & proprietary
Sample XML Document
<purchaseOrder orderDate="1999-10-20">
<shipTo country="US">
<name>Alice Smith</name>
<street>123 Maple Street</street>
<city>Mill Valley</city>
<state>CA</state>
<zip>90952</zip>
</shipTo>
<items>
<item partNum="872-AA">
<productName>Lawnmower</productName>
<quantity>1</quantity>
<price>148.95</price>
</item>
Element tags
Attributes
Data
![Page 6: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/6.jpg)
6AMS confidential & proprietary
Sample XML Document (continued)
<item partNum="926-AA">
<productName>Baby Monitor</productName>
<quantity>1</quantity>
<price>39.98</price>
<shipDate>1999-05-21</shipDate>
</item>
</items>
</purchaseOrder>
Element tags
Attributes
Data
![Page 7: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/7.jpg)
7AMS confidential & proprietary
XML Document Definition - DTD
Part of XML version 1.0 Used to specify structure of an XML
document— Element names, element structure, attribute
names, valid value lists
Can be embedded within the XML document or specified via a location reference (e.g. a URL)
Uses non-XML syntax and lacks ability to specify data types
![Page 8: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/8.jpg)
Sample XML DTD
<!DOCTYPE purchaseOrder [
<!ELEMENT purchaseOrder (shipTo, Items) >
<!ATTLIST purchaseOrder orderDate CDATA #REQUIRED >
<!ELEMENT shipTo (name, street, city, state, zip) >
<!ATTLIST shipTo country CDATA #REQUIRED >
<!ELEMENT name (#PCDATA) >
<!ELEMENT street (#PCDATA) >
<!ELEMENT city (#PCDATA) >
<!ELEMENT state (#PCDATA) >
<!ELEMENT zip (#PCDATA) >
<!ELEMENT Items (item+) >
<!ELEMENT item (productName, quantity, USPrice) >
<!ATTLIST item partNum CDATA #REQUIRED >
<!ELEMENT productname (#PCDATA) >
<!ELEMENT quantity (#PCDATA) >
<!ELEMENT USPrice (#PCDATA) >
![Page 9: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/9.jpg)
9AMS confidential & proprietary
XML Document Definition - Schema
Created to address failings of original DTD specification
Support for data typing Enables more rigorous validation Uses XML syntax Finally became part of official spec in
May 2001
![Page 10: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/10.jpg)
10AMS confidential & proprietary
Sample XML Schema
<xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<xsd:element name="purchaseOrder" type="PurchaseOrderType"/>
<xsd:complexType name="PurchaseOrderType">
<xsd:sequence>
<xsd:element name="shipTo" type="USAddress"/>
<xsd:element name="items" type="Items"/>
</xsd:sequence>
<xsd:attribute name="orderDate" type="xsd:date"/>
</xsd:complexType>
![Page 11: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/11.jpg)
11AMS confidential & proprietary
Sample XML Schema (continued)
Definition of the USAddress complex type
<xsd:complexType name="USAddress">
<xsd:sequence>
<xsd:element name="name" type="xsd:string"/>
<xsd:element name="street" type="xsd:string"/>
<xsd:element name="city" type="xsd:string"/>
<xsd:element name="state" type="xsd:string"/>
<xsd:element name="zip" type="xsd:decimal"/>
</xsd:sequence
<xsd:attribute name="country" type="xsd:NMTOKEN” fixed="US"/>
</xsd:complexType>
![Page 12: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/12.jpg)
12AMS confidential & proprietary
Sample XML Schema (continued)
Definition of the USAddress complex type
<xsd:complexType name="Items">
<xsd:sequence>
<xsd:element name="item" minOccurs="0”
maxOccurs="unbounded">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="productName" type="xsd:string"/>
<xsd:element name="quantity">
<xsd:simpleType>
<xsd:restriction base="xsd:positiveInteger">
<xsd:maxExclusive value="100"/>
</xsd:restriction>
</xsd:simpleType>
</xsd:element>
![Page 13: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/13.jpg)
13AMS confidential & proprietary
Sample XML Schema (continued)
…more child elements of the “item” element …..
<xsd:element name="USPrice" type="xsd:decimal"/>
<xsd:element name="shipDate" type="xsd:date"
minOccurs="0"/>
</xsd:sequence>
<xsd:attribute name="partNum" type="xsd:string” use="required"/>
</xsd:complexType
</xsd:element>
</xsd:sequence
</xsd:complexType>
![Page 14: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/14.jpg)
14AMS confidential & proprietary
Manipulating XML Documents
Parsing— DOM (Document Object Model) Parsers— SAX (Simple API for XML) Parsers
Translating— XSLT processors— XML Mapping tools — Custom code
Editing— Text editors— Third party tools (e.g. XML Spy)
Storage and retrieval— Store as large text or binary object in an RDBMS— Map XML elements to columns of relational tables— Use specialized XML data store (e.g eXelon)
![Page 15: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/15.jpg)
15AMS confidential & proprietary
Major Uses of XML
Data and document exchanges (A2A, B2B, G2B, G2G)
As a metadata format XLANG for process definitions (Microsoft) XMI for metadata exchange
Separating content from presentation Emerging Web Services Paradigm
— Business functions accessible over the web via widely used protocols
— Developing Standards – SOAP: Invoking web services
– WSDL: Describing web services
– Others: UDDI, WSFL, ….
![Page 16: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/16.jpg)
16AMS confidential & proprietary
Sample Web Service invocation using SOAP and HTTP
POST /StockQuote HTTP/1.1Host: www.stockquoteserver.comContent-Type: text/xml; charset="utf-8"Content-Length: nnnnSOAPAction: "Some-URI"
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"> <SOAP-ENV:Body> <m:GetLastTradePrice xmlns:m="Some-URI"> <symbol>DIS</symbol> </m:GetLastTradePrice> </SOAP-ENV:Body> </SOAP-ENV:Envelope>
![Page 17: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/17.jpg)
17AMS confidential & proprietary
Sample Web Service response
HTTP/1.1 200 OKContent-Type: text/xml; charset="utf-8"Content-Length: nnnn
<SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" SOAP-ENV:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/> <SOAP-ENV:Body> <m:GetLastTradePriceResponse xmlns:m="Some-URI"> <Price>34.5</Price> </m:GetLastTradePriceResponse> </SOAP-ENV:Body></SOAP-ENV:Envelope>
![Page 18: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/18.jpg)
18AMS confidential & proprietary
Benefits of XML
Industry support IBM, Microsoft, Oracle, ….. Ariba, Commerceone, webMethods, ... SAP, Baan, Siebel, Peoplesoft, AMS, ….
Human readable Self describing New elements can be added readily
![Page 19: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/19.jpg)
19AMS confidential & proprietary
The Other Side of the Coin
Parsing overhead Tag data and text format result in
increased network utilization
![Page 20: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/20.jpg)
20AMS confidential & proprietary
XML Standards and Initiatives
XML specification itself - W3C Industry-specific XML vocabularies
FpML Financial Products Markup Language
Vendor driven XML standards cXML and xCBL
Open standards initiatives ebXML
Government XML initiatives xml.gov
![Page 21: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/21.jpg)
21AMS confidential & proprietary
Establishing XML standards for data exchange
Document types Document structure and content Document processing flow and rules
![Page 22: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/22.jpg)
22AMS confidential & proprietary
Document processing flow and rules
Organization A Organization B
Transmit order
Acknowledge receipt of order
Provide estimated ship date
Acknowledge receipt of ship date info
Indicate order shipped
Acknowledge receipt of shipping confirmation
Payment notification
Acknowledge payment notification
![Page 23: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/23.jpg)
23AMS confidential & proprietary
Other processing considerations
Transport protocols and security Error handling procedures
![Page 24: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/24.jpg)
24AMS confidential & proprietary
Standards Administration
Some things to consider: Who will participate in developing and
maintaining the standards? Where will the standard specifications
reside? (schemas, process definitions, etc)
What process will be used for approval consensus?
How will change requests be administered?
Others …...
![Page 25: AMS confidential & proprietary International Business and Technology Consultants 1 XML as a Document Exchange Format Tom Loukas AMS Center for Advanced](https://reader030.vdocuments.us/reader030/viewer/2022032804/56649e4e5503460f94b45342/html5/thumbnails/25.jpg)
25AMS confidential & proprietary
Thank you