org.mule.modules

mule-module-pubsubhubbub


Namespacehttp://www.mulesoft.org/schema/mule/PuSH-subscriber
Schema Locationhttp://www.mulesoft.org/schema/mule/PuSH-subscriber/current/mule-PuSH-subscriber.xsd  (View Schema)
Schema Version3.3
Minimum Mule Version3.2

Module Overview

Allows Mule to act as a PubSubHubbub (aka PuSH) subscriber.
Pubsubhubbub is a simple, open, web-hook-based pubsub protocol & open source reference implementation.
This module implements the PubSubHubbub Core 0.3 -- Working Draft specification, except 7.5 Aggregated Content Distribution.

Summary

Configuration
<PuSH-subscriber:config>
Configure an instance of this module
Message Processors
<PuSH-subscriber:subscriber>
Handle all subscriber requests.

Configuration

To use the this module within a flow the namespace to the module must be included. The resulting flow will look similar to the following:

<mule xmlns="http://www.mulesoft.org/schema/mule/core"
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
      xmlns:PuSH-subscriber="http://www.mulesoft.org/schema/mule/PuSH-subscriber"
      xsi:schemaLocation="
               http://www.mulesoft.org/schema/mule/core
               http://www.mulesoft.org/schema/mule/core/current/mule.xsd
               http://www.mulesoft.org/schema/mule/PuSH-subscriber
               http://www.mulesoft.org/schema/mule/PuSH-subscriber/current/mule-PuSH-subscriber.xsd">

      <!-- here goes your flows and configuration elements -->

</mule>

This module is configured using the config element. This element must be placed outside of your flows and at the root of your Mule application. You can create as many configurations as you deem necessary as long as each carries its own name.

Each message processor, message source or transformer carries a config-ref attribute that allows the invoker to specify which configuration to use.

Attributes
TypeNameDefault ValueDescription
xs:string name Optional. Give a name to this configuration so it can be later referenced.
xs:string callbackUrl The URL that the hub should call back, which is the public URL of the HTTP inbound endpoint placed in front of the subscriber element.
xs:string hubUrl The URL of the PubSubHubbub to connect to.
xs:long leaseSeconds 604800 Optional. (Optional) Number of seconds for which the subscriber would like to have the subscription active.
xs:string secret Optional. (Optional) A subscriber-provided secret string that will be used to compute an HMAC digest for authorized content distribution.
xs:string topic The topic URL that the subscriber wishes to subscribe to.

Message Processors

<PuSH-subscriber:subscriber>

Handle all subscriber requests.

XML Sample
INCLUDE_ERROR

Attributes
NameDefault ValueDescription
config-ref Optional. Specify which configuration to use.
httpMethod The HTTP method name
contentType The content-type of the request
onBehalfOf Optional. (Optional) number of subscribers this subscriber is representing, should be either an integer or a Mule expression
payload The message payload
sourceCallback The callback to call when content is propagated
Child Elements
<PuSH-subscriber:response-headers>
The outbound/response headers
Return Payload
  • the response body
Exception Payloads
Payload ClassDescription
Exception
MuleException
DecoderException
Exception