Web Services Eventing (WS-Eventing)

Editor's Draft $Date: 2009/06/04 20:53:48 $

Latest version:
http://www.w3.org/TR/ws-eventing
Previous version:
http://www.w3.org/TR/2009/WD-ws-eventing-20090317
Editors:
Doug Davis, IBM
Ashok Malhotra, Oracle
Katy Warr, IBM
Wu Chou, Avaya

Abstract

This specification describes a protocol that allows Web services to subscribe to or accept subscriptions for event notification messages.

Status of this Document

This document is an editors' copy that has no official standing.

Table of Contents

1 Composable Architecture
2 Introduction
   2.1 Requirements
   2.2 Delivery Modes
   2.3 Subscription Managers
   2.4 Example
3 Notations and Terminology
   3.1 Notational Conventions
   3.2 Considerations on the Use of Extensibility Points
   3.3 XML Namespaces
   3.4 Terminology
   3.5 Compliance
4 Subscription Messages
   4.1 Subscribe
   4.2 Renew
   4.3 GetStatus
   4.4 Unsubscribe
   4.5 Subscription End
5 Notifications
6 Faults
   6.1 Fault Detail RetryAfter Element
   6.2 DeliveryModeRequestedUnavailable
   6.3 InvalidExpirationTime
   6.4 UnsupportedExpirationType
   6.5 FilteringNotSupported
   6.6 FilteringRequestedUnavailable
   6.7 EventSourceUnableToProcess
   6.8 UnableToRenew
   6.9 InvalidMessage
   6.10 DeliveryFormatRequestUnavailable
   6.11 EmptyFilter
   6.12 UnusableEPR
7 Security Considerations
   7.1 Message Security
   7.2 Access Control
8 Implementation Considerations
9 Acknowledgements
10 References

Appendices

A Service Metadata for Eventing
B XML Schema
C WSDL
D WSDL for Standard Wrapped Delivery
E Change Log


1 Composable Architecture

By using the XML, SOAP [SOAP 1.1], [SOAP 1.2], and WSDL [WSDL 1.1] extensibility models, the Web service specifications (WS-*) are designed to be composed with each other to provide a rich set of tools to provide security in the Web services environment. This specification specifically relies on other Web service specifications to provide secure, reliable, and/or transacted message delivery and to express Web service and client policy.

2 Introduction

Web services often want to receive messages when events occur in other services and applications. A mechanism for registering interest is needed because the set of Web services interested in receiving such messages is often unknown in advance or will change over time. This specification defines a protocol for one Web service (called a "subscriber") to register interest (called a "subscription") with another Web service (called an "event source") in receiving messages about events (called "notifications"). The subscriber may manage the subscription by interacting with a Web service (called the "subscription manager") designated by the event source.

To improve robustness, a subscription may be leased by an event source to a subscriber, and the subscription expires over time. The subscription manager provides the ability for the subscriber to renew or cancel the subscription before it expires.

There are many mechanisms by which event sources may deliver events to event sinks. This specification provides an extensible way for subscribers to identify the delivery mechanism they prefer. While asynchronous, pushed delivery is defined here, the intent is that there should be no limitation or restriction on the delivery mechanisms capable of being supported by this specification.

2.2 Delivery Modes

While the general pattern of asynchronous, event-based messages is extremely common, different applications often require different notification delivery mechanisms. For instance, in some cases a simple asynchronous message is optimal, while other situations may work better if the event consumer can poll for notification in order to control the flow and timing of message arrival. Some consumers will require notifications to be wrapped in a standard "event" SOAP envelope, while others will prefer messages to be delivered unwrapped. Some consumers may require notifications to be delivered reliably, while others may be willing to accept best-effort event delivery.

In order to support this broad variety of event delivery requirements, this specification introduces an abstraction called a Delivery Mode and an abstraction called Delivery Format. These concepts are used as an extension points, so that event sources and event consumers may freely create new delivery mechanisms that are tailored to their specific requirements. This specification provides a minimal amount of support for delivery mode and format negotiation by allowing an event source to provide a list of supported delivery modes and formats in response to a subscription request specifying a delivery mode or format it does not support.

When the Delivery Format feature is engaged the formatting of the going events occurs after any filtering. This ensures that regardless of what type of formatting might occur, the same Filter dialect/expression can be used to subset the event stream.

This specification defines a single delivery mode, Push Mode, which is simple asynchronous messaging.

This specification specifies two delivery formats: wrapped and unwrapped. Use of wrapped format indicates that notification messages should be contained in a wrapper element. Use of unwrapped format indicates that notification messages are not wrapped.

2.4 Example

Example 2-1 lists a hypothetical request to create a subscription for storm warnings.

Lines (07-09) in Example 2-1 indicate the message is a request to create a subscription, and Line (16) indicates that it is sent to a hypothetical event source of ocean events.

While Lines (13-15) indicate where a reply should be sent, Lines (20-29) indicate where and how notifications should be delivered; there is no requirement that these match. The absence of a Mode attribute on Line (20) indicates that notifications should be delivered using Push mode; that is, they should be asynchronously sent as SOAP messages to the endpoint described in lines (21-28). Note that Lines (25-27) illustrate a typical pattern where the event sink lists a reference parameter (Line 26) that identifies the subscription and will be included in each notification.

Example 2-2 lists a hypothetical response to the request in Example 2-1.

Lines (07-09) in Example 2-2 indicate this message is a response to a request to create a subscription, and Lines (10-12) indicate that it is a response to the request in Example 2-1. Lines (17-26) provide the subscription manager EPR for this subscription, and Line (27) indicates the subscription will expire in 30 hours unless renewed.

3 Notations and Terminology

This section specifies the notations, namespaces, and terminology used in this specification.

3.1 Notational Conventions

The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119 [RFC2119].

This specification uses the following syntax to define normative outlines for messages:

  • The syntax appears as an XML instance, but values in italics indicate data types instead of values.

  • Characters are appended to elements and attributes to indicate cardinality:

    • "?" (0 or 1)

    • "*" (0 or more)

    • "+" (1 or more)

  • The character "|" is used to indicate a choice between alternatives.

  • The characters "(" and ")" are used to indicate that contained items are to be treated as a group with respect to cardinality or choice.

  • The characters "[" and "]" are used to call out references and property names.

  • Ellipsis (i.e. "...") indicate a point of extensibility.

  • XML namespace prefixes (see Table 3-1) are used to indicate the namespace of the element being defined.

In addition to Message Information Header properties [WS-Addressing], this specification uses the following properties to define messages:

[Headers]

Unordered message headers.

[Action]

The value to be used for the wsa:Action URI.

[Body]

A message body.

These properties bind to a SOAP Envelope as follows:

<s:Envelope>
  <s:Header>
    [Headers]
    <wsa:Action>[Action]</wsa:Action>
    ...
  </s:Header>
  <s:Body>[Body]</s:Body>
</s:Envelope>

3.5 Compliance

An implementation is not compliant with this specification if it fails to satisfy one or more of the MUST or REQUIRED level requirements defined herein. A SOAP Node MUST NOT use the XML namespace identifier for this specification (listed in 3.3 XML Namespaces) within SOAP Envelopes unless it is compliant with this specification.

Normative text within this specification takes precedence over the XML Schema and WSDL descriptions, which in turn take precedence over outlines, which in turn take precedence over examples.

All messages defined by this specification MUST be sent to a Web service that is addressable by an EPR (see [WS-Addressing]).

4 Subscription Messages

To create, renew, and delete subscriptions, subscribers send request messages to event sources and subscription managers.

When an event source accepts a request to create a subscription, it typically does so for a given amount of time, although an event source may accept an indefinite subscription with no time-based expiration. If the subscription manager accepts a renewal request, it updates that amount of time. During that time, notifications are delivered by the event source to the requested event sink. An event source may support filtering to limit notifications that are delivered to the event sink; if it does, and a subscribe request contains a filter, the event source sends only notifications that match the requested filter. The event source sends notifications until one of the following happens: the subscription manager accepts an unsubscribe request for the subscription; the subscription expires without being renewed; or the event source cancels the subscription prematurely. In this last case, the event source makes a best effort to indicate why the subscription ended.

