Application update scripts
The scripting library provides multiple script procedures to automate your application configurations. See the usage information for scripts that update applications. You can run each script individually or combine procedures to create custom automation scripts for your environment.
- addSingleFileToAnAppWithUpdateCommand
- addSingleModuleFileToAnAppWithUpdateCommand
- addUpdateSingleModuleFileToAnAppWithUpdateCommand
- addPartialAppToAnAppWithUpdateCommand
- deleteSingleFileToAnAppWithUpdateCommand
- deleteSingleModuleFileToAnAppWithUpdateCommand
- deletePartialAppToAnAppWithUpdateCommand
- updateApplicationUsingDefaultMerge
- updateApplicationWithUpdateIgnoreNewOption
- updateApplicationWithUpdateIgnoreOldOption
- updateEntireAppToAnAppWithUpdateCommand
- updatePartialAppToAnAppWithUpdateCommand
- updateSingleFileToAnAppWithUpdateCommand
- updateSingleModuleFileToAnAppWithUpdateCommand
addSingleFileToAnAppWithUpdateCommand
This script uses the update command to add a single file to a deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
fileContent | Specifies the name of the file to use to update the application. |
contentURI | Specifies the URI of the file content. |
Syntax
AdminApplication.addSingleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.addSingleFileToAnAppWithUpdateCommand("myApp", "c:\sample.txt", "META-INFO/sample.txt")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.addSingleFileToAnAppWithUpdateCommand("myApp", "/sample.txt", "META-INFO/sample.txt")
addSingleModuleFileToAnAppWithUpdateCommand
This script uses the update command to add a single module file to a deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
fileContent | Specifies the name of the file to use to update the application. |
contentURI | Specifies the URI of the file content. |
Syntax
AdminApplication.addSingleModuleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.addSingleModuleFileToAnAppWithUpdateCommand("myApp", "c:\Increment.jar", "Increment.jar")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.addSingleModuleFileToAnAppWithUpdateCommand("myApp", "/Increment.jar", "Increment.jar")
addUpdateSingleModuleFileToAnAppWithUpdateCommand
This script uses the update command to add and update a single module file for a deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
fileContent | Specifies the name of the file to use to update the application. |
contentURI | Specifies the URI of the file content. |
contextRoot | Specifies the context root for web modules in the application. |
Syntax
AdminApplication.addUpdateSingleModuleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI, contextRoot)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.addUpdateSingleModuleFileToAnAppWithUpdateCommand("myApp",
"c:\DefaultWebApplication.war", "DefaultWebApplication.war",
"/webapp/defaultapp")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.addUpdateSingleModuleFileToAnAppWithUpdateCommand("myApp",
"/DefaultWebApplication.war", "DefaultWebApplication.war",
"/webapp/defaultapp")
addPartialAppToAnAppWithUpdateCommand
This script uses the update command to add a partial application to a deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
fileContent | Specifies the name of the file to use to update the application. |
Syntax
AdminApplication.addPartialAppToAnAppWithUpdateCommand(appName, fileContent)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.addPartialAppToAnAppWithUpdateCommand("myApp", "c:\partialadd.zip")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.addPartialAppToAnAppWithUpdateCommand("myApp", "/partialadd.zip")
deleteSingleFileToAnAppWithUpdateCommand
This script uses the update command to delete a single file from a deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
fileContent | Specifies the name of the file to use to update the application. |
contentURI | Specifies the URI of the file content. |
Syntax
AdminApplication.deleteSingleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.deleteSingleFileToAnAppWithUpdateCommand("myApp", "c:\sample.
txt", "META-INFO/sample.txt")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.deleteSingleFileToAnAppWithUpdateCommand("myApp", "/sample.
txt", "META-INFO/sample.txt")
deleteSingleModuleFileToAnAppWithUpdateCommand
This script uses the update command to delete a single module file from a deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
fileContent | Specifies the name of the file to use to update the application. |
contentURI | Specifies the URI of the file content. |
Syntax
AdminApplication.deleteSingleModuleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.deleteSingleModuleFileToAnAppWithUpdateCommand("myApp",
"c:\Increment.jar", "Increment.jar")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.deleteSingleModuleFileToAnAppWithUpdateCommand("myApp",
"/Increment.jar", "Increment.jar")
deletePartialAppToAnAppWithUpdateCommand
This script uses the update command to delete a partial application from a deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
fileContent | Specifies the name of the file to use to update the application. |
contentURI | Specifies the URI of the file content. |
Syntax
AdminApplication.deletePartialAppToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.deletePartialAppToAnAppWithUpdateCommand("myApp", "c:\part
ialdelete.zip", "partialdelete")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.deletePartialAppToAnAppWithUpdateCommand("myApp", "/part
ialdelete.zip", "partialdelete")
updateApplicationUsingDefaultMerge
This script updates an application using default merging.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
earFile | Specifies the name of the file to use to update the application. |
Syntax
AdminApplication.updateApplicationUsingDefaultMerge(appName, earFile)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.updateApplicationUsingDefaultMerge("myApp", "c:\ears\D
efaultApplication.ear")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.updateApplicationUsingDefaultMerge("myApp", "/ears/D
efaultApplication.ear")
updateApplicationWithUpdateIgnoreNewOption
This script updates an application using -update.ignore.new option. The system ignores the bindings from the new version of the application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
earFile | Specifies the name of the file to use to update the application. |
Syntax
AdminApplication.updateApplicationWithUpdateIgnoreNewOption(appName, earFile)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.updateApplicationWithUpdateIgnoreNewOption("myApp",
"c:\ears\DefaultApplication.ear")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.updateApplicationWithUpdateIgnoreNewOption("myApp",
"c:/ears/DefaultApplication.ear")
updateApplicationWithUpdateIgnoreOldOption
This script updates an application using the -update.ignore.old option. The system ignores the bindings from the installed version of the application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
earFile | Specifies the name of the file to use to update the application. |
Syntax
AdminApplication.updateApplicationWithUpdateIgnoreOldOption(appName, earFile)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.updateApplicationWithUpdateIgnoreOldOption("myApp",
"c:\ears\DefaultApplication.ear")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.updateApplicationWithUpdateIgnoreOldOption("myApp",
"/ears/DefaultApplication.ear")
updateEntireAppToAnAppWithUpdateCommand
This script uses the update command to update an entire deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
earFile | Specifies the name of the file to use to update the application. |
Syntax
AdminApplication.updateEntireAppToAnAppWithUpdateCommand(appName, earFile)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.updateEntireAppToAnAppWithUpdateCommand("myApp", "c:\new.ear")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.updateEntireAppToAnAppWithUpdateCommand("myApp", "/new.ear")
updatePartialAppToAnAppWithUpdateCommand
This script uses the update command to update a partial application for a deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
fileContent | Specifies the name of the file to use to update the application. |
contentURI | Specifies the URI of the file content. |
Syntax
AdminApplication.updatePartialAppToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.updatePartialAppToAnAppWithUpdateCommand("myApp", "c:\part
ialadd.zip", "partialadd")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.updatePartialAppToAnAppWithUpdateCommand("myApp", "/part
ialadd.zip", "partialadd")
updateSingleFileToAnAppWithUpdateCommand
This script uses the update command to update a single file on a deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
fileContent | Specifies the name of the file to use to update the application. |
contentURI | Specifies the URI of the file content. |
Syntax
AdminApplication.updateSingleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.updateSingleFileToAnAppWithUpdateCommand("myApp", "c:\sample.
txt", "META-INFO/sample.txt")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.updateSingleFileToAnAppWithUpdateCommand("myApp", "/sample.
txt", "META-INFO/sample.txt")
updateSingleModuleFileToAnAppWithUpdateCommand
This script uses the update command to update a single module file for a deployed application.
Argument | Description |
---|---|
appName | Specifies the name of the application to update. |
fileContent | Specifies the name of the file to use to update the application. |
contentURI | Specifies the URI of the file content. |
Syntax
AdminApplication.updateSingleModuleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
![[Windows]](../images/windows.gif)
AdminApplication.updateSingleModuleFileToAnAppWithUpdateCommand("myApp",
"c:\sample.jar", "Increment.jar")
![[AIX]](../images/aixlogo.gif)
![[Solaris]](../images/solaris.gif)
![[Linux]](../images/linux.gif)
![[HP-UX]](../images/hpux.gif)
![[IBM i]](../images/iseries.gif)
![[z/OS]](../images/ngzos.gif)
AdminApplication.updateSingleModuleFileToAnAppWithUpdateCommand("myApp",
"/sample.jar", "Increment.jar")