<?xml version='1.0' encoding='UTF-8'?>
<?xml-stylesheet type="text/xsl" href="xmlspec.xsl"?>
<!DOCTYPE spec PUBLIC "-//W3C//DTD Specification V2.2//EN" "xmlspec.dtd"[
<!ENTITY DD "16">
<!ENTITY MM "05">
<!ENTITY month "May">
<!ENTITY year "2003">
<!ENTITY WSi18nUS "http://www.w3.org/TR/2003/WD-ws-i18n-scenarios-20030516">
<!ENTITY LatestWSi18nUS "http://www.w3.org/TR/ws-i18n-scenarios">
<!ENTITY PreviousWSi18nUS "http://www.w3.org/TR/2002/WD-ws-i18n-scenarios-20021220">
<!ENTITY status "W3C Working Draft">
<!-- <!ENTITY status "Editors' copy $Date: 2003/05/14 15:36:50 $"> -->
]>

<spec w3c-doctype="wd">
<header>
  <title>Web Services Internationalization Usage Scenarios</title>

  <w3c-designation>ws-i18n-scenarios-&year;&MM;&DD;</w3c-designation>
  <w3c-doctype>&status;</w3c-doctype>
  <pubdate><day>&DD;</day><month>&month;</month><year>&year;</year></pubdate>


  <publoc>
    <loc href="&WSi18nUS;/">&WSi18nUS;</loc>
  </publoc>

  <altlocs>
    <loc role="available-format" href="Overview.xml">XML</loc>
<!--    
    <loc role="available-format" href="Overview.html">XHTML</loc>
 -->
  </altlocs>
  <prevlocs>
     <loc href="&PreviousWSi18nUS;/">&PreviousWSi18nUS;</loc>
  </prevlocs>
  <latestloc>
    <loc href="&LatestWSi18nUS;/">&LatestWSi18nUS;</loc>
  </latestloc>

  <authlist>
  <author>
    <name>Kentaroh Noji</name>
    <affiliation>IBM</affiliation>
  </author>
  <author>
    <name>Martin J. Dürst</name>
    <affiliation>W3C</affiliation>
    <email href="mailto:duerst@w3.org">duerst@w3.org</email>	 
  </author>
  <author>
    <name>Addison Phillips</name>
    <affiliation>webMethods</affiliation>
    <email href="mailto:aphillips@webmethods.com">aphillips@webmethods.com</email>	 
  </author>
  <author>
    <name>Takao Suzuki</name>
    <affiliation>Microsoft</affiliation>
  </author>
  <author>
    <name>Tex Texin</name>
    <affiliation>XenCraft</affiliation>
  </author>
  </authlist>

  <status>
  <p><emph>
     This section describes the status of this document at the time of its publication. 
     Other documents may supersede this document. The latest status of this series of 
     documents is maintained at the W3C.</emph></p>

  <p>This is an updated working draft describing Web Services 
     internationalization usage scenarios for review by W3C members and other
     interested parties. It has been produced by the 
     <loc xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="http://www.w3.org/International/ws/" xlink:show="replace" xlink:actuate="onRequest">Web Services Internationalization
     Task Force</loc> of the
     <loc xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="http://www.w3.org/International/" xlink:show="replace" xlink:actuate="onRequest">W3C Internationalization Working Group</loc>, as part of the
     <loc href="http://www.w3.org/International/Activity">W3C Internationalization Activity</loc>.</p>
	  
   <p>Discussion of this document takes place on the public mailing list 
     <loc href="mailto:public-i18n-ws@w3.org">public-i18n-ws@w3.org</loc>.
     To contribute, please subscribe by sending mail to 
     <loc href="mailto:public-i18n-ws-request@w3.org">public-i18n-ws-request@w3.org</loc>
     with <code>subscribe</code> as the subject. The 
     <loc xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="http://lists.w3.org/Archives/Public/public-i18n-ws/" xlink:show="replace" xlink:actuate="onRequest">archive</loc> of this list can be read 
     by the general public.</p> 

  <p>We invite contributions of additional Usage Scenarios and Use Cases to document
     aspects of Web Services internationalization that are not covered yet in this document.
	  For contributions, please use a format similar to the one used in this document.
     Please send your contribution or comment to the
	  <loc href="mailto:www-i18n-comments@w3.org">www-i18n-comments@w3.org</loc> mailing list
	  (<loc href="http://lists.w3.org/">public archive</loc>). Please use [Web Services]
	  or [WSUS] in the subject.</p>
 

  <!--<p>Comments on this document should be sent to the public mailing list  
     <loc href="mailto:public-i18n-ws@w3.org">public-i18n-ws@w3.org</loc>.</p>-->
 <p>At the time of publication, the Working Group believed there were no
    patent disclosures relevant to this specification. A current list of
    patent disclosures relevant to this specification may be found on the
    <loc href="http://www.w3.org/International/2002/Disclosures">Working Group's patent disclosure page</loc>.</p>

 <p>This document is work in progress and does not imply endorsement by, or the consensus of, 
     either W3C, or members of the Web Services Task Force of the W3C Internationalization 
     Working Group. This document still contains incomplete descriptions in various places. </p>
 

  <p>This document is a draft version, and may be updated, replaced or obsoleted by
     other documents at any time. It is inappropriate to use W3C Working Drafts as 
     reference material or to cite them as other than "work in progress". A list of 
     all technical reports can be found at <loc xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="http://www.w3.org/TR/" xlink:show="replace" xlink:actuate="onRequest">http://www.w3.org/TR/</loc>.</p>

  </status>

  <abstract>
     <p>This document describes internationalization usage patterns and scenarios 
	  for Web services and is intended for review by W3C members and other 
	  interested parties. This version provides additional guidance for 
	  implementers of Web service technologies, suggesting methods for 
	  dealing with general international interoperability issues in 
	  services and service descriptions. One goal of this document 
	  is to provide a template for Web service designers to implement 
	  international capabilities in their services.</p>
  </abstract>

  <langusage>
    <language id="EN">English</language>
  </langusage>
  <revisiondesc>
     <p>Last Modified: $Date: 2003/05/14 15:36:50 $</p>
  </revisiondesc>
</header>

<body>

<div1>
 <head>Introduction</head>

<p>This document describes a variety of Web Services internationalization
usage scenarios and use cases.</p>

<p>The goal of the <loc xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="http://www.w3.org/International/ws/" xlink:show="replace" xlink:actuate="onRequest">Web Services Internationalization Task Force</loc> is to ensure
that Web Services have robust support for global use, including all of the
world's languages and cultures.</p> 

<p>The goal of this document is to examine the different ways that language,
culture, and related issues interact with Web Services architecture and
technology. Ultimately this will allow us to develop standards and best
practices for those interested in implementing internationalized Web Services.
We may also discover latent international considerations in the various Web
Services standards and propose solutions to the responsible groups working
in these areas.</p>

<p>Web Services provide a world-wide distributed environment that uses XML based
messaging for access to distributed objects, application integration,
data/information exchange, presentation aggregation, and other rich machine-to-machine
interaction. The global reach of the Internet requires support for the international
creation, publication and discovery of Web Services. Although the technologies
and protocols used in Web Services (such as HTTP <bibref ref="RFC2616"/>,
XML <bibref ref="XML"/>, XML Schema, and so forth)
are generally quite mature as "international-ready" technologies, Web Services
may require additional perspective in order to provide the best internationalized
performance, because they represent a way of accessing distributed logic via a URI.</p>

<p>As a result, this document attempts to describe the different scenarios in
which international use of Web Services may require care on the part of the
implementer or user or to demonstrate potential issues with Web Services
technology.</p>

<p>This document describes the followings scenarios:</p>
<olist>
  <item><p>Locale neutral vs. locale-sensitive XML messages and data exchange</p></item>
  <item><p>Interaction between Web services and the underlying software
           system's international functionality</p></item>
  <item><p>Message processing in Web Services, e.g. SOAP Fault messages etc.</p></item>
</olist>

<p>The scope of this document is described in Section 1.1 below.</p>

<div2>
<head>Scope</head>

<p>This document follows the definition of Web Services specified in
Chapter 2 of the Web Services Architecture document <bibref ref="WSA"/>.</p>

<p>Definition: A Web service is a software system identified by a URI,
whose public interfaces and bindings are defined and described using XML.
Its definition can be discovered by other software systems. These systems
may then interact with the Web service in a manner prescribed by its
definition, using XML based messages conveyed by Internet protocols.</p>

<p>In order to narrow down the scope, the usage scenarios in this document
are limited to the following W3C technologies and deliverables:</p>

<ulist>

  <item><p>Web Services Architecture Documents <bibref ref="WSA"/> <bibref ref="WSAUS"/> <bibref ref="WSAR"/> <bibref ref="WSAG"/></p></item>
  <item><p>SOAP V1.2 Documents <bibref ref="SOAP-0"/> <bibref ref="SOAP-1"/> <bibref ref="SOAP-2"/> <bibref ref="SOAP-AF"/> <bibref ref="SOAP-EB"/> </p></item>
  <item><p>WSDL V1.2 Documents  <bibref ref="WSDL-V12"/> <bibref ref="WSDL-B"/></p></item>

</ulist>
 
<p>Internationalized Web Services need to be easy to create, publish and
discover for a wide range of audiences.</p>

<p>The scope of Web Services internationalization is W3C
internationalization working group deliverables, including:</p>

 <ulist>
  <item><p>Web services requirements</p></item>
  <item><p>Unicode technologies and deliverables</p></item>
  <item><p>Concepts and application of distributed locales and locale-affected preferences</p></item>
  <item><p>Web services internationalization best practices</p></item>
 </ulist>
</div2>
</div1>

<div1><head>Framework</head>
<div2><head>Overview</head>
<p>This section contains a "framework" or outline for understanding
international issues in Web services.</p>

<p>The framework is based on the Web Services Architecture document <bibref ref="WSA"/>,
which defines a service as follows:
<quote>A service is a set of actions that form a coherent whole from the point of view
of service providers and service requesters. A requester entity is a legal entity
that wishes to make use of a provider entity's Web service. It will use a requester
agent to exchange messages with the provider entity's provider agent. The provider
agent has one ore more services available to it, that it can invoke in behalf of
the requester agent.</quote></p>
<!-- This is from an old version, we have to look at it for the next version -->

<p></p>

<p>The mechanics of the message exchange are (partially) documented
in a Web service description (WSD).</p>
<graphic source="uswd1.jpg" alt="illustration of the sequence of events in the framework"/>
<p>The sequence of events in this framework are as follows:</p>

<olist>
  <item><p>The requester agent locates a suitable provider agent. This can be accomplished
	   through UDDI, but also can be accomplished through other means. For example, the
		URL of the provider agent may simply have been found in an advertisement somewhere.</p></item>
  <item><p>The provider agent makes available a Web Services Description (WSD) document.</p></item>
  <item><p>Using the information in the WSD, the requester agent can formulate a service request.
	   This will be a SOAP message which is then sent to the provider agent to be acted upon.</p></item>
  <item><p>The provider agent after receiving the request will invoke the service and
	   get a response. The response can be the results of the service or an indication
		that a fault occurred. Note that the interaction between the provider agent
		and the service are independent of the Web Services framework and the design
		is left completely to the implementors. The primary requirement is that the
		provider agent in turn be able to formulate a response to return to the
		requester agent. This response must satisfy both the requirements and
		specifications of the Web Services Architecture and the description of the WSD.</p></item>
  <item><p>If the service request was successfully executed, the provider agent will
	   formulate a response message and send it to the requester agent.</p></item>
  <item><p>If the service request was erroneous, or the service could not be
	   completed for some reason, a fault message will be sent to the requester agent.</p></item>
