com.ibm.websphere.ant.tasks

Class InstallApplication



  • public class InstallApplication
    extends WsAdmin
    The wsInstallApp task enables you to install a new application into a WebSphere Server or Cell. This task is a subclass of the wsadmin task and shares many of the same attributes. This task is a wrapper for the AdminApp.install() command of the wsadmin tool. Refer to the wsadmin documentation for information on the valid options available during application installation. The structure of the wsInstallApp task is shown below: <wsInstallApp wasHome="location of websphere installation" ear="the ear file you wish to install" options="the options to pass to the installation process" properties="java properties file containing attributes to set in the JVM System properties" profile="a script file to be executed before the main command or file" profileName="the profile name of the desired server" conntype="specifies the type of connection to be used." host="the host to connect to" port="the port on the host to connect to" user="user ID to authenticate with" password="password to authenticate with" failonerror="true | false"/> The wasHome attribute is optional and contains the location of the WebSphere Installation Directory.
    The ear attribute is required and contains the path of the ear that you wish to install.
    The options attribute is optional and contains the set of options you wish to pass to the installation process.
    The properties attribute is optional and it contains a java properties file containing attributes to set in the JVM System properties
    The profile attribute is optional and it contains a script file to be executed before the main command or file
    The profileName attribute is optional and it contains the name of the server profile to be used
    The conntype attribute is optional and it specifies the type of connection to be used. The Default type is SOAP. The valid values are SOAP, RMI, JMS, and NONE. NONE means that no server connection is made. The host attribute is optional and only specified if the conntype is specified. It contains the hostname of the machine to connect to
    The port attribute is optional and only specified if the conntype is specified. It contains the port on the host to connect to
    The user attribute is optional and contains the user ID to authenticate with
    The password attribute is optional and contains the password to authenticate with
    The failonerror attribute is optional. When this is specified the build will fail if any exception is thrown. The default is false.

    To use this task, add the following to your Ant build.xml <taskdef name="wsInstallApp" classname="com.ibm.websphere.ant.tasks.InstallApplication"/>
    • Field Summary

      • Fields inherited from class org.apache.tools.ant.Task

        description, location, target, taskName, taskType, wrapper
      • Fields inherited from class org.apache.tools.ant.ProjectComponent

        project
    • Constructor Summary

      Constructors 
      Constructor and Description
      InstallApplication()
      Constructor for InstallApplication.
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      org.apache.tools.ant.types.Commandline.Argument createArg()
      Creates a nested arg element.
      void execute() 
      void setCommand(java.lang.String command)
      Disabled in this subclass
      void setEar(java.lang.String application)
      Sets the ear.
      void setLang(java.lang.String lang)
      Disabled in this subclass
      void setOptions(java.lang.String options)
      Sets the options.
      void setScript(java.lang.String script)
      Disabled in this subclass
      • Methods inherited from class org.apache.tools.ant.Task

        getDescription, getLocation, getOwningTarget, getRuntimeConfigurableWrapper, getTaskName, getTaskType, getWrapper, handleErrorFlush, handleErrorOutput, handleFlush, handleInput, handleOutput, init, isInvalid, log, log, maybeConfigure, perform, reconfigure, setDescription, setLocation, setOwningTarget, setRuntimeConfigurableWrapper, setTaskName, setTaskType
      • Methods inherited from class org.apache.tools.ant.ProjectComponent

        getProject, setProject
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • InstallApplication

        public InstallApplication()
        Constructor for InstallApplication.
    • Method Detail

      • setCommand

        public void setCommand(java.lang.String command)
        Disabled in this subclass
        Overrides:
        setCommand in class WsAdmin
        Parameters:
        command - The command to set
      • setLang

        public void setLang(java.lang.String lang)
        Disabled in this subclass
        Overrides:
        setLang in class WsAdmin
        Parameters:
        lang - The lang to set
      • setScript

        public void setScript(java.lang.String script)
        Disabled in this subclass
        Overrides:
        setScript in class WsAdmin
        Parameters:
        script - The script to set
      • setEar

        public void setEar(java.lang.String application)
        Sets the ear.
        Parameters:
        ear - The ear to set
      • execute

        public void execute()
                     throws org.apache.tools.ant.BuildException
        Overrides:
        execute in class WsAdmin
        Throws:
        org.apache.tools.ant.BuildException
        See Also:
        Task.execute()
      • setOptions

        public void setOptions(java.lang.String options)
        Sets the options.
        Parameters:
        options - The options to set
      • createArg

        public org.apache.tools.ant.types.Commandline.Argument createArg()
        Description copied from class: WsAdmin
        Creates a nested arg element.
        Overrides:
        createArg in class WsAdmin
        See Also:
        WsAdmin.createArg()
IBM WebSphere Application ServerTM
Release 9.0