In the absence of reliable messaging at the application layer (e.g. [WS-ReliableMessaging]), messages defined herein are delivered using the quality of service of the underlying transport(s) and on a best-effort basis at the application layer.

4.1 Subscribe

To create a subscription, a subscriber sends a request message of the following form to an event source:

The following describes additional, normative constraints on the outline listed above:

[Body]/wse:Subscribe/wse:EndTo

Where to send a SubscriptionEnd message if the subscription is terminated unexpectedly. (See 4.5 Subscription End.) If present, this element MUST be of type wsa:EndpointReferenceType. Default is not to send this message. The endpoint to which the EndTo EPR refers MUST support the SubcriptionEndPortType portType.

Note, subscribers wishing to correlate SubscriptionEnd messages with the subscription to which they apply MAY wish to add a distinguishing reference parameter to the EndTo EPR. For convenience in this common situation, this specification defines a global element, wse:Identifier of type xs:anyURI, that MAY be used as a distinguishing reference parameter.

[Body]/wse:Subscribe/wse:Delivery

A delivery destination for notification messages, using some delivery mode. See 2.2 Delivery Modes for details.

[Body]/wse:Subscribe/wse:Delivery/@Mode

The delivery mode to be used for notification messages sent in relation to this subscription. Implied value is "http://www.w3.org/2009/02/ws-evt/DeliveryModes/Push", which indicates that Push Mode delivery should be used. See 2.2 Delivery Modes for details.

If the event source does not support the requested delivery mode, the request MUST fail, and the event source MUST generate a wse:DeliveryModeRequestedUnavailable fault indicating that the requested delivery mode is not supported.

[Body]/wse:Subscribe/wse:Delivery/@Mode="http://www.w3.org/2009/02/ws-evt/DeliveryModes/Push"

Value of [Body]/wse:Subscribe/wse:Delivery MUST contain at least the single element, wse:NotifyTo, that contains the endpoint reference to which notification messages should be sent. The value of this element is not constrained for other delivery modes.

[Body]/wse:Subscribe/wse:Format

This optional element contains the delivery format to be used for notification messages sent in relation to this subscription. Implied value is "http://www.w3.org/2009/02/ws-evt/DeliveryFormats/Unwrap", which indicates that unwraped delivery should be used. See Section 2.2 Delivery Modes for details.

If the event source does not support the requested delivery format, the request MUST generate a wse:DeliveryFormatRequestedUnavailable fault indicating that the requested delivery format is not supported.

[Body]/wse:Subscribe/wse:Format@Name="http://www.w3.org/2009/02/ws-evt/DeliveryFormats/Unwrap"

Indicate the unwrapped event delivery format.

[Body]/wse:Subscribe/wse:Format@Name="http://www.w3.org/2009/02/ws-evt/DeliveryFormats/Wrap"

Indicate the wrapped event delivery format.

[Body]/wse:Subscribe/wse:Expires

Requested expiration time for the subscription. (No implied value.) The event source defines the actual expiration and is not constrained to use a time less or greater than the requested expiration. The expiration time may be a specific time or a duration from the subscription's creation time. Both specific times and durations are interpreted based on the event source's clock.

If this element does not appear, then the request is for a subscription that will not expire. That is, the subscriber is requesting the event source to create a subscription with an indefinite lifetime. If the event source grants such a subscription, it may be terminated by the subscriber using an Unsubscribe request, or it may be terminated by the event source at any time for reasons such as connection termination, resource constraints, or system shut-down.

If the expiration time is either a zero duration or a specific time that occurs in the past according to the event source, then the request MUST fail, and the event source MUST generate a wse:InvalidExpirationTime fault indicating that an invalid expiration time was requested.

Some event sources may not have a "wall time" clock available, and so are only able to accept durations as expirations. If such a source receives a Subscribe request containing a specific time expiration, then the request MAY fail; if so, the event source MUST generate a wse:UnsupportedExpirationType fault indicating that an unsupported expiration type was requested.

[Body]/wse:Subscribe/wse:Filter

A Boolean expression in some dialect, either as a string or as an XML fragment (see [[Body]/wse:Subscribe/wse:Filter/@Dialect ]). If the expression evaluates to false for a notification, the notification MUST NOT be sent to the event sink. Implied value is an expression that always returns true. If the event source does not support filtering, then a request that specifies a filter MUST fail, and the event source MUST generate a wse:FilteringNotSupported fault indicating that filtering is not supported.

If the event source supports filtering but cannot honor the requested filtering, the request MUST fail, and the event source MUST generate a wse:FilteringRequestedUnavailable fault indicating that the requested filter dialect is not supported.

It is possible for a Subscribe request to contain a filter that will never evaluate to true for the lifetime of the Subscription. If an Event Source detects this condition it MUST generate a wse:EmptyFilter fault in response to the Subscribe request message.

[Body]/wse:Subscribe/wse:Filter/@Dialect

Implied value is "http://www.w3.org/TR/1999/REC-xpath-19991116".

While an XPath predicate expression provides great flexibility and power, alternate filter dialects may be defined. For instance, a simpler, less powerful dialect might be defined for resource-constrained implementations, or a new dialect might be defined to support filtering based on data not included in the notification message itself. If desired, a filter dialect could allow the definition of a composite filter that contained multiple filters from other dialects.

[Body]/wse:Subscribe/wse:Filter/@Dialect=" http://www.w3.org/TR/1999/REC-xpath-19991116 "