</olist>


<p>The internationalization issues in Web services and as illustrated in the
framework fall into several categories which are common to all Web Services,
regardless of the message exchange pattern used for a specific service.
In the section that follows it is assumed that the service, provider and
requester agents, and data structures (semantics) follow best practices in
internationalization and data structuring. Implicit in these descriptions is
the expectation that data structures use XML Schema types to create locale-neutral
data structures.</p>

<p>Some services may be implemented that do not follow these strictures for reasons
having to do with legacy system implementation or other restriction. These cases
are dealt with in usage scenarios later in this document.</p>
</div2>
<div2><head>Natural Language and International Preferences</head>

<p>"Natural Language" refers to human use of language. Generally systems that are
internationalized can produce messages in a variety of different natural languages.
These systems are referred to as "localized", because their messages (and frequently
behavior) are tailored to the individual cultural expectations for a specific target
market or group of individuals.</p>

<p>International preferences are similar to "Natural Language" identification.
Some of the other preferences that a service might be interested in include:</p>

<ulist>
    <item><p>Collation (sorting), often specified with xml:sort</p></item>
    <item><p>Alternate Calendar</p></item>
    <item><p>Time Zone or offset</p></item>
    <item><p>Tax Regime</p></item>
    <item><p>Default Currency</p></item>
    <item><p>...and many more</p></item>
</ulist>
<p>Some of these preferences may be inferred from the natural language by converting
the natural language preference to the service host's "locale" (Note that the provider
agent and service host are not always the same physical host). Other items (such as
timezone) are orthogonal or (like collation) imperfectly or incompletely described
by a natural language identifier. Separating these values requires forethought in
the design of the service and the setting of reasonable default values.</p>

<p>In the sections that follow, you will see the word "locale" used as an adjunct to
natural language. A locale is not a language and the language tags discussed in the
succeeding sections should not be confused with actually being locale tags or
identifiers. However, there is commonly a close relationship between the language
identified by such a tag and the corresponding locale in the underlying platform
and a software process may choose to use language tags to select many of these
additional operational settings or international preferences.</p>

<p>Distributed processing, as with Web services, must allow for several patterns of
behavior in the back end implementation represented by the service.</p>

<p>There are three patterns that such a service may follow. These are:</p>

<ulist>
    <item><p>Language/Locale Neutral</p></item>
    <item><p>Service Determined</p></item>
    <item><p>Client Influenced</p></item>
</ulist>
<p>In each of these patterns, the Web service description (commonly WSDL) and actual
protocol or invocation (SOAP is used in our examples) should reflect the requirements
of the service's own pattern of behavior.</p>


<div3><head>WSDL</head>
<p>Web service descriptions should consider how to communicate language or
locale-of-operation choices in a consistent manner. In the sections that
follow, specific patterns are recommended as good canonical references.
However experience shows that a specific implementation may require additional
contextual information not conveyed with a simple language tag. Generally
this type of additional information should be encoded into the data structure
defined for actual interchange in the message body (such as a soap:body block),
rather than as additional header information as shown in some of the examples below.
This is because specific implementation decisions should be expressed as part of
the service's signature: you may require additional or different data in future versions.</p>

<p>In the examples below, adoption of a generic method for exchanging
"international contextual information" will allow implementations to
better model the natural language and locale processing choices offered
by the services.</p>

<p>In all cases, the implementer should consider adding a language tag to any
operation fault elements to show what language to expect fault messages
to be generated in.</p>

<p>In all cases, descriptive text should be tagged with its actual content language
using the xml:lang attribute (where permitted). Consideration should be given to
providing documentation within services in alternate languages when the service
is expected to be utilized by users such as those in other countries or who speak
other languages.</p>
</div3>

<div3><head>SOAP</head>
<p>In general, SOAP documents should structure data elements in ways that make the
most sense for the specific underlying implementation. In the examples given,
the user's natural language is passed in an optional header element separate
from the specific data structures required to operate the underlying service logic.</p>

<p>This is by design.</p>

<p>Software developers generally get their language resources (translated messages
and other locale-specific data) from their programming environment. This functionality
is implemented in many ways, but the pattern for writing the logic is always similar:
the language and locale preferences are not included in the parameter list of the
service itself because the processing environment (JVM, OS, .NET framework, etc.)
maintains this information. SOAP Processor implementations should be designed to
recognize natural language information passed in the transport (such as HTTP
Accept-Language) or in SOAP headers as defined in this document or in the
specific implementation-dependent extension of this model and populate or set
the appropriate values in the service's environment.</p>

<p>For example, a .NET SOAP Processor might set the service's thread default
CultureInfo using the language tag. A J2EE implementation might populate
the ServletRequest Locale property with a java.util.Locale constructed from
the ISO639 and ISO3166 fields embedded in a language tag. And so forth.</p>
</div3>
<div3><head>Faults and Errors</head>

<p>Fault message "text" elements must be labelled with an appropriate language
identifier, as defined in XML 1.0. That is, an xml:lang tag containing an RFC3066
(or its successor) language identifier. If the transport provides the user's
language preference (such as HTTP Accept-Language), then that language or set
of languages should be preferred, followed by the SOAP Processor machine's
local language preference.</p>

<p>Ideally there should always be a "message of last resort" included in the fault.
In many cases this message may be in English, but consideration should be given
to the likely users of the system, including the administrators trying to puzzle
out the error. Numeric (or ASCII-only alpha-numeric) error codes should be
considered for inclusion in all fault messages. This may provide valuable
reference when the text of the message itself is in a language not understood
by the recipient.</p>

<p>When designing specifications intended for interoperability between vendors
or implementations, consideration should be given to enumerating the possible
faults in advance so that reference numbers can be universally and consistently
referenced by disparate implementations.</p>
</div3>
</div2>
<div2><head>Language and Context Negotiation Patterns</head>

<p>As noted above, there are three general patterns or policies that may
be applied to any specific Web service. These three are:
</p>
<ulist>
    <item><p>Language Neutral</p></item>
    <item><p>Service Determined</p></item>
    <item><p>Client Influenced</p></item>
</ulist>
<div3><head>Language Neutral</head>

<p>A language neutral service generally is one that executes in the same
way regardless of the current runtime locale or user preferences regarding
language. This implies that all or most strings embedded in the service
are not human readable. This is, by far, the most common pattern. In a
language or locale neutral service, external factors do not alter the
way the service performs. An example of this would be a service that
adds two integers together: 2+2 = 4 in most every locale.</p>

<div4><head>Example: GetTimeService returns the current time</head>

<p>GetTimeService can be written as a locale-neutral service. Time of day, although
it is presented with different formats around the world, is measured the
same way everywhere and a standardized single frame of reference is available
to be used. So a service request could return with a response that included
the current UTC (Coordinated Universal Time) time in ISO 8601 format: hh:mm:ss.sss,
i.e. as an XML Schema Part 2: Datatypes <bibref ref="XMLS-2"/>
<xspecref href="http://www.w3.org/TR/xmlschema-2/#time">time</xspecref> type.</p>

<p>Any application (i.e. a consumer) that triggers an event causing the GetTimeService
request to be sent to a Service Provider, can transform the result into a local or
other time format, including perhaps shifting the time into the local time zone.
With this proposed implementation, from the requester agent to the service provider,
the service and back to the requester agent, the request document and its service
implementation are entirely independent of the locale of the client, the host,
and the implementer. Hence the name locale-neutral.</p>

<p>Of course, the request could also be implemented with dependencies on locale of
the client or the host and this would complicate implementation and increase the
probability of errors in making requests, deploying the service, or implementing
the service.</p>
</div4>

<div4><head>Usage Pattern</head>
<p>Language neutral services, being the default, do not generally announce
themselves in their service contracts, although (other scenarios apply here).</p></div4>

<div4><head>WSDL</head>
<p>The Web services description does not require any extra information in order
to perform its operations or communicate its capabilities. Therefore no
additional fields beyond those required by the actual service implementation
should be defined in any of the bindings or operations.</p>

<p>The implementer should consider adding a language tag to any operation
fault elements to show what language to expect fault messages to be generated in.</p></div4>

<div4><head>SOAP</head>
<p>No additional attributes or information is required for this pattern.</p></div4>

<div4><head>Faults</head>
<p>Fault messages may be generated in a variety of languages simultaneously.
If the transport provides a way of determining the requester agent's preferred
language (such as the Accept-Language header in HTTP), then these preferences
should be used first. In all cases, a "message of last resort" should be generated,
which generally should be in the language and locale of the provider agent or the
language most preferred by the administrator of that system (since that is who will
have to debug any service requests against the system). Many systems are run in
default locales, which often default to the English language. This should be a
consideration in configuring the system.</p></div4>
</div3>
<div3><head>Service Determined</head>

<p>In the Service Determined pattern, the implementation or configuration
of the service itself or the provider agent determine some aspects of
the processing performed by the service. Generally this can be thought
of as a design-time or deployment-time decision, rather than a runtime
aspect of the service. That is, the service can be relied on to perform
its work in a consistent manner using a predetermined language or locale setting.</p>

<div4><head>Example</head>
<p>A service provider is in 3 country markets: U.S., Japan, and Germany.
Each market is supported by a local warehouse. 
One of the services that is provided indicates availability of parts.
For a given part number, the following information is returned:
part number, quantity, language, description, size, list price.</p>

<p>If all of the information was maintained in a single database one might see entries like:</p>
<table><thead><tr><th>location</th><th>part number</th><th>quantity</th>
<th>language</th><th>description</th><th>size</th><th>currency</th><th>value</th></tr></thead>
<tbody>
<tr><td>U.S.</td><td>123</td><td>51</td><td>en-US</td>
<td>6 pack budweiser</td><td>12oz.</td><td>USD</td><td>5.99</td></tr>

<tr><td>Japan</td><td>888</td><td>10</td><td>en-US</td>
<td>6 pack kirin</td><td>591ml</td><td>JPY</td><td>999</td></tr>

<tr><td>Germany</td><td>500</td><td>20</td><td>en-US</td>
<td>6 pack Beck's</td><td>300ml</td><td>EUR</td><td>8.00</td></tr>
</tbody></table>

<p>@@@@add some native Japanese and german language entries.</p>

<p>However, this company has not yet implemented a worldwide
inventory application and instead each warehouse maintains its
inventory in a separate and independent database and uses
different applications to manage inventory. In fact, the Japanese
warehouse is the only one that uses a system that supports the
Japanese language. Because of its support for Japanese and its
use of legacy encodings instead of Unicode, the Japanese system
cannot properly support German text.</p>

<p>The service provider has implemented a service, GetProductInventory.</p>

<p>The input (inbound message) takes a part number
or part ID. The output (outbound message) returns the following
information: part no., quantity, language, description, size,
list price.</p>

