build.xml
The following is a sample build.xml file.
<project name="BE_Stack-build" default="release" basedir="." xmlns:sf="antlib:com.datasynapse.fabric.ant">
<property file="build.properties" />
<property file="fabric-cli.properties" />
<sf:connection-props brokerurl="${DSPrimaryDirector}" username="${DSUserName}" password="${DSPassword}" clientssltrustfile="${DSSSLTrustFile}" />
<target name="release" depends="create-all-components, release-BE_Component-component, release-stack" />
<target name="clean" depends="clean-stack, clean-BE_Component-component" />
<target name="create-all-components">
<sf:component action="create" name="${BE_Component.component.name}" description="${BE_Component.component.description}" type="${BE_Component.component.type}" enablername="${BE_Component.enabler.name}" enablerversion="${BE_Component.enabler.version}" utility="${BE_Component.utility}" />
</target>
<target name="release-BE_Component-component">
<echo message="Building ${BE_Component.component.name}" />
<sf:option name="${BE_Component.component.name}" action="replace">
<sf:property name="Engine Blacklisting" value="${BE_Component.blacklisting}" />
<sf:property name="Failures Per Day Before Blacklist" value="${BE_Component.blacklist.failures}" />
<sf:property name="Archive Scale Up Timeout" value="${BE_Component.archive.scale.up.timeout}" />
<sf:property name="Archive Scale Down Timeout" value="${BE_Component.archive.scale.down.timeout}" />
<sf:property name="Maximum Deactivation Time" value="${BE_Component.deactivation.timeout}" />
<sf:property name="Maximum Activation Time" value="${BE_Component.activation.timeout}" />
<sf:property name="Maximum Capture Time" value="${BE_Component.maximum.capture.time}" />
<sf:property name="Maximum Instances Per Host" value="${BE_Component.max.instances.per.host}" />
<sf:property name="Statistics Collection Frequency" value="${BE_Component.stats.collection.frequency}" />
<sf:property name="Activation Delay" value="${BE_Component.activation.delay}" />
<sf:property name="Engine Reservation Expiration" value="${BE_Component.engine.reservation.expiration}" />
</sf:option>
<sf:default-settings name="${BE_Component.component.name}" action="update">
<sf:property name="Default Min Engines" value="${BE_Component.min}" />
<sf:property name="Default Max Engines" value="${BE_Component.max}" />
<sf:property name="Default Priority" value="${BE_Component.priority}" />
</sf:default-settings>
<sf:feature name="${BE_Component.component.name}" action="add" feature="HTTP Support" />
<sf:feature name="${BE_Component.component.name}" action="update" feature="HTTP Support">
<sf:property name="Relative Url" value="${BE_Component.relative.url}" />
<sf:property name="Routing Prefix" value="${BE_Component.routing.prefix}" />
<sf:property name="HTTPS Enabled" value="${BE_Component.https.enabled}" />
<sf:property name="HTTP Enabled" value="${BE_Component.http.enabled}" />
<sf:property name="Route Directly To Endpoints" value="${BE_Component.route.directly.to.endpoints}" />
</sf:feature>
<sf:feature name="${BE_Component.component.name}" action="add" feature="Archive Management Support" />
<sf:feature name="${BE_Component.component.name}" action="update" feature="Archive Management Support">
<sf:property name="Archive" value="${BE_Component.archive}" />
<sf:property name="Start Archives On Activation" value="${BE_Component.start.archives.on.activation}" />
</sf:feature>
<sf:feature name="${BE_Component.component.name}" action="add" feature="Application Logging Support" />
<sf:feature name="${BE_Component.component.name}" action="update" feature="Application Logging Support">
<sf:property name="Checkpoint Frequency In Seconds" value="${BE_Component.checkpoint.frequency.in.seconds}" />
<sf:property name="Archive Application Logs" value="${BE_Component.archive.application.logs}" />
<sf:property name="Log File Pattern" value="${BE_Component.log.file.pattern}" />
</sf:feature>
<sf:archive-file name="${BE_Component.component.name}" action="add" >
<path>
<pathelement path="${BE_Component.archive.0.path}" />
</path>
</sf:archive-file>
<sf:context-variable type="component" name="${BE_Component.component.name}" action="update">
<sf:contextvar name="NB_HAWK_RESTART_BEFORE_RESTART_ENGINE" type="string" value="${BE_Component.contextvar.nb.hawk.restart.before.restart.engine}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="HAWK_POLLPERIOD" type="string" value="${BE_Component.contextvar.hawk.pollperiod}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="NB_BE_RESTART_BEFORE_RESTART_ENGINE" type="string" value="${BE_Component.contextvar.nb.be.restart.before.restart.engine}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="BE_POLLPERIOD" type="string" value="${BE_Component.contextvar.be.pollperiod}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="HTTP_PORT_BASE" type="environment" value="${BE_Component.contextvar.http.port.base}" export="false" autoincrement="none" description="Consult the user documentation on automated HTTP port setting" />
<sf:contextvar name="HTTP_PORT_INCREASE" type="environment" value="${BE_Component.contextvar.http.port.increase}" export="false" autoincrement="none" description="Consult the user documentation on automated HTTP port setting" />
<sf:contextvar name="IS_PREPAND" type="environment" value="${BE_Component.contextvar.is.prepand}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="EXTERNAL_JAR_FILE" type="environment" value="${BE_Component.contextvar.external.jar.file}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="PLUGIN_CONFIG_FILE" type="environment" value="${BE_Component.contextvar.plugin.config.file}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="USE_OPT_EMS_DISTRO" type="environment" value="${BE_Component.contextvar.use.opt.ems.distro}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="USE_OPT_SB_DISTRO" type="environment" value="${BE_Component.contextvar.use.opt.sb.distro}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="USE_DEPEND_TEASERVER" type="environment" value="${BE_Component.contextvar.use.depend.teaserver}" export="false" autoincrement="none" description="Requires a running TIBCO Enterprise Administrator component" />
<sf:contextvar name="BE_TEAGENT_PORT_BASE" type="environment" value="${BE_Component.contextvar.be.teagent.port.base}" export="false" autoincrement="numeric" description="null" />
<sf:contextvar name="BE_TEAGENT_JMX_PORT_BASE" type="environment" value="${BE_Component.contextvar.be.teagent.jmx.port.base}" export="false" autoincrement="numeric" description="null" />
<sf:contextvar name="TEA_SERVER_URL" type="environment" value="${BE_Component.contextvar.tea.server.url}" export="false" autoincrement="none" description="URL of existing TIBCO Enterprise Administrator Server to connect to" />
<sf:contextvar name="TEA_SERVER_USERNAME" type="environment" value="${BE_Component.contextvar.tea.server.username}" export="false" autoincrement="none" description="Username of existing TIBCO Enterprise Administrator Server to connect to" />
<sf:contextvar name="BE_TEA_USE_CUSTOM_SSH_KEYS" type="environment" value="${BE_Component.contextvar.be.tea.use.custom.ssh.keys}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="BE_TEA_SSH_PRIVATE_KEY" type="environment" value="${BE_Component.contextvar.be.tea.ssh.private.key}" export="false" autoincrement="none" description="Private key file path for password-less SSH authentication" />
<sf:contextvar name="BE_TEA_SSH_PUBLIC_KEY" type="environment" value="${BE_Component.contextvar.be.tea.ssh.public.key}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="TEA_SSL_ENABLED" type="environment" value="${BE_Component.contextvar.tea.ssl.enabled}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="BE_TEA_SSL_SERVER_CERT" type="environment" value="${BE_Component.contextvar.be.tea.ssl.server.cert}" export="false" autoincrement="none" description="Server SSL certificate path" />
<sf:contextvar name="BE_TEA_SSL_CLIENT_CERT" type="environment" value="${BE_Component.contextvar.be.tea.ssl.client.cert}" export="false" autoincrement="none" description="Client SSL certificate path" />
<sf:contextvar name="BE_JRE_VERSION" type="environment" value="${BE_Component.contextvar.be.jre.version}" export="false" autoincrement="none" description="The JRE version required for BusinessEvents" />
<sf:contextvar name="BE_TEA_AGENT_REQUEST_TIMEOUT" type="environment" value="${BE_Component.contextvar.be.tea.agent.request.timeout}" export="false" autoincrement="none" description="The TIBCO BusinessEvents Enterprise Administrator Agent request timeout" />
<sf:contextvar name="DELETE_BE_TEA_MACHINE_ON_SHUTDOWN" type="environment" value="${BE_Component.contextvar.delete.be.tea.machine.on.shutdown}" export="false" autoincrement="none" description="Condition to delete the machine registered in TEA Server. Works in fast TLM restart" />
<sf:contextvar name="JDBC_DRIVER_FILE" type="environment" value="${BE_Component.contextvar.jdbc.driver.file}" export="false" autoincrement="none" description="Only if the Domain is stored in a database" />
<sf:contextvar name="DOMAIN_ENABLE_EMS_SSL" type="environment" value="${BE_Component.contextvar.domain.enable.ems.ssl}" export="false" autoincrement="none" description="If EMS SSL is enable for the domain" />
<sf:contextvar name="EMS_SSL_TRUSTED" type="environment" value="${BE_Component.contextvar.ems.ssl.trusted}" export="false" autoincrement="none" description="If EMS SSL is enable for the domain" />
<sf:contextvar name="EMS_SSL_IDENTITY" type="environment" value="${BE_Component.contextvar.ems.ssl.identity}" export="false" autoincrement="none" description="If EMS SSL is enable for the domain" />
<sf:contextvar name="EMS_SSL_PRIVATE_KEY" type="environment" value="${BE_Component.contextvar.ems.ssl.private.key}" export="false" autoincrement="none" description="If EMS SSL is enable for the domain" />
<sf:contextvar name="NOTIFIER_EMS_SSL_VENDOR" type="environment" value="${BE_Component.contextvar.notifier.ems.ssl.vendor}" export="false" autoincrement="none" description="The EMS SSL vendor" />
<sf:contextvar name="DELETE_APPLICATION_CONF_AT_SHUTDOWN" type="environment" value="${BE_Component.contextvar.delete.application.conf.at.shutdown}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="DO_NOT_REDEPLOY_EAR_FILE_AT_STARTUP" type="environment" value="${BE_Component.contextvar.do.not.redeploy.ear.file.at.startup}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="MANAGED_PROCESS_HAWK_AGENT_ENABLED" type="environment" value="${BE_Component.contextvar.managed.process.hawk.agent.enabled}" export="false" autoincrement="none" description="If the regular stop is not succesfull" />
<sf:contextvar name="MANAGED_PROCESS_SERVICE_ENABLED" type="environment" value="${BE_Component.contextvar.managed.process.service.enabled}" export="false" autoincrement="none" description="If the regular stop is not succesfull" />
<sf:contextvar name="LOGICAL_MACHINE_NAME" type="environment" value="${BE_Component.contextvar.logical.machine.name}" export="false" autoincrement="none" description="Unique Application Component machine name instantiated only once" />
<sf:contextvar name="DOMAINDATA_DIR" type="environment" value="${BE_Component.contextvar.domaindata.dir}" export="false" autoincrement="none" description="Share drive where deployment configuration will be created" />
<sf:contextvar name="TIBCO_SERVICES_STATE_AFTER_TLM_MOVED" type="environment" value="${BE_Component.contextvar.tibco.services.state.after.tlm.moved}" export="false" autoincrement="none" description="On logical machine restart, all services are either started or stopped" />
<sf:contextvar name="TEA_TIBCO_SERVICES_STATE_AFTER_TLM_MOVED" type="environment" value="${BE_Component.contextvar.tea.tibco.services.state.after.tlm.moved}" export="false" autoincrement="none" description="On logical restart of machine, all services are either started, stopped, or preserving the stae before restart" />
<sf:contextvar name="USE_FULL_ARCHIVE_NAME" type="environment" value="${BE_Component.contextvar.use.full.archive.name}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="WITHOUT_TRA" type="environment" value="${BE_Component.contextvar.without.tra}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="BE_EXECUTION_MODE" type="environment" value="${BE_Component.contextvar.be.execution.mode}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="AMI_HAWK_SERVICE" type="environment" value="${BE_Component.contextvar.ami.hawk.service}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="AMI_HAWK_DAEMON" type="environment" value="${BE_Component.contextvar.ami.hawk.daemon}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="AMI_HAWK_NETWORK" type="environment" value="${BE_Component.contextvar.ami.hawk.network}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="HAWK_PLUGIN_CONFIG_FILE" type="environment" value="${BE_Component.contextvar.hawk.plugin.config.file}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="ACTION_TO_PERFORM_FOR_HAWK_FILE" type="environment" value="${BE_Component.contextvar.action.to.perform.for.hawk.file}" export="false" autoincrement="none" description="null" />
<sf:contextvar name="HTTPChannel_JMX_PORT" type="string" value="${BE_Component.contextvar.httpchannel.jmx.port}" export="true" autoincrement="none" description="" />
<sf:contextvar name="HTTPChannel_PUID" type="string" value="${BE_Component.contextvar.httpchannel.puid}" export="true" autoincrement="none" description="" />
<sf:contextvar name="HTTPChannel_CDD" type="string" value="${BE_Component.contextvar.httpchannel.cdd}" export="true" autoincrement="none" description="" />
<sf:contextvar name="HTTPChannel_NAME" type="string" value="${BE_Component.contextvar.httpchannel.name}" export="true" autoincrement="none" description="" />
<sf:contextvar name="HTTPChannel_GLOBAL_FILE" type="string" value="${BE_Component.contextvar.httpchannel.global.file}" export="true" autoincrement="none" description="" />
<sf:contextvar name="TEA_SERVER_PASSWORD" type="encrypted" value="${BE_Component.contextvar.tea.server.password}" export="false" autoincrement="none" description="Password of existing TIBCO Enterprise Administrator Server to connect to" />
<sf:contextvar name="BE_TEA_SSH_KEY_PASSPHRASE" type="encrypted" value="${BE_Component.contextvar.be.tea.ssh.key.passphrase}" export="false" autoincrement="none" description="Passphrase to private key file for password-less SSH authentication" />
</sf:context-variable>
<sf:publish type="component" name="${BE_Component.component.name}" />
</target>
<target name="clean-BE_Component-component">
<echo message="Cleaning ${BE_Component.component.name}" />
<sf:unpublish type="component" name="${BE_Component.component.name}" onerror="ignore" />
<sf:remove type="component" name="${BE_Component.component.name}" onerror="ignore" />
</target>
<target name="release-stack">
<echo message="Building ${stack.name}" />
<sf:stack action="create" name="${stack.name}" description="${stack.description}"/>
<sf:stack-component action="add" name="${stack.name}" components="${BE_Component.component.name}" />
<!-- uncomment this section to create schedules
-->
<sf:stack-policy action="update" name="${stack.name}" >
<sf:policy manualpolicy="true">
<sf:compalloc component="${BE_Component.component.name}" min="${BE_Stack.policy.0BE_Component.min}" max="${BE_Stack.policy.0BE_Component.max}" priority="${BE_Stack.policy.0BE_Component.priority}"/>
</sf:policy>
</sf:stack-policy>
<sf:publish type="stack" name="${stack.name}" />
<sf:stack-mode name="${stack.name}" action="run" mode="${stack.mode}" />
</target>
<target name="clean-stack">
<echo message="Cleaning ${stack.name}" />
<sf:unpublish type="stack" name="${stack.name}" onerror="ignore" />
<sf:remove type="stack" name="${stack.name}" onerror="ignore" />
<!-- uncomment this section to remove schedules on clean
-->
</target>
</project>
Copyright © Cloud Software Group, Inc. All rights reserved.
