res-fetch-all
The res-fetch-all Ant task downloads all your RuleApp archives or Java™ XOM resources or libraries from Rule Execution Server.
The res-fetch-all task works through a Hypertext
Transfer Protocol (HTTP) or an HTTP Over SSL (HTTPS) and can download
two kinds of execution artifacts:
- All RuleApp archives
- The XOM, JAR, ZIP, or Java resources when a Java XOM is deployed to a Rule Execution Server instance
res-fetch-all element attributes
The following table describes the res-fetch-all element attributes and specifies whether they are mandatory or optional.
| Element Attribute | Description | Mandatory/optional |
|---|---|---|
| credentialsfile | A file that contains the userid and password, encrypted the first time the attribute is used. If you set this attribute, do not use the userid and password attributes. A credentials file is a text file that sets two properties: username and password. |
Optional |
| destfile | The destination where the RuleApp backup file or the resource is stored. | Mandatory |
| failonerror | If you set this attribute to false, a warning message is logged when an error occurs, but the build process is not stopped. | Optional The default value is true. |
| hostname | The host name of the server where the Rule Execution Server console is installed. | Mandatory |
| password | The password of the user that is allowed to log in to the Rule Execution Server console. If you set this attribute, do not use the credentialsfile attribute. | Optional |
| portnumber | The port number of the Rule Execution Server console. | Mandatory |
| secured | If you set this attribute to true, the task works through an HTTPS connection. | Optional The default value is false. |
| userid | The user name to log in the Rule Execution Server console. If you set this attribute, do not use the credentialsfile attribute. | Optional |
| webapp | The context root of the Rule Execution Server console | Optional. The default value is res. |
Example: Retrieval with no encryption
The
following code sample shows how to use the userid and password attributes:
<res-fetch-all hostname="localhost"
destfile="myruleapp.jar"
portnumber="9080"
userid="res"
password="mypassword"/>
Example: Encrypted credentials for resource retrieval
Here is an encrypted example, which uses the credentialsfile attribute:
<res-fetch-all hostname="localhost"
destfile="myruleapp.jar"
portnumber="9080"
credentialsfile="mypasswordfile"/>
The
credentials file is a text file that contains the following values:
username=res
password=mypassword
The file must comply with the Java format for property
files. For more information, see the Java documentation. After the first execution of the res-deploy Ant
task, the contents are encrypted. For example:
username={DES}oLHZROlruWw\=
password={DES}als58ekruWw\=
With encryption, the userid and password elements are never displayed in plain text in traces during RuleApp deployment.