<p>An implementation decision might be taken to provide separate Web services for each warehouse.
Customers on each continent will be directed to a
particular web service that returns the information from the
appropriate warehouse. This pattern is service-determined as it reflects the
inherent nature of the service in each part of the world. (That
is the German warehouse supports clients in Germany.)</p>

<p>This example also demonstrates the "service determined" type of limitation:
it's capabilities are limited by its use of legacy
applications. If the databases were consolidated and suitable
shipping facilities were made available, the service could still
not offer product from any warehouse to any client. The Japanese
clients using the Japanese service provider would not be able to
see all of the potential German beer names. (They could only see them if the names
were transliterated to Japanese or a subset of the Japanese legacy encoding, such as 7-bit ASCII.)</p>

<p>There are several sub-patterns for this.</p>
</div4>

<div4><head>Implementation or Deployment Decision</head>
<p>The service may be written to assume a specific locale or language setting
or the server which hosts the service or provider agent may be statically
configured to use a specific locale. This is generally a poor choice, since
it implies a non-internationalized implementation to start with. However,
legacy code or other choices may require this pattern and not be in the
control of the Web service.</p></div4>

<div4><head>Enumerated Set</head>
<p>The service may be enabled for or capable of internationalized operation,
but it may be configured to process all requests in just a few (or, more 
likely, just one) language or locale. This allows the service to be deployed
to many locales or for it to serve several markets simultaneously, depending
on how the service and/or its provider agent is configured.</p></div4>

<div4><head>Service Determined</head>
<p>Service determined language or locale matching is a pattern that is useful
when the service's performance is explicitly linked to what it does.
For example, a service that returns whether the New York Stock Exchange
will be open or closed on a particular day is strongly linked to the
holiday schedule in the USA. The service may be written in such a way
that it can also be used by other exchanges in other countries, but
the specific service might be written simply to support the needs of this one use.</p></div4>

<div4><head>Usage Pattern</head>
<p>Similar to that of Language Neutral, except that the server's local
language preference is expected to affect processing. In most cases the
difference between Language Neutral and Service Defined is that the latter
returns values that have elements consisting of natural language text or are
otherwise locale affected, whereas a Language Neutral service returns values
that can be formatted entirely by the requester agent or requester.</p></div4>

<div4><head>WSDL</head>
<p>The Web services description may provide an optional header field in the
operation output element defining the natural language used by the service
at execution time. Since this value is at least partially machine dependent,
the value probably should not be set in the actual service description.
Instead the soap:header or equivalent field should merely be defined as
being available. If the service uses an enumerated set of languages,
it might be wise to ensure that the actual language used is always
passed back in any output.</p></div4>

<div4><head>SOAP</head>
<p>This Web service pattern is generally similar to that of Language Neutral.
Processes that are language or locale affected may retrieve their settings
from the default machine settings and the SOAP Processor generally need not
provide any special functionality to activate or achieve this.</p></div4>

<div4><head>Faults</head>
<p>Faults are generated as with Language Neutral, except that the service
specific language should also be generated after any user specified value,
but before that of the SOAP Processor, assuming that these three are all
different values and that all are available.</p></div4>

<div4 id="S-013"><head>S-013: Service Determined Language Preference Leads to Fault</head>

<div5><head>Scenario Definition</head>
<p>Locale affected fault evaluation.</p>
</div5>

<div5><head>Description</head>
<olist>
  <item><p>Service "A" is defined on Provider "A", running in an English locale.
    The service requires that the value of string variable "foo" be less than
    "zzz".</p></item>
  <item><p>Requester "A" is running in a French locale and sends a SOAP request
    with foo="écrit". </p></item>
  <item><p>Provider "A" returns a fault, even though in French the string is "less
    than" the evaluated value.</p></item>
</olist>

</div5>
</div4>

</div3>

<div3><head>Client Influenced</head>
<p>In this pattern, the service will attempt to match its processing to the
language specified by the user. The service should therefore provide a way
for the user's preference to be communicated, regardless of transport, and
the actual value used to perform the processing should be returned in any 
response that may be generated.</p>

<div4><head>Example</head>
<p>If the service determined example (GetProductInventory) were upgraded
so that data was globally accessible,
then the pattern could be changed to the client-influenced pattern. In this case, the Web service
GetProductInventory, could return information about inventory
from all warehouses or any specific warehouse, but would take advantage of the user's
language and locale preferences to influence how choices are
returned, the ordering of the choices, and even which choices are displayed.</p>

<p>For example, a user that has a Japanese language preference might
see only the inventory counts for the products available in the
Japanese warehouse, with Japanese language description. Although
the locale-influenced web service may return the "best" responses
for a majority of users, it may be wrong for some percentage,
which on the web may be a large number of users. For example,
Japanese-speaking clients in U.S. would be better served
(perhaps) by inventory from the U.S. warehouse.</p>

<p>A more precise web service design would make the selections of
warehouse and description language, currency, etc. explicit.
However, it is not always possible to present the client all of
the information up front for them to make good choices on a form
with many explicit options. So client-influenced patterns are
often used for this purpose.</p>
</div4>
<div4><head>Usage Pattern</head>
<p>In this usage pattern, the service description and actual execution should be
designed to allow the requester agent to pass the most appropriate value for
the specific invocation of the service.</p></div4>

<div4><head>WSDL</head>
<p>Both inbound and outbound headers define a attribute bound to type xsd:language and
labelled with an xml:lang element. The inbound header should allow multiple values
to be passed, in case the first preference is not available. The outbound value
should be a single discrete value: that actually used by the service at execution time.</p></div4>

<div4><head>SOAP</head>
<p>Inbound and outbound headers optionally take the element defined in the WSDL.
If not present, the SOAP Processor's local language preference is used. Outbound
headers should reflect as accurately as possible the actual value used in performing
the processing. This may vary from that specified by the user according to the rules
in RFC3066 (or its successor). If no match may be obtained, the results will be
implementation defined--the service may generate a fault if processing can go no
further, but most implementations will probably use the current provider agent's default
locale for the value.</p></div4>

<div4><head>Faults</head>

<p>Fault messages should be generated with the requester's preferred language(s),
in order by preference, followed by the provider agent's default language.</p></div4>
</div3>
</div2>
<div2>
<head>Passing or Matching International Preferences</head>

<p>Implementers may also have to define more complex international behavior, beyond that
described by a mere language choice. It is common for these design decisions to be 
specific to the particular application or particular market being serviced. 
The use of a "locale" or language preference as a short hand for these more complex 
requirements should be carefully considered, and possibly discouraged, in favor of 
making the specific information required for proper operation explicit in the service contract.</p>

<p>Nonetheless, in some cases the service implementer may wish to use the language or 
locale preference of the end user to determine how the service's processing should proceed.</p>

   <p> * various examples
    * ... etc. @@@needs more work here</p>
</div2>
<div2><head>Natural Language Handling in Faults</head>

<p>SOAP Version 1.2 allows to send fault messages with reason texts in
     multiple languages. SOAP Version 1.2 Part 0: Primer <bibref ref="SOAP-0"/>
	  explains the &lt;Reason&gt; element as follows:
	  "It must have one or more env:Text sub-elements, each with a unique xml:lang attribute,
      which allows applications to make the fault reason available in multiple languages.
      (Applications could negotiate the language of the fault text using a mechanism built
      using SOAP headers; however this is outside the scope of the SOAP specifications.)"</p>


<p>This mechanism is suitable
 for returning faults in an environment in which the number of languages is relatively small 
 and the range of languages to be returned is known in advance.</p>

<p>Many actual SOAP implementations are localized into many languages simultaneously.
To prevent faults from becoming overly large and difficult to manage, implementations 
should really include some strategy that reduces the set of languages to a minimum and 
attempts to match the language of the fault as closely as possible to the client that
ends up viewing the message.</p>

<p>Ideal implementations will include mechanisms for "late localization" of the values.</p>

<p>Future versions of SOAP should probably consider allowing additional structured information 
in a Fault so that suitably internationalized clients can perform the localization and 
formatting themselves.</p>

<div3 id="S-005"><head>S-005: Language Matching for Fault Reason Messages</head>
 <div4>
   <head>Scenario Definition</head>
   <p>The service requester needs to select a matching language from the list of
   fault reasons returned by the service provider. This scenario illustrates an
	issue that implementations have to take into account.</p>
</div4>

<div4><head>Description</head>

<p>The requester may be unable to (validly) match the returned text values to
its current (end user) language.</p>

<example>
<head>SOAP fault reason messages in multiple languages</head>
<eg>&lt;env:faultReason&gt;
 &lt;env:Text xml:lang="en-US"&gt;Processing error&lt;/env:Text&gt;
 &lt;env:text xml:lang="cs"&gt;Chyba zpracování&lt;/env:Text&gt;
&lt;/env:faultReason&gt;
</eg>
</example>

<p>If the requester prefers "en-GB", then neither string will match
directly for the current requester language preference. Although it
is apparent to a human that en-US is a reasonable match for en-GB, automated
processes are not permitted to make the assumption that languages
with common prefixes are mutually understandable. If the requester prefers
"ja", then selecting the best fallback is even more difficult.</p>

<p>Applies to: SOAP, or an extension of SOAP</p>

</div4>
</div3>

<div3 id="S-009"><head>S-009: Language Preference for One Way Messages</head>
  <div4><head>Scenario Definition</head>
   <p>Service Oriented Architecture Derivative Patterns One Way Message</p>
  </div4>
<div4><head>Description</head>
<olist>
  <item><p>Service "A" is defined to receive a message from Requester "A" and
    deliver to Requester "B" via Service "B". An example of this would be
    similar to a mail server triggered by a Web service.</p></item>
  <item><p>Requester "A" calls Service "A".</p></item>
  <item><p>Service "B" is unable to complete its message transaction and generates
    a fault.</p></item>
</olist>
<p>Service "B" should return a message in a language that matches Requester "B"'s
language preference (so that the administrator of that system can use it).
In addition, if Requester "A"'s preferences are available to Requester "B"
(that is, Service "A" got the preferences as part of its input or via an
external mechanism such as the transport), then Requester "A"'s language
preference should be included in the SOAP fault reason text.</p>

<p>For example:</p> 
<ulist>
<item><p>Requester "A" has a language preference of "fr-FR"</p></item>
<item><p>Requester "B" is running in an environment with a language preference of "de-DE"</p></item>
<item><p>Service "B" is running in an environment with a language preference of "en-US"</p></item>
</ulist>

<example><head>The result may look like this:</head>
<eg>
  &lt;env:Reason&gt;
      &lt;env:Text xml:lang="fr-FR"&gt;French error&lt;/env:Text&gt;
      &lt;env:Text xml:lang="de-DE"&gt;Verarbeitungsfehler&lt;/env:Text&gt;
      &lt;env:Text xml:lang="en-US"&gt;Processing error&lt;/env:Text&gt;
  &lt;/env:Reason&gt;&gt;
</eg>
</example>
</div4>
</div3>

</div2>
<div2><head>Ordering, Grouping, and Collation in Services</head>

<p>Some types of internationally sensitive processing cannot be inferred solely from a 
language identifier. Collation (sorting) is such a process. The collation may even 
affect the results that one gets from a Web service. For example, if the service 
selects "all offers &gt; c", in certain locales you might receive back entries starting 
with "ch" (which is treated as a separate letter). Or if the service returns "all items &lt; z", 
in certain locales this may not include accented letters such as Å (A-RING).</p>

