[jbosstools-issues] [JBoss JIRA] Commented: (JBIDE-1291) Utilize JMX DeploymentScanner to ensure proper deployment

Juergen Zimmermann (JIRA) jira-events at lists.jboss.org
Sun Feb 3 04:20:03 EST 2008


    [ http://jira.jboss.com/jira/browse/JBIDE-1291?page=comments#action_12397970 ] 
            
Juergen Zimmermann commented on JBIDE-1291:
-------------------------------------------

The ANT-based solution:

<?xml version="1.0"?>

<project name="redeploy, undeploy, deploy" default="redeploy">

	<!-- ================================================================= -->
	<!-- P r o p e r t i e s                                               -->
	<!-- ================================================================= -->
	<property name="ear.name" value="hska.ear"/>

	<property environment="env"/>
	<property name="deploy.dir" value="${env.JBOSS_HOME}/server/default/deploy"/>
	<property name="ear.url" value="file:///${deploy.dir}/${ear.name}/"/>
	
	<!-- ================================================================= -->
	<!-- P a t h                                                           -->
	<!-- ================================================================= -->
	<path id="jmx.classpath">
		<fileset dir="${env.JBOSS_HOME}/client">
			<include name="jbossjmx-ant.jar"/>
			<include name="jbossall-client.jar"/>
		</fileset>
	</path>
	

	<!-- ================================================================= -->
	<!-- T a r g e t s                                                     -->
	<!-- ================================================================= -->
	<target name="redeploy" description="Redeploy">
		<antcall target="jmx-operation">
			<param name="operation" value="redeploy"/>
		</antcall>
	</target>
	
	<target name="undeploy" description="Undeploy">
		<antcall target="jmx-operation">
			<param name="operation" value="undeploy"/>
		</antcall>
	</target>
	
	<target name="deploy" description="Deploy">
		<antcall target="jmx-operation">
			<param name="operation" value="deploy"/>
		</antcall>
	</target>
	
	<target name="jmx-operation">
		<taskdef name="jmx" classname="org.jboss.ant.JMX">
			<classpath refid="jmx.classpath"/>
		</taskdef>
		<jmx adapterName="jmx/invoker/RMIAdaptor">
			<propertyEditor type="java.net.URL"
			                editor="org.jboss.util.propertyeditor.URLEditor"/>
			<invoke target="jboss.system:service=MainDeployer"
				    operation="${operation}">
				<parameter type="java.net.URL"
						   arg="${ear.url}"/>
			</invoke>
		</jmx>
	</target>
</project>

> Utilize JMX DeploymentScanner to ensure proper deployment
> ---------------------------------------------------------
>
>                 Key: JBIDE-1291
>                 URL: http://jira.jboss.com/jira/browse/JBIDE-1291
>             Project: Tools (JBoss Tools)
>          Issue Type: Feature Request
>          Components: JBossAS
>    Affects Versions: 2.0.0.CR1
>            Reporter: Max Andersen
>         Assigned To: Rob Stryker
>            Priority: Critical
>             Fix For: 2.1
>
>
> Jmx DeploymentScanner has suspendDeployment() and resumeDeployment() which could be usefull to call before/after deployment.
> See: http://docs.jboss.org/jbossas/javadoc/4.0.4/system/org/jboss/deployment/scanner/URLDeploymentScanner.html
> addURL() could be used to have our own eclipse workspace local deployment which won't pollute existing configurations.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the jbosstools-issues mailing list