Value of [Body]/wse:Subscribe/wse:Filter is an XPath [XPath 1.0] predicate expression (PredicateExpr); the context of the expression is:

  • Context Node: the SOAP Envelope containing the notification.

  • Context Position: 1.

  • Context Size: 1.

  • Variable Bindings: None.

  • Function Libraries: Core Function Library [XPath 1.0].

  • Namespace Declarations: The [in-scope namespaces] property [XML Infoset] of /s:Envelope/s:Body/*/wse:Filter.

Other message information headers defined by WS-Addressing [WS-Addressing] MAY be included in the request and response messages, according to the usage and semantics defined in WS-Addressing.

Other components of the outline above are not further constrained by this specification.

If included within the Subscribe request message, the wse:NotifyTo and wse:EndTo SHOULD have some cursory validity checking performed before the Subscribe response is returned. While not all errors can be detected prior to sending a message to those EPRs, some obvious ones can be detected. For example, an unsupported transport specified within the wsa:Address IRI. Detecting these errors during Subscribe processing will lessen the chances of the subscriber creating an unusable subscription. If this check is performed and a problem is detected then the event source MUST generate a wse:UnusableEPR fault rather than returning the SubscribeResponse message.

If the event source accepts a request to create a subscription, it MUST reply with a response of the following form:

[Action]
  http://www.w3.org/2009/02/ws-evt/SubscribeResponse

[Body]
  <wse:SubscribeResponse ...>
    <wse:SubscriptionManager>
      wsa:EndpointReferenceType
    </wse:SubscriptionManager>
    <wse:Expires>(xs:dateTime | xs:duration)</wse:Expires>
    xs:any*
  </wse:SubscribeResponse>

The following describes additional, normative constraints on the outline listed above:

[Body]/wse:SubscribeResponse/wse:SubscriptionManager

The EPR of the subscription manager for this subscription.

In some cases, it is convenient for all EPRs issued by a single event source to address a single Web service and use a reference parameter to distinguish among the active subscriptions. For convenience in this common situation, this specification defines a global element, wse:Identifier of type xs:anyURI, that MAY be used as a distinguishing reference parameter if desired by the event source.

[Body]/wse:SubscribeResponse/wse:Expires

The expiration time assigned by the event source. The expiration time MAY be either an absolute time or a duration but SHOULD be of the same type as the requested expiration (if any).

If this element does not appear, then the subscription will not expire. That is, the subscription has an indefinite lifetime. It may be terminated by the subscriber using an Unsubscribe request, or it may be terminated by the event source at any time for reasons such as connection termination, resource constraints, or system shut-down.

Other components of the outline above are not further constrained by this specification.

If the event source chooses not to accept a subscription, the request MUST fail, and the event source MUST generate a wse:EventSourceUnableToProcess fault indicating that the request was not accepted.

Example 4-1 lists another hypothetical request to create a subscription.

(01) <s12:Envelope 
(02)     xmlns:s12="http://www.w3.org/2003/05/soap-envelope"
(03)     xmlns:wsa="http://www.w3.org/2005/08/addressing"
(04)     xmlns:wse="http://www.w3.org/2009/02/ws-evt"
(05)     xmlns:ew="http://www.example.com/warnings" >
(06)   <s12:Header>
(07)     <wsa:Action>
(08)       http://www.w3.org/2009/02/ws-evt/Subscribe
(09)     </wsa:Action>
(10)     <wsa:MessageID>
(11)       uuid:e1886c5c-5e86-48d1-8c77-fc1c28d47180
(12)     </wsa:MessageID>
(13)     <wsa:ReplyTo>
(14)      <wsa:Address>http://www.example.com/MyEvEntsink</wsa:Address>
(15)      <wsa:ReferenceParameters>
(16)        <ew:MySubscription>2597</ew:MySubscription>
(17)      </wsa:ReferenceParameters>
(18)     </wsa:ReplyTo>
(19)     <wsa:To>http://www.example.org/oceanwatch/EventSource</wsa:To>
(20)   </s12:Header>
(21)   <s12:Body>
(22)     <wse:Subscribe>
(23)       <wse:EndTo>
(24)         <wsa:Address>
(25)           http://www.example.com/MyEventSink
(26)         </wsa:Address>
(27)         <wsa:ReferenceParameters>
(28)           <ew:MySubscription>2597</ew:MySubscription>
(29)         </wsa:ReferenceParameters>
(30)       </wse:EndTo>
(31)       <wse:Delivery>
(32)         <wse:NotifyTo>
(33)           <wsa:Address>
(34)             http://www.other.example.com/OnStormWarning
(35)           </wsa:Address>
(36)           <wsa:ReferenceParameters>
(37)             <ew:MySubscription>2597</ew:MySubscription>
(38)           </wsa:ReferenceParameters>
(39)         </wse:NotifyTo>
(40)       </wse:Delivery>
(41)       <wse:Expires>2004-06-26T21:07:00.000-08:00</wse:Expires>
(42)       <wse:Filter xmlns:ow="http://www.example.org/oceanwatch" >
(43)         /*/ow:Speed/[node() &gt; 50]
(44)       </wse:Filter>
(45)     </wse:Subscribe>
(46)   </s12:Body>
(47) </s12:Envelope>

Like the request in Example 2-1, Lines (07-09) of Example 4-1 indicate the message is a request to create a subscription. Line (19) indicates that it is sent to a hypothetical event source of ocean events.

Lines (13-18) indicate where to send the response to this request, Lines (23-30) indicate where to send a SubscriptionEnd message if necessary, and Lines (31-34) indicate how and where to send notifications.

Line (41) indicates the event sink would prefer to have the subscription expire on 26 June 2004 at 9:07 PM Pacific time.

Lines (42-44) indicate the event sink only wants weather reports where the speed of wind is greater than 50.

Example 4-2 lists a hypothetical response to the request in Example 4-1.

Like the response in Example 2-2, Lines (08-10) of Example 4-2 indicate this message is a response to a request to create a subscription, and Lines (11-13) indicate that it is a response to the request in Example 4-1 . Lines (14-17) indicate the response is sent to the event sink indicated in Lines (13-18) of Example 4-1. Lines (21-30) provide the address of the subscription manager for this subscription; note that this particular response uses the global wse:Identifier element defined by this specification. Finally, Line (31) indicates the subscription will expire on 1 July 2004 unless renewed; there is no requirement that this time be necessarily longer or shorter than the requested expiration (Line (41) of Example 4-1).

4.2 Renew

To update the expiration for a subscription, subscription managers MUST support requests to renew subscriptions.

To renew a subscription, the subscriber sends a request of the following form to the subscription manager:

Components of the outline listed above are additionally constrained as for a request to create a subscription (see 4.1 Subscribe). Other components of the outline above are not further constrained by this specification.

If the subscription manager accepts a request to renew a subscription, it MUST reply with a response of the following form:

[Action]
  http://www.w3.org/2009/02/ws-evt/RenewResponse

[Body]
  <wse:RenewResponse ...>
    <wse:Expires>(xs:dateTime | xs:duration)</wse:Expires> ?
    xs:any*
  </wse:RenewResponse>

Components of the outline listed above are constrained as for a response to a subscribe request (see 4.1 Subscribe) with the following addition(s):

[Body]/wse:RenewResponse/wse:Expires

If the requested expiration is a duration, then the implied start of that duration is the time when the subscription manager starts processing the Renew request.

If the subscription manager chooses not to renew this subscription, the request MUST fail, and the subscription manager MUST generate a wse:UnableToRenew fault indicating that the renewal was not accepted.

Other components of the outline above are not further constrained by this specification.

Example 4-3 lists a hypothetical request to renew the subscription created in Example 4-2.

Lines (07-09) indicate this is a request to renew a subscription. Lines (19-21) contain the reference parameter that indicates the subscription to be renewed is the one created in Example 4-2. Line (25) in Example 4-3 indicates the request is to extend the subscription until 26 June 2004 at 9:07 PM Pacific.

Example 4-4 lists a hypothetical response to the request in Example 4-3.

Line (17) in Example 4-4 indicates the subscription has been extended only until 26 June 2004 at noon.

4.3 GetStatus

To get the status of a subscription, the subscriber sends a request of the following form to the subscription manager:

Components of the outline listed above are additionally constrained as for a request to renew a subscription (see 4.2 Renew). Other components of the outline above are not further constrained by this specification.

If the subscription is valid and has not expired, the subscription manager MUST reply with a response of the following form:

[Action]
  http://www.w3.org/2009/02/ws-evt/GetStatusResponse

[Body]
  <wse:GetStatusResponse ...>
    <wse:Expires>(xs:dateTime | xs:duration)</wse:Expires> ?
    xs:any*
  </wse:GetStatusResponse>

Components of the outline listed above are constrained as for a response to a renew request (see 4.2 Renew). Other components of the outline above are not further constrained by this specification.

Example 4-5 lists a hypothetical request to get the status of the subscription created in Example 4-2.

Lines (07-09) indicate this is a request to get the status of a subscription. Lines (16-21) indicate that the request is sent to the subscription manager for the subscription created in Example 4-2.

Example 4-6 lists a hypothetical response to the request in Example 4-5.

Line (17) in Example 4-6 indicates the subscription will expire on 26 June 2004 at noon.

4.4 Unsubscribe

Though subscriptions expire eventually, to minimize resources, the subscribing event sink SHOULD explicitly delete a subscription when it no longer wants notifications associated with the subscription.

To explicitly delete a subscription, a subscribing event sink sends a request of the following form to the subscription manager:

Components of the outline above are additionally constrained only as for a request to renew a subscription (see 4.2 Renew). For example, the faults listed there are also defined for a request to delete a subscription.

If the subscription manager accepts a request to delete a subscription, it MUST reply with a response of the following form:

[Action]
  http://www.w3.org/2009/02/ws-evt/UnsubscribeResponse

[Body]
  <wse:UnsubscribeResponse ...>
    xs:any*
  </wse:UnsubscribeResponse>

Components of the outline listed above are not further constrained by this specification.

Example 4-7 lists a hypothetical request to delete the subscription created in Example 4-2.

Lines (07-09) in Example 4-7 indicate the message is a request to delete a subscription. Lines (16-21) indicate that the request is addressed to the manager for the subscription created in Example 4-2.