<p>See <xspecref href="#S-009">S-009</xspecref> above for a similar example.</p>
</div2>
<div2><head>Descriptive Text in Service Descriptions</head>

<p>Service descriptions are human-readable text intended to describe what the service
does and how it should be used. To be useful, the description needs to be a natural
language sentence or even a set of keywords in the language that the likely user audience 
will understand. The should be a way to tag the content with the specific language that 
it is in and to allow multiple languages. Otherwise false positives or negatives will result.</p>
</div2>
</div1>

<div1><head>Usage Scenarios</head>

<div2><head>Data Integrity and Interoperability</head>

 <div3 id="S-001"><head>S-001: Data Integrity using an Unicode-based Encoding</head>
  <div4><head>Scenario Definition</head>
   <p>A sender and a receiver wish to use an Unicode-based encoding to transmit
	data between each other. This scenario provides an example of best practice.
   </p>
  </div4>
  <div4><head>Description</head>
   <p>SOAP is used for XML messages exchanging data among
   nodes. Because all XML <bibref ref="XML"/> processors must be able 
   to read entities in
   both the UTF-8 <bibref ref="RFC2279"/> and UTF-16 <bibref ref="RFC2781"/> encodings, 
   using UTF-8 or UTF-16 guarantees character encoding interoperability on the SOAP layer. 
   The Character Model for the World Wide Web <bibref ref="CHARMOD"/> document 
	describes these considerations and guidelines.
   </p>

   <p>Applies to: SOAP, SOAP interface of software systems</p>
  </div4>
 </div3>

 <div3 id="S-002"><head>S-002: Data Integrity using a Legacy Encoding</head>
  <div4>
   <head>Scenario Definition</head>
   <p>A sender and a receiver wish to use a legacy (i.e. not Unicode-based) encoding.
	This scenario provides an example of good practice, but using an Unicode-based encoding
   (see <xspecref href="#S-001"></xspecref>)	
	is preferable and Web service implementers should avoid legacy encodings wherever
	possible to ensure interoperability.</p>
  </div4>

  <div4><head>Description</head>

   <p>This scenario is divided into three aspects.</p>
   <olist> 
    <item><p>A sender sends a SOAP message using a legacy encoding.</p></item> 
    <item><p>A receiver receives a SOAP message using a legacy encoding.</p></item> 
    <item><p>Interaction between SOAP layer and SOAP interface such as programming
             language, middleware, operating systems etc.</p></item>
   </olist>
  
   <p>
   When a sender sends a SOAP message in a legacy encoding to a receiver,
	the receiver may not be able to accept the legacy encoding.
	In order to use a legacy encoding in a SOAP message, the sender needs to
	know beforehand whether the receiver is able to accept the
	legacy encoding in question.</p>
   <p>
   Receiver passed SOAP messages to programming languages, middleware, or
   operating systems via SOAP interface. Through the interaction of SOAP
   interface, code conversion from non-Unicode encoding to Unicode may happen.</p>
   <p>
	The XML Japanese Profile <bibref ref="XML-JP"/> describes that using
	legacy encodings such as Shift_JIS cannot provide complete interoperability
	in	information interchange; there are slight differences among platforms
	in the mapping tables they use for this and similar encodings.</p>

   <p>Applies to: SOAP, SOAP interface of software systems</p>
  </div4>
 </div3>
 </div2>

 <div2>
  <head>Language (Locale) Negotiation for SOAP Fault Messages</head>

<!--
 <div3 id="S-003"><head>S-003: Natural Languages for SOAP Fault Messages</head>
  <div4><head>Scenario Definition</head>

   <p>A requester wishes to tell the requester's language
   preference to the provider in order to receive SOAP fault messages in the
   requester's preferred language.</p>
  </div4>

  <div4><head>Description</head>
   
   <p>When a SOAP fault occurs, SOAP fault messages containing natural language
   descriptions of the error(s) are sent back to the requester. The requester
   usually wants to see error messages in the requester's preferred language(s)
   and data format. Currently the following mechanism is available with the HTTP
   binding.</p>

   <p><code>Accept-language:</code> The Accept-Language request-header field
	restricts the set of natural languages that are preferred as a
   response to the request. <bibref ref="RFC2616"/></p>

   <p>Using Accept-language, a requester can notify a provider of the requester's
	language preference. A provider can then send SOAP-Fault messages in the requester's
   preferred language(s). If a SOAP message does not use the HTTP binding, 
   how can a SOAP-Fault message detect the requester's language preference.</p>   

   <p>Applies to: SOAP, or an extension of SOAP</p>
  </div4>
 </div3>
-->

<!--
<div3 id="S-004"><head>S-004: Producing Fault Reasons in All Available Languages</head>

<div4><head>Scenario Definition</head>
 <p>In the absence of language negotiation, the service provider needs to produce
    fault messages in all available languages. This scenario documents a potentially
	 significant processing overhead.</p>
</div4> 

<div4><head>Description</head>

<p>The Service Requester sends a SOAP document containing an error to the
Service Provider. The provider generates a response containing a SOAP fault.
In order to provide for multi-lingual response under the current design, the
provider must return all available languages. The provider cannot know what
languages (resources) are installed. Most programming environments do not
provide functionality that enumerates which languages are actually installed,
so the service provider must request every possible installed locale in turn
in order to poll whether the string is available in that language. Since
resources are often sparsely populated, this suggests significant a processing
overhead to loop over all possible locales, loading resources in turn.</p>

<p>Applies to: SOAP, or an extension of SOAP</p>
</div4>
</div3>

<div3 id="S-006"><head>S-006: Sending Fault Reasons in All Available Languages</head>

<div4><head>Scenario Definition</head>

<p>The service provider must return fault messages in all available languages
when it does not know the language(s) needed by the requester (and by other
people who may need to read the message). This scenario documents a
potential scalability problem for the size of fault messages.</p>
</div4>

<div4><head>Description</head>

<p>Many operating environments are localized into a large number of languages
(for example, Microsoft supports 33 languages in 120+ locales or regional variations).
SOAP fault messages may become substantial in size if every 
language is returned because it is not clear what languages are needed.</p>

<p>Applies to: SOAP, or an extension of SOAP</p>

</div4>
</div3>
-->

<div3 id="S-007"><head>S-007: Language Preference for Chained Services</head>

<div4><head>Scenario Definition</head>
<p>A service defines a language preference. The service is then chained.</p> 
</div4>

<div4><head>Description</head>
<p>Service "A" defines an optional header, as in section 2.3.3, containing a
language request field. This service is deployed.</p>

<p>Service "B" defines a service that includes a call to Service "A",
but does not define a natural language header.</p>

<p>A requester calls service "B" with the arguments provided by service "B".
Service "A" therefore receives no language preference or Server "B"s provider's preference.</p>

<p>Applies to: SOAP, or an extension of SOAP</p>

</div4>
</div3>


<div3 id="S-008"><head>S-008: Locale Sensitive Formated Data in SOAP Fault Messages</head>

<div4><head>Scenario Definition</head>
<p>FaultReason must substitute locale-sensitive data into text message.</p>
</div4>

<div4><head>Description</head>
<p>Service "A" is defined on Provider "A". A fault is generated during
    invocation that returns a faultReason that includes values for which
	 the presentation depends on locale.</p>

<ulist>
  <item><p>"The date provided, 12 November 2201, was too late."</p></item>
  <item><p>"The argument 12345.678 was too large."</p></item>
  <item><p>"The argument 12345,678- was too small."</p></item>
</ulist>

<p>The provider should format substitutions in each message according to the language
(and implied locale) of the message, not according to the locale of the provider
or service. In the case of Language Neutral or Service Determined patterns,
it may not be possible to generate a message in the user's preferred language
(or the preference may not be available). In these cases, the message should
follow the language preference of the provider or service host.</p>

<p>Applies to: SOAP, or an extension of SOAP</p>

</div4>
</div3>

<div3 id="S-010"><head>S-010: Language Preference for Multiple SOAP Bindings</head>
 <div4><head>Scenario Definition</head>
  <p>SOAP message variation if http or ftp or SMTP or RMI or IIOP (difficulty
  deploying in a single WSDL)</p>
 </div4>

  <div4><head>Description</head>
   <olist>
   <item><p>Service "A" is defined on Provider "A".</p></item>
   <item><p>The administrator of Provider "A" wishes to deploy the 
            same service on several bindings simultaneously 
            in the same WSDL file.</p></item>
   </olist>
  
  <p>Some protocols, such as HTTP or, to a lesser extent, SMTP, contain headers
  or other information that can be used to communicate the requester's language
  preference. If a service is designed to be wholly or partially sensitive to 
  the requester's language preference, it should include an optional header in 
  the Web service description with the name "lang" which uses the type xsd:language. 
  This value should be used preferentially by the service when deciding on the 
  language preference of the requester. If the value is not supplied or the value 
  is not installed (available) locally, then the provider may also choose to process 
  information provided by the transport protocol. If no values are available or supplied, 
  then the provider may choose some reasonable default to use in the service.</p>
 </div4>
</div3>


<div3 id="S-011"><head>S-011: HeaderFault vs. Fault</head>

<div4><head>Scenario Definition</head>
<p>HeaderFault vs. Fault</p>
</div4>

<div4>
 <head>Description</head>
 <olist>
  <item><p>Service "A" is defined on Provider "A" and invoked by Requester "B".</p></item>
  <item><p>While processing the request, Provider "A" detects a problem with the header.
           Provider "A" returns a SOAP fault with Reason text.</p></item>
  <item><p>Later Requester "B" invokes Service "A" again. This time the actual
           service generates a fault (and presumably supplies the falut reason text).
			  For example a Java-based service might throw an Exception to which it
			  passes a string containing information about the fault.</p></item>
 </olist>

<p>Provider "A" should, if possible, try to resolve any reason Text elements
into the languages requested by Requester "A". In some cases this may not be
possible because the language in question is not available or the design of
the error handling subsystem does not allow multiple language resolution of
the fault. In this case, Provider "A" should return the message provided by
Service "A" and labeled with the local language (or the language of the
actual message, if known).</p>

</div4>
</div3>

<div3 id="S-012"><head>S-012: Interaction of Language Negotiation and Caching</head>

<div4><head>Scenario Definition</head>
<p>Caching may affect the results of language negotiation.
(This usage scenario is still work in progress.)</p>
</div4>

<div4>
 <head>Description</head>
  <olist>
  <item><p>Caching is not (yet) well defined or described in Web Services architecture
    and SOAP 1.2.</p></item>
  <item><p>If caching is permitted and is separate from service execution and
    there is no standardized language negotiation mechanism, it is possible
    that cached responses in the wrong language could be returned.</p></item>
  </olist>
  </div4>
 </div3>

<!--
<div3 id="S-015"><head>S-015: Peer-to-Peer Fault</head>

<div4><head>Scenario Definition</head>
<p>Peer-to-Peer faults.</p>
</div4>

<div4><head>Description</head>
<olist>
  <item><p>Service "A" and Service "B" are defined as "peer-to-peer" services
    (that is, each service may invoke the other service or be invoked by the
    other service).</p></item>
  <item><p>Service "A" invokes Service "B", generating a fault.</p></item>
