|Although URI-based endpoints are still supported in Mule 2.0, transport-specific endpoints are generally recommended instead.|
|This topic relates to Mule ESB Version 2.x.|
To see the corresponding topic in Mule ESB Version 3.x, click [Mule Endpoint URIs].
Mule Endpoint URIs are any valid URI and describe how to connect to the underlying transport. Most connectors in Mule can be created from an endpoint URI except where not enough connection information can be expressed clearly in a URI, such as JMS connection properties. Endpoint URIs are set on Mule Endpoints, which manage other connection instance information such as filters and transactions.
Mule Endpoint URIs usually appear in one of the following forms, although other provider implementations can introduce their own schemes.
The scheme must always be set. The host and port are set for endpoints that use unwrapped socket based communications such as the TCP, UDP, HTTP, or multicast.
The user name and password are used to log in to the remote server specified by the host and port parameters. The POP3 and SMTP connectors use this format or URI.
Here we only define a protocol and an address. This tells Mule to get a connector that handles the specified scheme, or create one if needed, and to create a new endpoint using the specified address.
There are two types of parameters you can set on the URI:
- Known Mule parameters that control the way the endpoint is configured, such as transformers for the endpoint.
- Properties to be set on the connector or to be associated with the transport. This allows you to set properties on a connector used by this endpoint. Additionally, all properties will be associated with the transport, so you can mix connector and transport properties. For more information, see Configuring Endpoints.
|connector||The name of an existing connector to use for this endpoint URI|
|transformers||Defines a comma-separated list of transformers to configure on the endpoint|
|address||Explicitly sets the endpoint address to the specified value and ignores all other info in the URI.|
Any other parameters set on the URI will be set on the connector if a connector is created and also set on the endpoint itself as properties.
When using XML configuration, certain character entities defined in the W3C SGML specification need to be escaped to their SGML code. The most relevant are listed here. Don't forget to remove the space before the ';'.
For characters such as > < " % #, the notation will be resolved and cause the constructor for the URI to throw an exception. To use one of these characters, you can specify %HEXNUMBER
|Text code||Numerical code||What it looks like||Description, extras|
|%22||#34||"||quotation mark = APL quote, U+0022 ISONEW|
|& ;||#38||&||ampersand, U+0026 ISOnum|
|%3C||#60||<||less-than sign, U+003C ISOnum|
|%3E||#62||>||greater-than sign, U+003E ISOnum|
|%25||#37||%||percentage sign, U+0023 ISOnum|
|%23||#35||#||hash sign, U+0025 ISOnum|
Additionally, for connectors such as Axis, FTP, and the Email connectors, if your login credentials include @, you must escape it using %40. For example, instead of these URIs:
You must use these: