Petals ANT Tasks 2.6.0-SNAPSHOT

compared with
Key
This line was removed.
This word was removed. This word was added.
This line was added.

Changes (1)

View Page History
</petals-assert-flow-tree>
{code}

h1. Petals ESB Ant conditions

h2. Condition {{hasEndpointDeployed}}

The condition '{{hasEndpointDeployed}}' retrieve the endpoints matching criteria, and compare the number of these endpoints with an expected number. If they are equals, the condition is validated.

|| Attribute || Description || Default ||Required ? ||
| {{host}} | the hostname of a Petals container | {{localhost}} | No |
| {{port}} | JMX port of the Petals container | {{7700}} | No |
| {{username}} | JMX username of the Petals container | - | No |
| {{password}} | JMX password of the Petals container | - | No |
| {{interfaceName}} | interface name that the endpoints should match, or {{null}} if any interface is accepted | {{null}} | No |
| {{serviceName}} | service name that the endpoints should match, or {{null}} if any service is accepted | {{null}} | No |
| {{endpointName}} | endpoint name that the endpoints should match, or {{null}} if any endpoint name is accepted | {{null}} | No |
| {{expectedNumber}} | the number of endpoints matching criteria that should be found to validate the condition | 1 | No |

h3. Example

{code}
<waitfor maxwait="30"
maxwaitunit="second"
checkevery="5"
checkeveryunit="second"
timeoutproperty="endpointsPropagationFailed">
<and>
<hasEndpointDeployed host="${container.0.host}"
port="${container.0.jmx-port}"
username="${container.0.username}"
password="${container.0.password}"
interfaceName="{http://petals.ow2.org/}HelloWorldService"
serviceName="{http://petals.ow2.org/}HelloWorldService"
expectedNumber="4" />
<hasEndpointDeployed host="${container.1.0.host}"
port="${container.1.0.jmx-port}"
username="${container.1.0.username}"
password="${container.1.0.password}"
interfaceName="{http://petals.ow2.org/}HelloWorldService"
serviceName="{http://petals.ow2.org/}HelloWorldService"
expectedNumber="4" />
</and>
</waitfor>
{code}