</olist>

    <ednote>
      <name>KN</name>
      <date>2002-12-15</date>
      <edtext>Needs to describe what internationalization is.</edtext>
   </ednote>
</div4>
</div3>
-->

</div2>

 <div2><head>Locale Neutral vs. Locale Sensitive Data Exchange</head>
 <div3><head>Background</head>
 <p>As noted in the Framework section, data structures should be designed
 wherever possible to be locale neutral. In the case of certain applications
 this is not possible. In general care should be used to avoid locale-sensitive
 data representations.</p>
 <p>For example, for data transmitted in textual form the following cases
  can be distinguished because of the actual formatting:</p>
 
 <ulist>
 <item><p>Data formatted using a (locale-)specific convention. Example: A Japanese
       date such as "平成15年5月16日".</p></item>
 <item><p>Data formatted in a way that is widely understood by different software.
       Example: A date in the format used by XML Schema (Part 2,
       Datatypes)<bibref ref="XMLS-2"/>: 2003-05-16.</p></item>
 </ulist>
 
 <p>A similar distinction can be made with respect to semantics:</p>
 <ulist>
 <item><p>Data that has semantics that depend on culture. For example, the
       XML Schema datatype 'gMonth' is bound to the Gregorian calendar.
		 A value of this datatype such as '5' (referring to May in each year
		 of the Gregorian calendar) cannot be converted to calendars that
		 do not have their months aligned with the months of the Gregorian
		 calendar.</p></item>
 <item><p>Data that has semantics independent of culture.
       Example: the datatype 'integer' from
		 XML Schema (Part 2, Datatypes)<bibref ref="XMLS-2"/>.</p></item>
 </ulist>
 <p>Please note that there are formats that use conventions related to
 some specific culture for the actual representation while their semantics
 are culture-independent. For example, although XML Schema requires the
 use of Western digits, which makes the actual formatting culture-dependent,
 integers can be formatted according to different cultural conventions
 without problems.</p>
 
 </div3>

 <div3 id="S-016"><head>S-016: Locale Neutral Formated Data</head>
  <div4><head>Scenario Definition</head>
   <p>A sender wishes to send data to a receiver. The sender does not know the
   kind of formatting conventions that the receiver is using for various types
   of data. This usage scenario does not raise any requirements. It provides an
   example of best practice.</p>
  </div4>
  
  <div4><head>Description</head>
   <p>If the sender does not know the kind of formatting conventions that the
   receiver is using for a particular type of data, the sender has to use
   well-known, locale-neutral formatting conventions. XML Schema (Part 2,
   Datatypes)<bibref ref="XMLS-2"/> provides such such formatting conventions.
	Although SOAP can
   support various XML encodings, SOAP specifies the common data types such as
   SOAP encoding which is for general cases: e.g. RPC scenario for  basic
   interoperability. SOAP encoding is based on XML Schema.</p>

   <p>The following data types are related to date and time. They are built-in
   primitive types which are specified in XML Schema Part 2.</p>

   
   <example>
   <head>Locale neutral formated data in XML Schema</head>
   <eg>
   TYPE            : EXAMPLE               
   ---------------- ---------------------------
   date            : 2003-05-31
   time            : 13:20:00
   tz              : +09:00
   dateTime        : 2003-05-31T13:20:00+09:00
   <!--  duration        : P1Y2M3D
   gYearMonth      : 2003-05
   gYear           : 2003 
   gMonthDay       : 05-25
   gDay            : 25
   gMonth          : 05  
   -->
   double          : 1267.43233E12
   decimal:integer : 2678967543233</eg>
   </example>

   <p>The above data types keep interoperability from a lexical analysis
   perspective. When a SOAP sender sends e.g. a date to a SOAP receiver using the above
   date type, both sender and receiver can interpret the date lexically.</p>
	
<p>On the other hand, dates and date-time values are affected by the user's
location (timezone). For example, 2003-05-31 in Korea is not exactly the
same period of time as 2002-05-31 in France, but it is the same as 2003-05-31
in Japan. Date varies by time-zone which is related to regional government
and geography etc. In processing SOAP encoding or XML Schema data types,
it is necessary to distinguish locale-neutral data formatting and locale-neutral
data semantics. Using SOAP encoding or XML Schema ensure locale-neutral data format,
but does not always ensure locale-neutral data semantics.</p>

<p>For example, a Web service that returns whether the New York Stock Exchange
is open or closed on a specific day can accept a date like 2002-05-31 as
location independent--the exchange is either open or closed that day.
However, for example, a service that places a "limit order" (that is,
a purchase of stock that has specific limits on it, one of which may be
an expiration date if the other limits are not met) might tie the expiration
date to the specific time the market closes in New York that day rather than
to an arbitrary other timezone.</p>
	

   <p>The following example is a SOAP message in SOAP encoding. Although all of
   the following data are locale-neutral formatting, the context of data differs
   from one location/culture to another.</p>

   <example>
   <head>Locale neutral formated data</head>
   <eg>
   &lt;?xml version='1.0' ?&gt;
   &lt;env:Envelope xmlns:env="http://www.w3.org/2002/06/soap-envelope"&gt;
    &lt;env:Header&gt;
    &lt;/env:Header&gt;
   &lt;env:Body&gt;
    &lt;c:getAvailableFlightResponse xmlns:c="http://trip.example/query"&gt;
     &lt;c:price&gt;123.55&lt;/c:price&gt;
     &lt;c:departuredate&gt;2003-05-31&lt;/c:departuredate&gt;
     &lt;c:departuretime&gt;13:30:00&lt;/c:departuretime&gt;
    &lt;/c:getAvailableFlightResponse&gt;
   &lt;/env:Body&gt;
   &lt;/env:Envelope&gt;</eg>
   </example>

   <p>SOAP transactions can use SOAP encoding/XML Schema to assure that there is
   no ambiguity in transactions between senders and receivers in order to keep
   lexical analysis interoperability. Additional attributes may be needed to assure the
   data semantics. Detailed scenarios are described in the next section.</p>

   <p>Applies to: Web Services in general</p>
  </div4>
 </div3>

 <div3 id="S-017"><head>S-017: Data with Additional 'Attributes'</head>
  <div4><head>Scenario Definition</head>
   <p>A sender wishes to send monetary data to a receiver. Each of the monetary
   amounts has a specific currency. This usage scenario does not raise any
   requirements. It provides an example of best practice.</p>
  </div4>
  <div4><head>Description</head>
   <p>SOAP messages are sent to a receiver using XML schema data types such as
   integer, double, float, date, time etc. However, these data types may have locale
   sensitive semantics such as currency and location. In order to add data
   semantics, adding attributes is frequently used for XML messaging
   scenario.</p>

   <example>
   <head>Locale neutral formated data with additional attributes</head>  
   <eg>
   &lt;?xml version='1.0' ?&gt;
   &lt;env:Envelope xmlns:env="http://www.w3.org/2002/06/soap-envelope"&gt;
    &lt;env:Header&gt;
    &lt;/env:Header&gt;
    &lt;env:Body&gt;
     &lt;c:getAvailableFlightResponse&gt;
      &lt;c:price c:currency="USD"&gt;123.55&lt;/c:price&gt;
      &lt;c:departuredate c:location="JFK"&gt;2003-05-31&lt;/c:departuredate&gt;
      &lt;c:departuretime c:location="JFK"&gt;13:30:00&lt;/c:departuretime&gt;
     &lt;/c:getAvailableFlightResponse&gt;
    &lt;/env:Body&gt;
   &lt;/env:Envelope&gt;</eg>
   </example>

   <p>Another option is to use a structure consisting of two elements for RPC
   scenario using SOAP encoding.</p>

   <example>
   <head>Locale neutral formated data with additional semantic data</head>
   <eg>
   &lt;?xml version='1.0' ?&gt;
   &lt;env:Envelope xmlns:env="http://www.w3.org/2002/06/soap-envelope"&gt;
    &lt;env:Header&gt;
    &lt;/env:Header&gt;
    &lt;env:Body&gt;
     &lt;c:getAvailableFlightResponse&gt;
      &lt;c:price&gt;
       &lt;c:currency&gt;USD&lt;c:currency&gt;
       &lt;c:amount&gt;123.55&lt;/c:amount&gt;
      &lt;/c:price&gt;
      &lt;c:departuredate&gt;
       &lt;c:location&gt;JFK&lt;/c:location&gt;
       &lt;c:date&gt;2003-05-31&lt;/c:date&gt;
      &lt;/departuredate&gt;
      &lt;c:departuretime&gt;
       &lt;c:location&gt;JFK&lt;/c:location&gt;
       &lt;c:date&gt;2003-05-31&lt;/c:date&gt;
      &lt;/departuretime&gt;
     &lt;/c:getAvailableFlightResponse&gt;
    &lt;/env:Body&gt;
   &lt;/env:Envelope&gt;</eg>
   </example>

   <p>Applies to: Web Services in general</p>
  </div4>
 </div3>

 <div3 id="S-018"><head>S-018: Data with Default 'Attribute'</head>
  <div4><head>Scenario Definition</head>
   <p>A service is designed around a single currency and therefore did
	not associate financial data with currency symbol or codes. However, the
	responses from this service may in turn be used by multicurrency services
	or incorporated into other messages. Therefore the response should be modified
	to identify the currency used by the service. There are 3 possible solutions.
	Two involve modifying the message format. The message can be changed so that a
	currency element is added to any node that has financial data elements.
	An alternative is to provide the currency as an attribute for any financial data. 
	However, it may be unacceptable to change the XML message format used by the service. 
	A third alternative is to indicate the currency used throughout the message in the SOAP header.</p>
  </div4>

  <div4><head>Description</head>
   <p>The following example demonstrates multiple currency data transmission in a SOAP message
      and the currency code being provided in a separate element along with the value.		
   </p>

   <example><head>Multiple currencies in SOAP message</head>
   <eg>
   &lt;?xml version='1.0' ?&gt;
   &lt;env:Envelope xmlns:env="http://www.w3.org/2002/06/soap-envelope" &gt;
    &lt;env:Header&gt;
    &lt;/env:Header&gt;
    &lt;env:Body&gt;
     &lt;c:purchase&gt;
      &lt;c:apple&gt;
       &lt;c:currency&gt;JPY&lt;/c:currency&gt;
       &lt;c:amount&gt;123.55&lt;/c:amount&gt;
      &lt;/c:apple&gt;
      &lt;c:orange&gt;
       &lt;c:currency&gt;USD&lt;/c:currency&gt;
       &lt;c:amount&gt;325.78&lt;/c:amount&gt;
      &lt;/c:orange&gt;
     &lt;c:peach&gt;
      &lt;c:currency&gt;EUR&lt;/c:currency&gt;
      &lt;c:amount&gt;36.55&lt;/c:amount&gt;
     &lt;/c:peach&gt;
    &lt;/c:purchase&gt;
   &lt;env:Body&gt;
   &lt;/env:Envelope&gt;</eg>
   </example>

   <p>The following is an
   example which has the default currency in SOAP header. It is also possible to
   specify the default currency attribute in SOAP body instead of SOAP header.</p>

   <p>Although adding parameter to SOAP body requires design change for service 
    interface, adding default value into SOAP header does not affect services 
    interface.</p>

   <example>
   <head>Default attribute in SOAP header (the namespace WS-I18N is only an example)</head>
   <eg>
   &lt;?xml version='1.0' ?&gt;
   &lt;env:Envelope xmlns:env="http://www.w3.org/2002/06/soap-envelope" &gt;
    &lt;env:Header&gt;
     &lt;WS-I18N:WSinternationalization xmlns:WS-I18N="http://example.org/2002/11/21/WS-I18N"&gt;
      &lt;WS-I18N:Currency&gt;JPY&lt;/WS-I18N:Currency&gt;
     &lt;/WS-I18N:WSinternationalization&gt;
    &lt;/env:Header&gt;
   &lt;env:Body&gt;
    &lt;c:purchase&gt;
     &lt;c:apple&gt;
      &lt;c:price&gt;123.55&lt;/c:price&gt;
     &lt;/c:apple&gt;
     &lt;c:orange&gt;
      &lt;c:price&gt;325.78&lt;/c:price&gt;
     &lt;/c:orange&gt;
     &lt;c:peach&gt;
      &lt;c:price&gt;36.55&lt;/c:price&gt;
     &lt;/c:peach&gt;
     &lt;/c:purchase&gt;
    &lt;/env:Body&gt;
   &lt;/env:Envelope&gt;</eg>
   </example>

   <p>Applies to: Web Services General</p>
  </div4>
 </div3>

 <div3 id="S-019"><head>S-019: Locale Dependent Datatypes</head>
  <div4><head>Scenario Definition</head>
   <p>A sender wishes to send locale dependent data to a receiver for regional
   SOAP messaging or RPC. The receiver needs to process the locale dependent
   data correctly.</p>
  </div4>

  <div4><head>Description</head>
   <p>If a Japanese sender sends date data to a Japanese receiver, the Japanese 
   sender wishes to send data in Japanese calendar's date such as 
   H13-5-31(H means Heisei era; see Appendix <specref ref="heisei"/>)
   to the receiver.</p>

   <example>
   <head>Locale sensitive data in regional datatype</head> 
   <eg>
   &lt;?xml version='1.0' ?&gt;
   &lt;env:Header&gt;
    &lt;WS-I18N:WSinternationalization
       xmlns:WS-I18N="http://example.org/2002/11/21/WS-I18N"&gt;
     &lt;WS-I18N:dataTypePreference&gt;
      &lt;ja:JDate xmlns:ja="http//example.org/2003/12/3/ja"&gt;EYY-MM-DD&lt;/WS-I18N:JDate&gt;
     &lt;/WS-I18N:dataTypePreference&gt;
    &lt;/WS-I18N:WSinternationalization&gt;
   &lt;/env:Header&gt;
   &lt;env:Body&gt;
    &lt;departuredate&gt;H14-5-31&lt;/departuredate&gt;
   &lt;/env:Body&gt;</eg>
   </example>
   
   <p>Default is Locale neutral mode. If a sender and a receiver can handshake
   with each other using the same semantics of locale, sender can send a locale
   dependent data to a receiver, and the receiver can process the data
   consistently.</p>

   <p>If WSDL can
   describe locale sensitive datatypes, locale negotiation mechanism can be
   described in WSDL. Is it applicable requirement for interface definition 
   of WSDL? </p>

   <ednote>
   <name>KN</name>
   <date>2002-12-10</date>
   <edtext>Possible datatype: Telephone number, ZIP code etc. Needs
   feasibility assessment.
   </edtext>
   </ednote> 

   <p>There is a difference between data types such as telephone
   number, ZIP code, etc., which can be modeled as strings with patterns, and
   data types such as dates and numbers, where a connection with the value space
   (e.g. of XML Schema) may be desirable.</p>

   <p>Applies to: WSDL, SOAP, or Localizable datatype</p>
  </div4>
 </div3>

