WSO2 ESB XML definition syntax (2)

5.Proxy Service Configuration

<Proxy> element is used to define Synapse agency services.

Created by Axis2 engine on the basis of a specified and public transport agency services, according to the standard Axis2 convention (ie, based on the service name) public service EPR. Please note that currently do not allow Axis2 service settings on for some transmissions (such as http / s) custom URI. Agency services can all enabled Axis2 transmission (such as http, https, JMS, Mail and File, etc.) or through the optional "transports" on public property specified subset. By default, if this property is not specified, Synapse will attempt to open the proxy service on all enabled transmission.

In a clustered setup, you may need to deploy specific agency services on a subset of the available nodes. This can be 'pinnedServers' properties to achieve. This property uses the server list name. When the server starts, Synapse will check for any current name of the host name given to whether this attribute match, if a match is found, the only deployment agent service. Select the server host name from the system properties "SynapseServerName", otherwise the machine will use the host name or the default is "localhost". The user can start the server using the following command, specify a name more meaningful Synapse server instance.

./synapse.sh -serverName=<ServerName>

If Synapse start as a daemon or service, you should specify these settings in wrapper.conf file.

By default, when you create a proxy service, it is added to the same name and agency services Axis service group. Use 'serviceGroup' attribute may further configure this behavior. You can use "serviceGroup" property to specify a custom service group Axis agency services. In this way, multiple proxy services can be grouped together in Axis2 level, which greatly simplifies service management tasks.

Each service object definition may be received message is a direct sequence or endpoint names. Agent configuration needs of the target inSequence or endpoint, how to define the target outSequence should handle the response. Any WS-Policies are provided as the application service level policies, and may use 'parameter' element (e.g., a JMS destination, etc.) will pass any parameters to the service instance AxisService proxy service. If the proxy service should enable WS-Reliable Messaging or Security, you should use the appropriate modules and applications specified service level policies. To use the required modules may be used 'enableSec' and 'enableAddressing' elements

Dynamic entries can be specified as defined by the dynamic properties of the broker agent, is to use a key reference them. For example, a key may be used to specify the remote endpoint or inSequence, without having to define in its local configuration. With the remote to change the registry key, the agent attributes dynamically updated accordingly. (Note: The agent itself can not be specified as the service defining dynamic; that <proxy key = "string" / > Error)

You can use WSDL 'publishWSDL' element publishing proxy services. WSDL documents can be loaded from the registry by specifying the "key" attribute, you can load the WSDL document from any other location designated by the "uri" attribute. Alternatively, WSDL may be provided as a sub-element associated "publishWSDL" element. A workpiece (or other pattern WSDL documents) WSDL introduced from the registry can be resolved by specifying an appropriate "resources" element.

<publishWSDL key =“my.wsdl”>

<resource location =“http://www.standards.org/standard.wsdl” key =“standard.wsdl”/>

</publishWSDL>

In this example, using the key "my.wsdl" WSDL retrieved from the registry. It is another WSDL introduced from the position 'http://www.standards.org/standard.wsdl'. Synapse from the registry key "standard.wsdl" to retrieve the imported WSDL, instead of loading it from this location.

Here are some well-known parameters in the preparation of complex proxy service very useful. These may be used 'parameter' tag contained in the proxy configuration.

The following table lists some transmission may be transferred to a particular proxy service configuration parameters.

 

Guess you like

Origin www.cnblogs.com/leolzi/p/10967992.html
ESB
ESB