Example 4-8 lists a hypothetical response to the request in Example 4-7.

4.5 Subscription End

If the event source terminates a subscription unexpectedly, the event source SHOULD send a Subscription End SOAP message to the endpoint reference indicated when the subscription was created (see 4.1 Subscribe). This endpoint reference MUST refer to an endpoint that supports the SubscriptionEndPortType portType. The message MUST be of the following form:

[Action]
  http://www.w3.org/2009/02/ws-evt/SubscriptionEnd

[Body]
  <wse:SubscriptionEnd ...>
    <wse:Status>
      ( http://www.w3.org/2009/02/ws-evt/DeliveryFailure | 
        http://www.w3.org/2009/02/ws-evt/SourceShuttingDown |
        http://www.w3.org/2009/02/ws-evt/SourceCancelling )
    </wse:Status>
    <wse:Reason xml:lang="language identifier" >xs:string</wse:Reason> ?
    xs:any*
  </wse:SubscriptionEnd>

The following describes additional, normative constraints on the outline listed above:

[Body]/wse:SubscriptionEnd/wse:Status = "http://www.w3.org/2009/02/ws-evt/DeliveryFailure"

This value MUST be used if the event source terminated the subscription because of problems delivering notifications.

[Body]/wse:SubscriptionEnd/wse:Status = "http://www.w3.org/2009/02/ws-evt/SourceShuttingDown"

This value MUST be used if the event source terminated the subscription because the source is being shut down in a controlled manner; that is, if the event source is being shut down but has the opportunity to send a SubscriptionEnd message before it exits.

[Body]/wse:SubscriptionEnd/wse:Status = "http://www.w3.org/2009/02/ws-evt/SourceCancelling"

This value MUST be used if the event source terminated the subscription for some other reason before it expired.

[Body]/wse:SubscriptionEnd/wse:Reason

This optional element contains text, in the language specified by the @xml:lang attribute, describing the reason for the unexpected subscription termination.

Other message information headers defined by WS-Addressing [WS-Addressing] MAY be included in the message, according to the usage and semantics defined in WS-Addressing.

Other components of the outline above are not further constrained by this specification.

Example 4-9 lists a hypothetical SubscriptionEnd message corresponding to an early termination of the subscription created in Example 4-1.

Line (08) is the action URI for Subscription End. Lines (10-13) indicate the message is sent to the EndTo of the subscribe request (Lines (23-30) in Example 4-1 .). Line (17) indicates the event source is shutting down, and Lines (18-20) indicate that the event source was going off line.

5 Notifications

This specification does not constrain notifications because any message MAY be a notification.

However, if a subscribing event sink wishes to have notifications specifically marked, it MAY specify literal SOAP header blocks in the Subscribe request, in the /s:Envelope/s:Body/wse:Subscribe/wse:NotifyTo/wsa:ReferenceParameters element; per WS-Addressing [WS-Addressing], the event source MUST include each such literal SOAP header block in every notification sent to the endpoint addressed by /s:Envelope/s:Body/wse:Subscribe/wse:NotifyTo.

Example 5-1 lists a hypothetical notification message sent as part of the subscription created by the subscribe request in Example 4-1.

Lines (13-15) indicate the message is sent to the endpoint indicated by the subscribe request (Lines (32-39) in Example 4-1). Line (17) matches the filter in the subscribe request (Lines (42-45) in Example 4-1).

6 Faults

All fault messages defined in this specification MUST be sent according to the rules described in WS-Addressing section 4. They are sent to the [fault endpoint], if present and valid. Otherwise they are sent to the [reply endpoint] if present. If neither is present faults may be sent to the [source endpoint].

Endpoints compliant with this specification MUST include required message information headers on all fault messages. Fault messages are correlated as replies using the [relationship] property as defined in WS-Addressing. The [action] property below designates fault messages: http://www.w3.org/2009/02/ws-evt/fault

The definitions of faults use the following properties:

[Code]The fault code.
[Subcode]The fault subcode.
[Reason]The English language reason element.
[Detail] The detail element. If absent, no detail element is defined for the fault.

The properties above bind to a SOAP 1.2 fault as follows:

The SOAP 1.1 fault is less expressive and map only [Subcode] and [Reason]. These the properties bind to a SOAP 1.1 fault as follows:

6.2 DeliveryModeRequestedUnavailable

This fault is sent when a Subscribe request specifies a delivery mode that is not supported by the event source. Optionally, this fault may contain a list of supported delivery mode URIs in the Detail property.

[Code]s12:Sender
[Subcode]wse:DeliveryModeRequestedUnavailable
[Reason]The requested delivery mode is not supported.
[Detail] <wse:SupportedDeliveryMode> +
Optional; one per delivery mode supported by the receiver

6.3 InvalidExpirationTime

This fault is sent when a Subscribe request specifies an expiration time that is in the past or an expiration duration of zero.

[Code]s12:Sender
[Subcode]wse:InvalidExpirationTime
[Reason]The expiration time requested is invalid.
[Detail]none

6.5 FilteringNotSupported

This fault is sent when a Subscribe request contains a filter and the event source does not support filtering.

[Code]s12:Sender
[Subcode]wse:FilteringNotSupported
[Reason]Filtering is not supported.
[Detail]none

6.6 FilteringRequestedUnavailable

This fault is sent when a Subscribe request specifies a filter dialect that the event source does not support. Optionally, this fault may contain a list of supported filter dialect URIs in the Detail property.

[Code]s12:Sender
[Subcode]wse:FilteringRequestedUnavailable
[Reason]The requested filter dialect is not supported.
[Detail] <wse:SupportedDialect> +
Optional; one per filter dialect supported by the receiver

6.7 EventSourceUnableToProcess

This fault is sent when the event source is not capable of fulfilling a Subscribe request for local reasons unrelated to the specific request.

[Code]s12:Receiver
[Subcode]wse:EventSourceUnableToProcess
[Reason]Text explaining the failure; e.g., "The event source has too many subscribers".
[Detail] <wse:RetryAfter> ? (Optional)

6.8 UnableToRenew

This fault is sent when the event source is not capable of fulfilling a Renew request for local reasons unrelated to the specific request.

[Code]s12:Receiver
[Subcode]wse:UnableToRenew
[Reason]Text explaining the failure; e.g., "The event source has too many subscribers".
[Detail] <wse:RetryAfter> ? (Optional)

6.10 DeliveryFormatRequestUnavailable

This fault is sent when a Subscribe request specifies a delivery mode that is not supported by the event source. Optionally, this fault may contain a list of supported delivery mode URIs in the Detail property.

[Code]s12:Sender
[Subcode]wse:DeliveryFormatRequestedUnavailable
[Reason]The requested delivery format is not supported.
[Detail] <wse:SupportedDeliveryFormat> +
Optional, one per delivery format supported by the receiver.

6.11 EmptyFilter

This fault MAY be generated when an Event Source detects a wse:Subscribe request containing a filter that, for whatever reason, will never evaluate to true.

[Code]s12:Sender
[Subcode]wse:EmptyFilter
[Reason]The wse:Filter would result in zero Notifications.
[Detail] The wse:Filter value.

6.12 UnusableEPR

This fault MAY be generated when an Event Source detects that the wse:NotifyTo or wse:EndTo EPR is unusable.

[Code]s12:Sender
[Subcode]wse:UnusableEPR
[Reason]An EPR in the Subscribe request message is unusable.
[Detail] The specific EPR that generated the error and why.

7 Security Considerations

7.1 Message Security

It is strongly RECOMMENDED that the communication between services be secured using the mechanisms described in WS-Security [WS-Security]. In order to properly secure messages, the body and all relevant headers need to be included in the signature. Specifically, any headers identified in the <wse:NotifyTo> element and standard messaging headers, such as those from WS-Addressing [WS-Addressing], need to be signed with the body in order to "bind" the two together. For messages with empty bodies, the <s12:Body> element should be signed so content cannot be added in transit.

Different security mechanisms may be desired depending on the frequency of messages. For example, for infrequent messages, public key technologies may be adequate for integrity and confidentiality. However, for high-frequency events, it may be more performant to establish a security context for the events using the mechanisms described in WS-Trust [WS-Trust] and WS-SecureConversation [WS-SecureConversation].

It should be noted that if a shared secret is used it is RECOMMENDED that derived keys be used to strengthen the secret as described in WS-SecureConversation.

The following list summarizes common classes of attacks that apply to this protocol and identifies the mechanism to prevent/mitigate the attacks:

  • Message alteration - Alteration is prevented by including signatures of the message information using WS-Security.

  • Message disclosure - Confidentiality is preserved by encrypting sensitive data using WS-Security.

  • Key integrity - Key integrity is maintained by using the strongest algorithms possible (by comparing secured policies - see WS-Policy [WS-Policy] and WS-SecurityPolicy [WS-SecurityPolicy]).

  • Authentication - Authentication is established using the mechanisms described in WS-Security and WS-Trust. Each message is authenticated using the mechanisms described in WS-Security.

  • Accountability - Accountability is a function of the type of and string of the key and algorithms being used. In many cases, a strong symmetric key provides sufficient accountability. However, in some environments, strong PKI signatures are required.

  • Availability - All reliable messaging services are subject to a variety of availability attacks. Replay detection is a common attack and it is RECOMMENDED that this be addressed by the mechanisms described in WS-Security. Other attacks, such as network-level denial of service attacks are harder to avoid and are outside the scope of this specification. That said, care should be taken to ensure that minimal state is saved prior to any authenticating sequences.

  • Replay - Messages may be replayed for a variety of reasons. To detect and eliminate this attack, mechanisms should be used to identify replayed messages such as the timestamp/nonce outlined in WS-Security. Alternatively, and optionally, other technologies, such as sequencing, can also be used to prevent replay of application messages.

8 Implementation Considerations

Implementations SHOULD generate expirations in subscribe and renew request and response messages that are significantly larger than expected network latency.

Event sinks should be prepared to receive notifications after sending a subscribe request but before receiving a subscribe response message. Event sinks should also be prepared to receive notifications after receiving an unsubscribe response message.

9 Acknowledgements

This specification has been developed as a result of joint work with many individuals and teams, including: Ashok Malhotra (Oracle Corp.), Asir Vedamuthu (Microsoft Corp.), Bob Freund (Hitachi, Ltd.), Doug Davis (IBM), Fred Maciel (Hitachi, Ltd.), Geoff Bullen (Microsoft Corp.), Gilbert Pilz (Oracle Corp.), Greg Carpenter (Microsoft Corp.), Jeff Mischkinsky (Oracle Corp.), Katy Warr (IBM), Li Li (Avaya Communications), Mark Little (Red Hat), Prasad Yendluri (Software AG), Sreedhara Narayanaswamy (CA), Sumeet Vij (Software AG), Vikas Varma (Software AG), Wu Chou (Avaya Communications), Yves Lafon (W3C)

10 References

RFC2119
Key words for use in RFCs to Indicate Requirement Levels , S. Bradner, March 1997. (See http://www.ietf.org/rfc/rfc2119.txt.)
SOAP 1.1
Simple Object Access Protocol (SOAP) 1.1 , D. Box, et al, May 2000. (See http://www.w3.org/TR/2000/NOTE-SOAP-20000508/.)
SOAP 1.2
SOAP Version 1.2 Part 1: Messaging Framework , M. Gudgin, et al, June 2003. (See http://www.w3.org/TR/2003/REC-soap12-part1-20030624/.)
WS-Addressing
W3C Recommendation, "Web Services Addressing 1.0 (WS-Addressing)" , May 2006. (See http://www.w3.org/2005/08/addressing/.)
WS-MetadataExchange
Web Services Metadata Exchange (WS-MetadataExchange) , K. Ballinger, et al, September 2004. (See http://www.w3.org/2009/02/ws-mex.)
WS-Policy
W3C Recommendation, "Web Services Policy 1.5 - Framework" , September 2007. (See http://www.w3.org/TR/ws-policy/.)
WS-ReliableMessaging
Web Services Reliable Messaging Protocol (WS-ReliableMessaging) , R. Bilorusets, et al, February 2005. (See http://schemas.xmlsoap.org/ws/2005/02/rm.)
WS-SecureConversation
Web Services Secure Conversation Language (WS-SecureConversation) , S. Anderson, et al, February 2005. (See http://schemas.xmlsoap.org/ws/2005/02/sc.)
WS-Security
Web Services Security: SOAP Message Security 1.0 , A. Nadalin, et al, March 2004. (See http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-soap-message-security-1.0.pdf.)
WS-SecurityPolicy
Web Services Security Policy Language (WS-SecurityPolicy), Version 1.1 , G. Della-Libera, et al, July 2005. (See http://schemas.xmlsoap.org/ws/2005/07/securitypolicy.)
WS-Trust
Web Services Trust Language (WS-Trust) , S. Anderson, et al, February 2005. (See http://schemas.xmlsoap.org/ws/2005/02/trust.)
WSDL 1.1
Web Services Description Language (WSDL) 1.1 , E. Christensen, et al, March 2001. (See http://www.w3.org/TR/2001/NOTE-wsdl-20010315.)
XML Infoset
XML Information Set , J. Cowan, et al, February 2004. (See http://www.w3.org/TR/2004/REC-xml-infoset-20040204/.)
XML Schema, Part 1
XML Schema Part 1: Structures , H. Thompson, et al, October 2004. (See http://www.w3.org/TR/2004/REC-xmlschema-1-20041028/.)
XML Schema, Part 2
XML Schema Part 2: Datatypes , P. Biron, et al, October 2004. (See http://www.w3.org/TR/2004/REC-xmlschema-2-20041028/.)
XPath 1.0
XML Path Language (XPath) Version 1.0 , J. Clark, et al, November 1999. (See http://www.w3.org/TR/1999/REC-xpath-19991116.)

A WSDL Interfaces for Eventing

The Event Source is modeled by two sets of WSDL files (event source WSDL files and notification WSDL files), both having only inbound operations. The set of event source WSDL files specifies the services supported by the Event Source; whereas the set of notification WSDL files specifies the events that the Event Source can generate, as well as the requirements, such as bindings, etc., of the Event Source.

Operations in the notification WSDL files are specified from the perspective of the Event Sink, i.e. inbound operations, to make the Eventing WSDL interface WS-I BP 1.1 compliant. To align with this model, outbound operations in the event source WSDL MUST be reversed into inbound operations and moved to a separate notification WSDL.

Event sink MUST implement WSDLs, e.g. unwrapped or wrapped, that are compatible to the notification WSDLs to receive the events.

The event source WSDL and notification WSDL MAY use WS-Policy and WS-Policy Attachment to indicate the event source's requirements for the notification WSDL. If the event source WSDL and notification WSDL do not use WS-Policy, some out of band mechanism can be used to link these inbound operations in the notification WSDL with the event source. If WS-Policy and Attachment are used, the following policy assertions MUST be used.

A.1 Outbound Policy Assertion

This policy assertion has Endpoint Subject in the event source WSDL. It is attached to wsdl:definition and referred from a policy subject using <wsp:PolicyReference URI="URI">. Each port type can have at most one such assertion, whereas each port can have more than one such assertion if multiple bindings are associated with the port.

<wsp:Policy wsu:Id="xs:ID"?>
<out:Outbound>
  out:Interface | out:Binding
</out:Outbound>
</wsp:Policy>

This assertion indicates that the port types and bindings identified by its parameters are required for the event source, the subscriber, and the event sink to register and receive event messages. For the event source, this assertion requires it to generate events identified by the policy parameter out:Interface element and deliver the events using the binding identified by the policy parameter out:Binding element. For the subscriber, this assertion requires it to subscribe to the port with this policy attachment. For the event sink, this assertion requires it to implement the subscribed operations and their bindings identified by the policy parameters in order to receive the event messages.

The policy parameter elements of this assertion are defined in the following subsections.

A.1.1 Interface policy parameter element

<out:Interface name="InterfaceName (xs:nmtoken)" >
  Notification_WSDL_URI (xs:anyURI)
</out:Interface>

This policy parameter element is used when attaching the assertion to a port type. It indicates that the port type of the policy subject is associated with the operations in the port type InterfaceName in the WSDL located at Notification_WSDL_URI. Notification_WSDL_URI can be omitted if the event source WSDL is empty and the policy assertion is attached to the notification WSDL. @name="InterfaceName" can be omitted if the policy assertion is attached to the notification port type directly.

A.1.2 Binding policy parameter element

<out:Binding name="BindingName (xs:qname)">
  Notification_WSDL_URI (xs:anyURI)
</out:Binding>

This policy parameter element is used when attaching the policy to a port. It indicates that the port of the policy subject is associated with the binding BindingName in the WSDL located at Notification_WSDL_URI.

A.1.3 Assertion Combination

When two <out:Outbound> assertions, one with parameter <out:Interface> element and one with parameter <out:Binding> element, are attached to the same Endpoint Subject, the BindingName of <out:Binding> parameter element MUST be a binding to a port type identified by InterfaceName in the <out:Interface> parameter element.

A.1.4 WSDL Examples

For example, here is a concrete WSDL 1.1 file for a hypothetical event source service that exposes several types of events defined in a separate notification WSDL specified by the WS-Policy attachments .

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://www.example.com/source" xmlns:evt="http://www.w3.org/2009/02/ws-evt" xmlns:wsp="http://www.w3.org/ns/ws-policy" xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd" xmlns:out="http://www.w3.org/ns/outbound" targetNamespace="http://www.example.com/source">
						
<!-- policy assertions for bindings -->
<wsp:Policy wsu:Id="SubscriptionEndNotification">
 <out:Outbound>
 <out:Binding name="SubscriptionEndBindingSOAPHTTP">
  concrete_sink.wsdl
 </out:Binding>
 </out:Outbound>
</wsp:Policy>
<wsp:Policy wsu:Id="StockNotification">
 <out:Outbound>
 <out:Binding name="StockBindingSOAPHTTP">
  concrete_notifications.wsdl
 </out:Binding>
 </out:Outbound>
</wsp:Policy>
<wsp:Policy wsu:Id="WeatherNotification">
 <out:Outbound>
 <out:Binding name="WeatherBindingSOAPHTTP">
  concrete_notifications.wsdl
 </out:Binding>
 </out:Outbound>
</wsp:Policy> 
<wsdl:import namespace="http://www.example.com/source" location="abstract_source.wsdl"/>
 
<wsdl:binding name="ReportStormBindingSOAPHTTP" type="tns:ReportStormPortType">
  <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
  <wsdl:operation name="ReportStorm">
   <soap:operation soapAction="urn:#ReportStorm"/>
   <wsdl:input>
    <soap:body use="literal"/>
   </wsdl:input>
   <wsdl:output>
    <soap:body use="literal"/>
   </wsdl:output>
  </wsdl:operation>
 </wsdl:binding>

<wsdl:binding name="PurchaseStockBindingSOAPHTTP" type="tns:StockPurchasePortType">
  <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
  <wsdl:operation name="PurchaseStock">
   <soap:operation soapAction="urn:#PurchaseStock"/>
   <wsdl:input>
    <soap:body use="literal"/>
   </wsdl:input>
   <wsdl:output>
    <soap:body use="literal"/>
   </wsdl:output>
  </wsdl:operation>
 </wsdl:binding>
 
<wsdl:binding name="EventSourceSOAPHTTP" type="evt:EventSource">
  <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
  <wsdl:operation name="SubscribeOp">
   <soap:operation soapAction="urn:#SubscdribeOp"/>
   <wsdl:input>
    <soap:body use="literal"/>
   </wsdl:input>
   <wsdl:output>
    <soap:body use="literal"/>
   </wsdl:output>
  </wsdl:operation>
 </wsdl:binding>
 
<wsdl:service name="eventsourceservice">
  <wsdl:port name="StormPort" binding="tns:ReportStormBindingSOAPHTTP">
   <soap:address location="http://www.example.com/source"/>
  </wsdl:port>
  <wsdl:port name="PurchasePort" binding="tns:PurchaseStockBindingSOAPHTTP">
   <soap:address location="http://www.example.com/source"/>
  </wsdl:port>
  <wsdl:port name="SubscribePortSubscriptionEnd" binding="tns:EventSourceSOAPHTTP">
   <!-- This subcribe port is used to support subscriptions to the SubscriptionEnd. -->
   <wsp:PolicyReference URI="#SubscriptionEndNotification" wsdl:required="false"/>
   <soap:address location="http://www.example.com/source/monitor"/>
  </wsdl:port>
  <wsdl:port name="SubscribePortAll" binding="tns:EventSourceSOAPHTTP">
   <soap:address location="http://www.example.com/source/all"/>
   <!--
   This subcribe port is used to support subscriptions to all outbound bindings that are compatible to a common event sink, e.g. SOAP over HTTP.
   -->
   <wsp:PolicyReference URI="#WeatherNotification" wsdl:required="false"/>
   <wsp:PolicyReference URI="#StockNotification" wsdl:required="false"/>
  </wsdl:port>
  <wsdl:port name="SubscribePortWeather" binding="tns:EventSourceSOAPHTTP">
   <soap:address location="http://www.example.com/source/weather"/>

   <!-- This subscribe port is associated with a specific outbound binding for a specific event sink. -->
   <wsp:PolicyReference URI="#WeatherNotification" wsdl:required="false"/>
  </wsdl:port>
  <wsdl:port name="SubscribePortStock" binding="tns:EventSourceSOAPHTTP">
   <soap:address location="http://www.example.com/source/stock"/>
  <!-- This subscribe port is associated with a specific outbound binding for a specific event sink. -->
   <wsp:PolicyReference URI="#StockNotification" wsdl:required="false"/>
  </wsdl:port>
 </wsdl:service>
</wsdl:definitions>
					

The concrete notification WSDL 1.1 refered by the above WS-Policy attachments are illustrated below.

<?xml version="1.0" encoding="UTF-8"?>
<wsdl:definitions xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:http="http://schemas.xmlsoap.org/wsdl/http/" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/" xmlns:mime="http://schemas.xmlsoap.org/wsdl/mime/" xmlns:tns="http://www.example.com/notifications" targetNamespace="http://www.example.com/notifications">
 <wsdl:types>
  <xs:schema targetNamespace="http://www.example.com/notifications" elementFormDefault="qualified"/>
 </wsdl:types>
 
<wsdl:import namespace="http://www.example.com/notifications" location="abstract_notifications.wsdl" />
 
<wsdl:binding name="WeatherBindingSOAPHTTP" type="tns:WeatherReportPortType">
  <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
  <wsdl:operation name="WeatherOperation">
   <soap:operation soapAction="urn:#WeatherOperation"/>
   <wsdl:input>
    <soap:body use="literal"/>
   </wsdl:input>
  </wsdl:operation>
</wsdl:binding>
 
<wsdl:binding name="StockBindingSOAPHTTP" type="tns:StockReportPortType">
  <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
  <wsdl:operation name="StockOperation">
   <soap:operation soapAction="urn:#StockOperation"/>
   <wsdl:input>
    <soap:body use="literal"/>
   </wsdl:input>
  </wsdl:operation>
</wsdl:binding>
 
<!-- there is no service or port definition -->
</wsdl:definitions>
							

B XML Schema

A normative copy of the XML Schema [XML Schema, Part 1], [XML Schema, Part 2] description for this specification may be retrieved from the following address:

A non-normative copy of the XML schema is listed below for convenience.

<xs:schema 
  targetNamespace="http://www.w3.org/2009/02/ws-evt" 
  xmlns:tns="http://www.w3.org/2009/02/ws-evt"
  xmlns:wsa="http://www.w3.org/2005/08/addressing"
  xmlns:xs="http://www.w3.org/2001/XMLSchema" 
  elementFormDefault="qualified" 
  blockDefault="#all">
  
  <xs:import 
    namespace="http://www.w3.org/XML/1998/namespace" 
    schemaLocation="http://www.w3.org/2001/xml.xsd" />
  <xs:import
    namespace="http://www.w3.org/2005/08/addressing"
    schemaLocation="http://www.w3.org/2005/08/addressing/ws-addr.xsd" />
 
  <!-- Types and global elements -->
  <xs:complexType name="DeliveryType" mixed="true">
    <xs:sequence>
      <xs:element ref="tns:NotifyTo" minOccurs="0" maxOccurs="1" />
      <xs:any namespace="##other" processContents="lax" 
              minOccurs="0" maxOccurs="unbounded" />
    </xs:sequence>
    <xs:attribute name="Mode" type="xs:anyURI" use="optional" 
      default="http://http://www.w3.org/2009/02/ws-evt/DeliveryModes/Push" />
    <xs:anyAttribute namespace="##other" processContents="lax" />
  </xs:complexType>
 
  <xs:complexType name="FormatType" mixed="true">
    <xs:sequence>
      <xs:any namespace="##any" processContents="lax" 
              minOccurs="0" maxOccurs="unbounded" />
    </xs:sequence>
    <xs:attribute name="Name" type="xs:anyURI" use="optional" 
      default="http://http://www.w3.org/2009/02/ws-evt/DeliveryFormats/Unwrap" />
    <xs:anyAttribute namespace="##other" processContents="lax" />
  </xs:complexType>
 
  <xs:simpleType name="NonNegativeDurationType">
    <xs:restriction base="xs:duration">
      <xs:minInclusive value="P0Y0M0DT0H0M0S" />
    </xs:restriction>
  </xs:simpleType>
 
  <xs:simpleType name="ExpirationType">
      <xs:union memberTypes="xs:dateTime 
                tns:NonNegativeDurationType" />
  </xs:simpleType>
 
  <xs:complexType name="FilterType" mixed="true">
    <xs:sequence>
      <xs:any namespace="##other" processContents="lax" 
              minOccurs="0" maxOccurs="unbounded" />
    </xs:sequence>
    <xs:attribute name="Dialect" type="xs:anyURI" use="optional" 
      default="http://www.w3.org/TR/1999/REC-xpath-19991116" />
    <xs:anyAttribute namespace="##other" processContents="lax" />
  </xs:complexType>
 
  <xs:complexType name="LanguageSpecificStringType">
    <xs:simpleContent>
      <xs:extension base="xs:string">
        <xs:attribute ref="xml:lang" />
        <xs:anyAttribute namespace="##other" processContents="lax" />
      </xs:extension>
    </xs:simpleContent>
  </xs:complexType>
 
  <xs:element name="NotifyTo" type="wsa:EndpointReferenceType" />
 
  <!-- Subscribe request -->
  <xs:element name="Subscribe">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="EndTo" type="wsa:EndpointReferenceType" 
                    minOccurs="0" />
        <xs:element name="Delivery" type="tns:DeliveryType" />
        <xs:element name="Format" type="tns:FormatType" 
                    minOccurs="0" />
        <xs:element name="Expires" type="tns:ExpirationType" 
                    minOccurs="0" />
        <xs:element name="Filter" type="tns:FilterType" 
                    minOccurs="0" />
        <xs:any namespace="##other" processContents="lax" 
                minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>
      <xs:anyAttribute namespace="##other" processContents="lax" />
    </xs:complexType>
  </xs:element>
 
  <xs:element name="Identifier" type="xs:anyURI" />
 
  <!-- Subscribe response -->
  <xs:element name="SubscribeResponse">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="SubscriptionManager" 
                    type="wsa:EndpointReferenceType" />
        <xs:element name="Expires" type="tns:ExpirationType" />
        <xs:any namespace="##other" processContents="lax" 
                minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>
      <xs:anyAttribute namespace="##other" processContents="lax" />
    </xs:complexType>
  </xs:element>
 
  <!-- Used in a fault if there's an unsupported dialect -->
  <xs:element name="SupportedDialect" type="xs:anyURI" />
 
  <!-- Used in a fault if there's an unsupported delivery mode -->
  <xs:element name="SupportedDeliveryMode" type="xs:anyURI" />
 
  <!-- Used in a fault if there's an unsupported format name -->
  <xs:element name="SupportedDeliveryFormat" type="xs:anyURI" />
 
  <!-- Renew request -->
  <xs:element name="Renew">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="Expires" type="tns:ExpirationType" 
                    minOccurs="0" />
        <xs:any namespace="##other" processContents="lax" 
                minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>
      <xs:anyAttribute namespace="##other" processContents="lax" />
    </xs:complexType>
  </xs:element>
 
  <!-- Renew response -->
  <xs:element name="RenewResponse">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="Expires" type="tns:ExpirationType" 
                    minOccurs="0" />
        <xs:any namespace="##other" processContents="lax" 
                minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>
      <xs:anyAttribute namespace="##other" processContents="lax" />
    </xs:complexType>
  </xs:element>
 
  <!-- GetStatus request -->
  <xs:element name="GetStatus">
    <xs:complexType>
      <xs:sequence>
        <xs:any namespace="##other" processContents="lax" 
                minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>
      <xs:anyAttribute namespace="##other" processContents="lax" />
    </xs:complexType>
  </xs:element>
 
  <!-- GetStatus response -->
  <xs:element name="GetStatusResponse">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="Expires" type="tns:ExpirationType" 
                    minOccurs="0" />
        <xs:any namespace="##other" processContents="lax" 
                minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>
      <xs:anyAttribute namespace="##other" processContents="lax" />
    </xs:complexType>
  </xs:element>
 
  <!-- Unsubscribe request -->
  <xs:element name="Unsubscribe">
    <xs:complexType>
      <xs:sequence>
        <xs:any namespace="##other" processContents="lax" 
                minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>
      <xs:anyAttribute namespace="##other" processContents="lax" />
    </xs:complexType>
  </xs:element>
 
  <!-- Unsubscribe response -->
  <xs:element name="UnsubscribeResponse">
    <xs:complexType>
      <xs:sequence>
        <xs:any namespace="##other" processContents="lax" 
                minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>
      <xs:anyAttribute namespace="##other" processContents="lax" />
    </xs:complexType>
  </xs:element>
 
  <!-- SubscriptionEnd message -->
  <xs:element name="SubscriptionEnd">
    <xs:complexType>
      <xs:sequence>
        <xs:element name="Status"
                    type="tns:OpenSubscriptionEndCodeType" />
        <xs:element name="Reason" 
                    type="tns:LanguageSpecificStringType" 
                    minOccurs="0" maxOccurs="unbounded" />
        <xs:any namespace="##other" processContents="lax" 
                minOccurs="0" maxOccurs="unbounded" />
      </xs:sequence>
      <xs:anyAttribute namespace="##other" processContents="lax" />
    </xs:complexType>
  </xs:element>
 
  <xs:simpleType name="SubscriptionEndCodeType">
    <xs:restriction base="xs:anyURI">
      <xs:enumeration value=
  "http://www.w3.org/2009/02/ws-evt/DeliveryFailure" />
      <xs:enumeration value=
  "http://www.w3.org/2009/02/ws-evt/SourceShuttingDown" />
      <xs:enumeration value=
  "http://www.w3.org/2009/02/ws-evt/SourceCancelling" />
    </xs:restriction>
  </xs:simpleType>
 
  <xs:simpleType name="OpenSubscriptionEndCodeType">
    <xs:union memberTypes="tns:SubscriptionEndCodeType xs:anyURI" />
  </xs:simpleType>
    
  <!-- RetryAfter Fault Detail Element -->
  <xs:element name="RetryAfter"  type="tns:RetryAfterType"/>
  <xs:complexType name="RetryAfterType">
    <xs:simpleContent>
      <xs:extension base="xs:nonNegativeInteger">
        <xs:anyAttribute namespace="##other" processContents="lax" />
      </xs:extension>
    </xs:simpleContent>
  </xs:complexType>
     
  <xs:attribute name="EventSource" type="xs:boolean" />

  <!-- Wrapped Events -->
  <xs:complexType name="EventType" mixed="true">
    <xs:sequence>
      <xs:any namespace="##any" processContents="lax" minOccurs="0"
              maxOccurs="unbounded"/>
    </xs:sequence>
    <xs:attribute name="actionURI" type="xs:anyURI" use="optional" />
    <xs:anyAttribute namespace="##other" processContents="lax" />
  </xs:complexType>
  <xs:element name="Notify" type="tns:EventType" />

</xs:schema> 

C WSDL

A normative copy of the WSDL [WSDL 1.1] description can be retrieved from the following address:

A non-normative copy of the WSDL description is listed below for convenience.

<wsdl:definitions
  targetNamespace="http://www.w3.org/2009/02/ws-evt"
  xmlns:wsa="http://www.w3.org/2005/08/addressing"
  xmlns:wsam="http://www.w3.org/2007/05/addressing/metadata"
  xmlns:wse="http://www.w3.org/2009/02/ws-evt" 
  xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" 
  xmlns:xs="http://www.w3.org/2001/XMLSchema" >

  <wsdl:types>
    <xs:schema>
       <xs:import
         namespace="http://www.w3.org/2009/02/ws-evt"
         schemaLocation=
  "http://www.w3.org/2009/02/ws-evt/eventing.xsd" />
    </xs:schema>
  </wsdl:types>
  
  <wsdl:message name="SubscribeMsg" >
    <wsdl:part name="body" element="wse:Subscribe" />
  </wsdl:message>
  <wsdl:message name="SubscribeResponseMsg" >
    <wsdl:part name="body" element="wse:SubscribeResponse" />
  </wsdl:message>
  
  <wsdl:message name="RenewMsg" >
    <wsdl:part name="body" element="wse:Renew" />
  </wsdl:message>
  <wsdl:message name="RenewResponseMsg" >
    <wsdl:part name="body" element="wse:RenewResponse" />
  </wsdl:message>
  
  <wsdl:message name="GetStatusMsg" >
    <wsdl:part name="body" element="wse:GetStatus" />
  </wsdl:message>
  <wsdl:message name="GetStatusResponseMsg" >
    <wsdl:part name="body" element="wse:GetStatusResponse" />
  </wsdl:message>
  
  <wsdl:message name="UnsubscribeMsg" >
    <wsdl:part name="body" element="wse:Unsubscribe" />
  </wsdl:message>
  <wsdl:message name="UnsubscribeResponseMsg" >
    <wsdl:part name="body" element="wse:UnsubscribeResponse" />
  </wsdl:message>
 
  <wsdl:message name="SubscriptionEnd" >
    <wsdl:part name="body" element="wse:SubscriptionEnd" />
  </wsdl:message>

  <message name="notifyEvent">
    <part name="parameter" element="tns:Notify"/>
  </message>
  
  <wsdl:portType name="EventSource" >
    <wsdl:operation name="SubscribeOp" >
      <wsdl:input 
        message="wse:SubscribeMsg"
        wsam:Action="http://www.w3.org/2009/02/ws-evt/Subscribe"/>
      <wsdl:output 
        message="wse:SubscribeResponseMsg" 
        wsam:Action="http://www.w3.org/2009/02/ws-evt/SubscribeResponse"/>
    </wsdl:operation>
  </wsdl:portType>
  
  <wsdl:portType name="SubscriptionEndPortType" >
    <wsdl:operation name="SubscriptionEnd" >
      <wsdl:input 
        message="wse:SubscriptionEnd" 
        wsam:Action="http://www.w3.org/2009/02/ws-evt/SubscriptionEnd"/>
    </wsdl:operation>
  </wsdl:portType>
  
  <wsdl:portType name="SubscriptionManager" >
    <wsdl:operation name="RenewOp" >
      <wsdl:input 
        message="wse:RenewMsg" 
        wsam:Action="http://www.w3.org/2009/02/ws-evt/Renew"/>
      <wsdl:output 
        message="wse:RenewResponseMsg" 
        wsam:Action="http://www.w3.org/2009/02/ws-evt/RenewResponse"/>
    </wsdl:operation>
    <wsdl:operation name="GetStatusOp" >
      <wsdl:input 
        message="wse:GetStatusMsg"
        wsam:Action="http://www.w3.org/2009/02/ws-evt/GetStatus"/>
      <wsdl:output 
        message="wse:GetStatusResponseMsg" 
        wsam:Action="http://www.w3.org/2009/02/ws-evt/GetStatusResponse"/>
    </wsdl:operation>
    <wsdl:operation name="UnsubscribeOp" >
      <wsdl:input 
        message="wse:UnsubscribeMsg" 
        wsam:Action="http://www.w3.org/2009/02/ws-evt/Unsubscribe"/>
      <wsdl:output 
        message="wse:UnsubscribeResponseMsg" 
        wsam:Action="http://www.w3.org/2009/02/ws-evt/UnsubscribeResponse"/>
    </wsdl:operation>
  </wsdl:portType>

  <portType name="WrappedSinkPortType">
    <operation name="NotifyEvent">
      <input message="tns:notifyEvent" name="NotifyEvent" 
        wsam:Action="http://www.w3.org/2009/02/ws-evt/WrappedSinkPortType/NotifyEvent"/>
    </operation>
  </portType>
</wsdl:definitions>

D WSDL for Standard Wrapped Delivery

If an Event Subscriber specifies the wrapped event delivery format http://www.w3.org/2009/02/ws-evt/DeliveryFormats/Wrap in the Subscribe request message, then the Event Sink MUST implement the following abstract WSDL and the Event Source MUST send the Notification messages wrapped in the element defined in the WSDL.

E Change Log

Data Author Description
2009/03/04 DD Added resolution of issue 6391
2009/03/04 DD Added resolution of issue 6519
2009/03/04 DD Added resolution of issue 6427
2009/03/04 DD Added resolution of issue 6459
2009/03/09 DD Added resolution of issue 6397
2009/03/09 DD Added resolution of issue 6426
2009/03/11 DD Added change log
2009/03/11 DD Added resolution of issue 6641
2009/03/11 DD Added resolution of issue 6498
2009/03/11 DD Added resolution of issue 6425
2009/03/16 KW Added resolution of issue 6587
2009/03/17 KW Added resolution of issue 6400
2009/03/17 DD Added resolution of issue 6428
2009/03/17 DD Added resolution of issue 6687
2009/03/23 DD Added resolution of issue 6666
2009/03/23 DD Added resolution of issue 6681
2009/03/24 DD Added resolution of issue 6595
2009/03/24 DD Added resolution of issue 6648
2009/04/07 DD Added resolution of issue 6727
2009/04/07 DD Added resolution of issue 6725
2009/04/07 DD Added resolution of issue 6715
2009/04/22 KW Added resolution of issue 6739
2009/04/28 DD Added resolution of issue 6787
2009/04/28 DD Added resolution of issue 6788
2009/05/13 KW Added resolution of issue 6472
2009/05/13 DD Added resolution of issue 6850
2009/05/13 DD Added resolution of issue 6696
2009/05/19 DD Added resolution of issue 6907
2009/05/19 DD Added resolution of issue 6429
2009/05/21 DD Added resolution of issue 6674
2009/05/27 DD Added resolution of issue 6906
2009/06/04 DD Added resolution of issue 6955
2009/06/04 DD Added resolution of issue 6916
2009/06/04 DD Added resolution of issue 6986