<div3 id="S-020"><head>S-020: Correlation of Data among Services in Different Languages</head>

<div4><head>Scenario Definition</head>
<p>A service is defined using "Service Oriented Architecture Derivative
Patterns Intermediary" as found in Web Services Architecture document<bibref ref="WSA"/>.</p>
</div4>

<div4><head>Description</head>
<olist>
  <item><p>Service "A" is defined as a service that returns status text and
    deployed on Providers "A1", "A2", and "A3" in different language
    configurations (locales).</p></item>
  <item><p>Provider "B" polls Service "A" on each machine and caches the
  results.</p></item>
  <item><p>Service "B" is defined as a process that returns cached results and is
    deployed on Provider "B".</p></item>
  <item><p>Requesters "C1", "C2", and "C3", each with different language
    preferences, invoke Service "B" sporadically to obtain data.</p></item>
</olist>
<ulist>
  <item><p>Provider "B" must cache faults and data in all possible languages since
    it cannot know in advance which requesters will want what data.</p></item>
  <item><p>Provider "B" must send all data to each requester.</p></item>
  <item><p>Correlation of data may prove difficult.</p></item>
</ulist>
</div4>
</div3>

</div2>



<div2><head>Locale Sensitive Presentation</head>

 <div3 id="S-021"><head>S-021: Data Formatting for End User on Receiver Side</head>
  <div4><head>Scenario Definition</head>
   <p>Data is formatted for an end user by the receiver according to the end
   user's preferences and the system conventions. This usage scenario does not
   raise any requirements. It provides an example of best practice.</p>
  </div4>
  <div4><head>Description</head>
   <p>The receiver may format data in order to display the data in a user
   interface. Locale sensitive data formatting functions are widely provided by
   internationalization functionality of operating systems, programming
   languages, or applications such as word processors and middleware. Therefore, an
   application can format locale neutral data using built-in
   internationalization functions. The details of data formatting vary across
   different systems. Therefore, Web services themselves do not guarantee
   completely identical formatting on different systems.</p>

   <p>Applies to: Web Services General</p>
  </div4>
 </div3>

 <div3 id="S-022"><head>S-022: Data Formatting on Sender Side</head>
  <div4><head>Scenario Definition</head>
   <p>The sender formats data for viewing by an end user on the receiver side.
   The sender takes care of data formatting to assure consistency of
   presentation.</p>
  </div4>

  <div4><head>Description</head>
   <ednote>
   <name>F2F</name>
   <date>2002-11-23</date>
   <edtext>Explain in more detail why the consistency is needed/desirable. Give
   examples. Ways this could be done: Producing HTML (+styles). Other reasons
   may be that the recipient asked for specific formatting.</edtext>
   </ednote>
  </div4>
 </div3>

 <div3 id="S-023"><head>S-023: Data Formatting on Receiver Side according to Sender</head>

  <div4><head>Scenario Definition</head>
   <p>A receiver formats data according to the format provided by the sender.</p>
  </div4>

  <div4><head>Description</head>
    <p>Data sent by a sender is formatted by the receiver according to format(s)
    provided by the sender. This is different from the scenarios "<specref ref="S-021"/>" or "<specref ref="S-022"/>" in that
    the center of decision and the actual execution of the formatting are
    separated. Scenarios "<specref ref="S-021"/>" or "<specref ref="S-022"/>" should be preferred because they are more
    straightforward, but this scenario may be chosen for various reasons such as:
    The sender wants to ensure consistent appearance, and the data may be used on
    the receiver side both for formatting and for further processing. </p>
    

    <ednote>
    <name>F2F</name>
    <date>2002-11-23</date>
    <edtext>We need more details and better arguments for why the server wants
    consistency, and maybe examples of what degree of consistency is
    necessary/desirable in different applications.</edtext>
    </ednote>
   

    <p>Data formatting rules should be sent to receivers together with data, in
    order to keep consistency self-descriptively, for user interface.</p> 

    
    
    <ednote>
    <name>F2F</name>
    <date>2002-11-23</date>
    <edtext>There
    may be other ways to tell the receiver what exactly to do, e.g. by
    referencing rather that including formatting rules.</edtext>
    </ednote>
    


    <p>The following is a pair of float data and an example of numeric formatting rule.</p>
    <eg>
    Value: float: 235055.55
    Numeric formatting rule: #.##.##0,##</eg> 
  
  
    <p>
    Presentation result for user interface is: </p>
    <eg>
    2.35.055,55</eg>

    <p>The following example shows a way to send a formatting rule in SOAP header 
    together with a float value.</p>

    <example>
    <head>Locale neutral formated data with formatting rule</head>
    <eg>
    &lt;?xml version='1.0' ?&gt;
    &lt;env:Header&gt;
     &lt;WS-I18N:WSinternationalization
       xmlns:WS-I18N="http://example.org/2002/11/21/WS-I18N"&gt;
      &lt;WS-I18N:presentationPreferences&gt;
       &lt;WS-I18N:NumericFormat&gt;#.##.##0,##&lt;/WS-I18N:NumericFormat&gt;
       &lt;/WS-I18N:presentationPreferences&gt;
     &lt;/WS-I18N:WSinternationalization&gt;
    &lt;/env:Header&gt;
    &lt;env:Body&gt;
     &lt;value&gt;235055.55&lt;/value&gt;
    &lt;/env:Body&gt;</eg>
    </example> 

    <p>Because a receiver receives a value in locale neutral decimal data
    together with formatting rule, the receiver can format the data for user
    interface self-descriptively.</p>

   <p>Applies to: Web Services General</p>

  </div4>
 </div3>

</div2>

<!---
 <div3><head>Locale Sensitive Data Processing</head>
        <p><emph> Similar to Scenario 2.9a</emph></p>

  <div4><head>Scenario Definition</head>
   <p>A sender wishes the receiver to process data locale sensitively based on
   sender's locale preference.</p>
  </div4>

  <div4><head>Description</head>
   <p>If data is sent as a string data type, the sender will want to indicate
   how the recipient should parse that string to obtain a data value (such as 
   as date or a number). Other examples of processing: String comparison,
   collation, deciding whether a date is a holiday, legal rules, and so on.</p>

   <p><emph>This needs some more work.</emph></p>
  </div4>
 </div3>

<div3>
<head>Locale Preference</head>

<p><emph>This scenario should be merged into 2.4x.</emph></p>
</div3>
-->


<div2>
 <head>Locale Sensitive Data Processing</head>

 <div3 id="S-024"><head>S-024: Locale Sensitive Processing by Provider(Receiver)</head>
  <div4><head>Scenario Definition</head>
   <p>The service provider needs the locale of the sender in order to perform
   locale sensitive processing. There are three levels to this: Transport layer,
   service provider layer (SOAP Header), and service layer (SOAP Body) <emph>(we
   need separate scenarios for these)</emph></p>
  </div4>
  <div4><head>Description</head>

  <div5><head>Transport Layer (HTTP, SMTP/MIME, etc.)</head>

  <p>Note that this layer includes more than just Web services. It also
  includes XHTML <bibref ref="XHTML"/>, XForms <bibref ref="XFORMS"/>, 
  and other locale-sensitive applications
  on the Web. The service provider receiving the document needs to know the
  sender's locale preferences in order to perform locale-sensitive processing.
  This may include routing based on language or regional preferences, selection
  of response language, formatting of error messages (if the SOAP document is
  unintelligible/non-parse-able, what language is the failure message returned
  in?).</p></div5>

  <div5><head>Service Provider Layer</head>

  <p>As shown elsewhere, locale-sensitive processing requires a locale to be
  passed to the Web service somehow. Most Web services, however, are not
  explicitly locale-sensitive operations. They may still need a locale in their 
  context (for obtaining resources, obtaining the preferred collation, etc.).
  The Web service author should not have to specify a Locale in the actual
  service definition, since it has no bearing on the actual data structures
  involved in the process. For example: xlxlx The Service Provider (SOAP
  container) also must process the actual SOAP message and generate SOAP fault
  messages. These may be locale- or language-affected.</p>
  </div5>

  <div5><head>Service Layer</head>

<p>Each Web service may need to have a specific locale applied to a specific
piece of data (in a data structure) or as an argument passed in. Exposing the
specific locale structure of the back-end system removed platform
independence.</p>

   <p>Applies to: Web Services General</p>

 </div5>
   </div4>
  </div3>


<div3 id="S-025"><head>S-025: Opaque Identifier to Identify a Locale</head>

<div4><head>Scenario Definition</head>

<p>Using an opaque identifier to identify a locale.</p>

<!-- 
<emph>This may already be too close to an actual solution. There are other ways
to identify locales, e.g. by more explicit identifiers, or by referencing or
listing some data that defines the locale. For example, expand the definition
of RFC3066 to define Accept-Language and Content-Language to define locale
also or define a new standard for a new pair of headers, Accept-Locale and
Content-Locale to ensure that Language and Locale preference are allowed to
be separate.</emph></p>
-->

</div4>

<div4><head>Description</head>

<p>Same locale processing does not always return same result, because
there are locale implementation differences among runtime environment.</p> 

<p>
A sender(requester) 
wishes a provider(receiver) to return a result of specific locale sensitive 
processing such as Java Locale, Windows Locale, or POSIX locale etc</p>

<p>Because user can customize locale, a sender(requester) wishes a provider(receiver) 
to return a result of locale sensitive processing based on the sender 
customized locale. </p>

<p>Applies to: A locale identification which distinguishes runtime differences
or users customization.</p>
 
</div4>
</div3>

</div2>

<div2><head>Finding Services</head>
 <div3 id="S-026"><head>S-026: Searching for Web Services</head>
	<div4><head>Scenario Definition</head>
	 <p>Searching for Web services depending on language or culture.</p>
 </div4>

<div4><head>Description</head>

<p>Repositories and search-able meta-data (such as UDDI <bibref ref="UDDI"/>) about Web services
need to provide support for multiple language searches. Transport layer
issues do not allow XML data structures to be used for resolution, except by
reference (e.g. the receiver must down-load a separate resource
asynchronously to "decode" the preference). Tags on this layer may be
necessary in place of XML data structures.</p>

 <ednote>
  <name>KN</name>
  <date>2002/12/13</date>
  <edtext>UDDI provides TAXONOMY based on the ISO 3166 Geographic Code System.</edtext>
 </ednote>
</div4>
</div3>

<div3 id="S-027"><head>S-027: Fall-Back for Internationalized Web Services</head>

<div4><head>Scenario Definition</head>

<p>There is no way for the service to find the best appropriate match when
the user's request cannot be met.</p>
</div4>
<div4><head>Description</head>

<p>If the sender specified "ja-JP" and "ja-JP" is not available at the
receiver, what should the fall-back schema be?</p>


<ednote>
<name>F2F</name>
<date>2002-11-23</date>
<edtext>Need to more clearly
define this scenario and provide examples.</edtext></ednote>

</div4>
</div3>

<!--
 <div3 id="S-014">
  <head>S-014: Request-Response vs. Connection-less</head>
 <div4>
  <head>Scenario Definition</head>
   <p>Request-response versus connection-less.</p>
 </div4>
  <div4>
   <head>Description</head>
    <ednote>
      <name>AF</name>
      <date>2002-11-27</date>
      <edtext>Needs more work.</edtext>
   </ednote>
  </div4>
 </div3>
-->

</div2>


<!--
<div3><head>Locale Container</head>

<div4><head>Scenario Definition</head>

<p><emph>The material here should be combined with 2.9 and then maybe split up
into four different pieces, according to 1.-4. below. Because this
scenario is close to sample implementation not usage scenario, this scenario
is removed, and partially integrated into each scenarios such as Locale preference</emph></p>
</div4>

<div4><head>Description</head>

<p>1. ja-JP: Sender wishes receiver process SOAP message based on receiver's
locale interpretation.</p>

<p>2. ja-JP with accessPoint: Sender wishes that receiver obtains contents of
locale by accessing an URL, then process SOAP messages based on retrieved
locale contents.</p>

<p>3. ja-JP with an addition ID: Sender wishes that receiver obtain contents
of locale based on an additional ID, then process SOAP messages based on
retrieved locale contents and receiver's locale functions.</p>

<p>4. ja-JP with some preferences:</p>

</div4>
</div3>


<div3><head>Contents of Locale Preferences</head>

<div4><head>Scenario Definition</head>

<p><emph>This may move to the introduction after some more work. Not a real
scenario.</emph></p>
</div4></div3>

-->


<div2><head>Services for Internationalization Functionality</head>

<div3 id="S-028"><head>S-028: Outsourcing Locale-Related Services</head>

<div4><head>Scenario Definition</head>

<p>Using a Web service to obtain some locale-related service, such as
formatting, collation etc.</p>
</div4>
<div4><head>Description</head>

<p>Some locale-related tasks are not easy to describe by an exchangeable data
structure. Also, not all systems will have code for all locales. It may
therefore be desirable in some cases to 'outsource' locale services.</p>

<p>Example 1: Formatting a date according to traditional Thai conventions
(the full text of the formatted date is very long)</p> 

<ednote>
 <name>F2F</name>
 <date>2002-11-23</date>
 <edtext>Add example.</edtext>
</ednote>

<p>Example 2: Converting a date according to local rules that may not be
predictable.</p>

<p>Example 3: Collation data can be very large, and collation may include
additional domain-specific preprocessing in addition to the simple comparison
of strings. It may therefore in some cases be more efficient to send the data
to be sorted to another system.</p>
</div4>
</div3>

<div3 id="S-029"><head>S-029: Propagating Updates related to Locales</head>

<div4><head>Scenario Definition</head>

<p>Using Web services to update locale-related data that may change
dynamically and/or in ways that are not easily predictable.</p>
</div4>
<div4><head>Description</head>

<p>Some kinds of data needed for culturally sensitive operations is not
easily predictable. Web services may be used to update such data, either by
polling for updates or by sending out updates.</p>

<p>Example: Certain calendars depend on actually observed events, such as the
actual observation of the new moon. </p>

<ednote>
<name>F2F</name>
<date>2002-11-23</date>
<edtext>Add more specific details here.</edtext>
</ednote>

<p>Example: Jurisdictions once in a while may change their rules for which
time-zones they are in at which time of the year.</p>

<p>Issues: Scalability; requests may concentrate at specific times; polling
may have to be repeated over and over without any actual updates.</p>
</div4></div3>

</div2>


<div2><head>Development of Internationalized Web Services</head>

<div3 id="S-030"><head>S-030: Internationalizing an Existing Web Service</head>

<div4><head>Scenario Definition</head>

<p>If a Web service starts out uninternationalized and is later
internationalized, it must be re-deployed as a separate service because the
original service contract has changed.</p>
</div4>

<div4><head>Description</head>

<p>The web services developer is solely responsible for supplying the fields,
logic, and semantics that will be used to achieve i18n capabilities. Each
service will vary in its approach and may not bother to supply a suitable
mechanism. Without guidance from the client, assumptions have to be made that
are unsuitable. For example, the locale of the server may be used to format
the response. When the service is internationalized, the only option is to
ask for locale as an additional input, changing the service contract.</p>

<p>There is an important functional and semantic difference between a field
supplied in the actual service invocation (that is, as part of the data) and
one supplied in the envelope (that is, as part of the protocol) because when
supplied as part of the data, developers must always take care to create,
populate, read, and process the fields. Internationalization of an existing
service therefore takes the form of deploying a new service (since the inputs
have changed).</p>

<p>By contrast, if locale and language preferences are part of the "context"
(in the envelope, for example), the developer gains several advantages.
First, both the provider and the service can read the locale and language
preference. (The service must be provided with a specific API to obtain the
locale and language from the provider, or it can be silently managed by the
provider.) Services that require external environmental changes to activate
their locale-sensitivity can have the provider perform this processing for
them. Multiple services in the same "chain" can inherit the same locale and
language context. Most important, though, the client-side environment can be
optimized to provide the locale and language preferences of the end user
automatically, without developers having to write code to obtain the values
and populate the inputs of the Web Service. In addition, Web Service authors
can add international or multi-language support to services after initial
deployment without changing service descriptors (WSDL and XSD) that may
already be in wide use.</p>
</div4></div3>

<div3 id="S-031"><head>S-031: Communicating Available Options</head>

<div4><head>Scenario Definition</head>

<p>There is no way for the service to communicate what language and
formatting options are available.</p>
</div4>
<div4><head>Description</head>

<p>If a Web service requires that a language, locale, or formatting
preference in a service description (WSDL), how can the sender know what
values will have meaning at the receiver. For example, POSIX
 locales for a C
program are very different than (say) Windows LCID values.</p>

<p>As a result, developers of internationalized Web services (especially
those that support multi-lingual operations - that is, servers that can
provide responses in a variety of human languages and dialects) have to
provide the ability to external users, whose platforms and programming
languages may be maximally different than their own, to know what options the
service supports.</p>
</div4>
</div3>

</div2>

<div2><head>Template</head>
  <div3><head>Title</head>
  <div4><head>Scenario Definition</head></div4>
  <div4><head>Description</head>
</div4>
</div3>
</div2>

</div1>

<div1><head>Use Case</head>

 <ednote>
 <name>KN</name>
 <date>2002-12-10</date>
 <edtext>Use Case is added based on usage scenarios. e.g. Flight Schedule, Accounting Data
 </edtext>
 </ednote>

</div1>

</body>

<back>
<!--
<inform-div1 id="class">
<head>Deliverables Classification</head>

<p>This is the first pass at classifying the Usage Scenarios into
different activities that WSTF might undertake. The current use cases are
readily divided into just four categories. Some of the items appear more than
once. All items appear at least once.</p>

<p>The four categories are:</p>
<ulist>
  <item><p>Best Practices</p></item>
  <item><p>Implementation Guidelines</p></item>
  <item><p>Language Negotiation</p></item>
  <item><p>Locale Negotiation</p></item>
</ulist>

<table border="1" id="classification">
  <caption>Usage Scenario Classifications</caption>
    <colgroup align="left" width="10%"/>
    <colgroup align="left" width="35%"/>
    <colgroup align="left" width="55%"/>
  <tbody>
    <tr>
      <th align="center">Classification</th>
      <th align="center">Activity</th>
      <th align="center">Scenarios</th>
    </tr>
    <tr>
      <td>Best Practices</td>
      <td>Create best practices document for end users. 

        "End users" means people who are
        creating Web services. That is, these are guidelines for making an
        internationalized Web service using existing standards.
      </td>
      <td>
      <ulist>
      <item><p><specref ref="S-001"/></p></item>
      <item><p><specref ref="S-002"/></p></item>
      <item><p><specref ref="S-007"/></p></item>
      <item><p><specref ref="S-016"/></p></item>
      <item><p><specref ref="S-017"/></p></item>
      <item><p><specref ref="S-018"/></p></item>
      <item><p><specref ref="S-019"/></p></item>
      <item><p><specref ref="S-021"/></p></item>
      <item><p><specref ref="S-022"/></p></item>
      <item><p><specref ref="S-023"/></p></item>
      <item><p><specref ref="S-028"/></p></item>
      <item><p><specref ref="S-029"/></p></item>
      </ulist>
      </td>
    </tr>
    <tr>
      <td>Implementation Guidelines</td>
      <td>Create best practices document for technology implementers. 

        "Technology implementers" means
        software that provides a Web services container or operating
        platform. That is, these are guidelines for building a Web service
        development tool or server.
      </td>
      <td>
      <ulist>
       <item><p><specref ref="S-001"/></p></item>
       <item><p><specref ref="S-007"/></p></item>
       <item><p><specref ref="S-012"/></p></item>
       <item><p><specref ref="S-021"/></p></item>
       <item><p><specref ref="S-027"/></p></item>
       <item><p><specref ref="S-030"/></p></item>
       </ulist>
      </td>      
    </tr>
    <tr>
      <td>Language Management</td>
      <td>Create a standard for negotiating natural language preferences. 

        These are issues related specifically
        to language negotiation that can be accomplished without any
        reference to locales or other user preferences. That is, these are
        requirements that are similar to RFC2717 or to the xml:lang aspect of
        XML.
      </td>
      <td>
      <ulist>
      <item><p><specref ref="S-003"/></p></item>
      <item><p><specref ref="S-004"/></p></item>
      <item><p><specref ref="S-005"/></p></item>
      <item><p><specref ref="S-006"/></p></item>
      <item><p><specref ref="S-009"/></p></item>
      <item><p><specref ref="S-010"/></p></item>
      <item><p><specref ref="S-015"/></p></item>  
      <item><p><specref ref="S-020"/></p></item>
      <item><p><specref ref="S-026"/></p></item>
      <item><p><specref ref="S-031"/></p></item>
      </ulist>   
      </td>
    </tr>
    <tr>
      <td>Locale/I18n Context Management</td>
      <td>Create a standard for locales, locale tags, user
        internationalization preferences or "i18n-context". 

        These are either issues directly
        related to locale negotiation/i18n-context or which have broader
        implications than just language negotiation.
      </td>
      <td>
      <ulist>
      <item><p><specref ref="S-008"/></p></item>
      <item><p><specref ref="S-009"/></p></item>
      <item><p><specref ref="S-011"/></p></item>
      <item><p><specref ref="S-013"/></p></item>
      <item><p><specref ref="S-020"/></p></item>
      <item><p><specref ref="S-024"/></p></item>  
      <item><p><specref ref="S-025"/></p></item>
      <item><p><specref ref="S-028"/></p></item> 
      <item><p><specref ref="S-030"/></p></item>    
      <item><p><specref ref="S-031"/></p></item>
      </ulist> 
      </td>
    </tr>
  </tbody>
</table>


<ednote>
 <name>Regular Tele-conference</name>
 <date>2003-01-07</date>
 <edtext>
  Categories: "best practices" vs. "best problems"? Suggestion that we need to get more coverage for neglected areas, that we need to more "orthogonally" define the triage categories, and that we need to do more research to achieve "total coverage". Also agreed that some of the "best practices/implementation guidelines" items describe well-known or well-understood problems that have concrete solutions and that some merely describe areas where more works needs doing or for which there are not well-understood solutions.
 </edtext>
</ednote>

<ednote>
 <name>Regular Tele-conference</name>
 <date>2003-01-07</date>
 <edtext> 
   Discussed the categories themselves. Dissatisfaction with them as is was expressed. They don't cover the requirements areas neatly and there is a lot of crossover. Concern that "implementation guidelines" is an inaccurate title, since these aren't really guidelines.
 </edtext>
</ednote>

</inform-div1>
-->


<inform-div1 id="refs">
<head>References</head>


<blist>
<bibl key="WSA" href="http://www.w3.org/TR/2003/WD-ws-arch-20030514/" id="WSA">
W3C Working Draft "Web Services Architecture",
David Booth, Michael Champion, Chris Ferris, Francis McCabe, Eric Newcomer, David Orchard,
14 May 2003</bibl>

<bibl key="WSAR" href="http://www.w3.org/TR/2002/WD-wsa-reqs-20021114" id="WSAR">
W3C Working Draft "Web Services Architecture Requirements",
Daniel Austin, Abbie Barbir, Christopher Ferris, Sharad Garg, 14 November 2002</bibl>

<bibl key="WSAUS" href="http://www.w3.org/TR/2003/WD-ws-arch-scenarios-20030514/" id="WSAUS">
W3C Working Draft "Web Services Architecture Usage Scenarios",
Hugo Haas, David Orchard, 14 May 2003</bibl>

<bibl key="WSAG" href="http://www.w3.org/TR/2003/WD-ws-gloss-20030514/" id="WSAG">
W3C Working Draft "Web Services Glossary",
Allen Brown, Hugo Haas, 14 May 2003</bibl>

<bibl key="SOAP-0" href="http://www.w3.org/TR/2003/PR-soap12-part0-20030507/" id="SOAP-0">
W3C Proposed Recommendation  "SOAP Version 1.2 Part 0: Primer",
Nilo Mitra, 7 May 2003</bibl>

<bibl key="SOAP-1" href="http://www.w3.org/TR/2003/PR-soap12-part1-20030507/" id="SOAP-1">
W3C Proposed Recommendation  "SOAP Version 1.2 Part 1: Messaging Framework",
Martin Gudgin, Marc Hadley, Noah Mendelsohn, Jean-Jacques Moreau, Henrik Frystyk Nielsen,
7 May 2003</bibl>

<bibl key="SOAP-2" href="http://www.w3.org/TR/2003/PR-soap12-part2-20030507/" id="SOAP-2">
W3C Proposed Recommendation  "SOAP Version 1.2 Part 2: Adjuncts",
Martin Gudgin, Marc Hadley, Noah Mendelsohn, Jean-Jacques Moreau, Henrik Frystyk Nielsen,
7 May 2003</bibl>

<bibl key="SOAP-AF" href="http://www.w3.org/TR/2002/WD-soap12-af-20020924/" id="SOAP-AF">
W3C Working Draft "SOAP 1.2 Attachment Feature",
Henrik Frystyk Nielsen, Hervé Ruellan, 24 September 2002</bibl>

<bibl key="SOAP-EB" href="http://www.w3.org/TR/2002/NOTE-soap12-email-20020703" id="SOAP-EB">
W3C Note  "SOAP Version 1.2 Email Binding",
Highland Mary Mountain, Jacek Kopecky, Stuart Williams, Glen Daniels, Noah Mendelsohn,
3 July 2002</bibl>

<!--
<bibl key="SOAP-XML" href="http://www.w3.org/2000/xp/Group/2/06/18/draft-baker-soap-media-reg-01.txt" id="SOAP-XML">  
</bibl>
-->

<bibl key="WSDL-V12" href="http://www.w3.org/TR/2003/WD-wsdl12-20030303" id="WSDL-V12">
W3C Working Draft "Web Services Description Language (WSDL) Version 1.2",
Roberto Chinnici, Martin Gudgin, Jean-Jacques Moreau, Sanjiva Weerawarana, 3 March 2003</bibl>

<bibl key="WSDL-B" href="http://www.w3.org/TR/2003/WD-wsdl12-bindings-20030124" id="WSDL-B">
W3C Working Draft "Web Services Description Language (WSDL) Version 1.2: Bindings",
Jean-Jacques Moreau, Jeffrey Schlimmer, 24 January 2003</bibl>

<bibl key="XML" href="http://www.w3.org/TR/2000/REC-xml-20001006" id="XML">
W3C Recommendation "Extensible Markup Language (XML) 1.0 (Second Edition)",
Tim Bray, Jean Paoli, C. M. Sperberg-McQueen, Eve Maler, 6 October 2000</bibl>

<bibl key="CHARMOD" href="http://www.w3.org/TR/2002/WD-charmod-20020430/" id="CHARMOD">
W3C Working Draft "Character Model for the World Wide Web 1.0",
Martin J. Dürst, François Yergeau, Richard Ishida, Misha Wolf, Asmus Freytag, Tex Texin,
30 April 2002</bibl>

<bibl key="XML-JP" href="http://www.w3.org/TR/2000/NOTE-japanese-xml-20000414/" id="XML-JP">
W3C Note "XML Japanese Profile", MURATA Makoto, 14 April 2000
</bibl>

<bibl key="RFC2616" href="http://www.ietf.org/rfc/rfc2616.txt" id="RFC2616">
Request for Comments: 2616 "Hypertext Transfer Protocol -- HTTP/1.1",  R. Fielding, J. Gettys, J. Mogul, H. Frystyk, L. Masinter, P. Leach, T. Berners-Lee, June 1999
</bibl>

<bibl key="XMLS-2" href="http://www.w3.org/TR/2001/REC-xmlschema-2-20010502/" id="XMLS-2">
W3C Recommendation "XML Schema Part 2: Datatypes",
Paul V. Biron, Ashok Malhotra, 02 May 2001</bibl>

<bibl key="UDDI" href="http://uddi.org/pubs/uddi_v3.htm" id="UDDI">
"UDDI Version 3.0 Published Specification",
Tom Bellwood, Luc Clément, David Ehnebuske, Andrew Hately, Maryann Hondo, Yin Leng Husband,
Karsten Januszewski, Sam Lee, Barbara McKee, Joel Munter, Claus von Riegen, 19 July 2002</bibl>

<bibl key="RFC2279" href="http://www.ietf.org/rfc/rfc2279.txt" id="RFC2279"> 
IETF (Internet Engineering Task Force). RFC 2279: UTF-8, a transformation format of ISO 10646,
F. Yergeau, 1998</bibl>

<bibl key="RFC2781" href="http://www.ietf.org/rfc/rfc2781.txt" id="RFC2781">
IETF (Internet Engineering Task Force). RFC 2781: UTF-16, an encoding of ISO 10646,
P. Hoffman, F. Yergeau. 2000</bibl>

<bibl key="XHTML" href="http://www.w3.org/TR/xhtml1/" id="XHTML">
W3C Recommendation "XHTML 1.0 The Extensible HyperText Markup Language (Second Edition)", 
26 January 2000, revised 1 August 2002</bibl>

<bibl key="XFORMS" href="http://www.w3.org/TR/2002/CR-xforms-20021112/" id="XFORMS">
W3C Candidate Recommendation "XForms 1.0",
Micah Dubinko, Leigh L. Klotz, Jr., Roland Merrick, T. V. Raman, 12 November 2002</bibl>

</blist>
</inform-div1>

<inform-div1>
 <head>Acknowledgements</head>
 <p>This document is the work of the Web Services Task Force
 of the W3C Internationalization Working Group.</p>
</inform-div1>

<inform-div1 id="heisei">
  <head>Heisei</head>

<p>The imperial Calendar is commonly used in Japan.  Heisei is the current era,
and it started on January 8th, 1989. Year 2002 is Year Heisei 14.
Showa is the previous era, which ended on January 7th, 1989 or Showa 64.</p>

</inform-div1>

</back>

</spec>
 
