Application update scripts
The scripting library provides script procedures to automate the application configurations. See the usage information for scripts that update applications. We can run each script individually or combine procedures to create custom automation scripts for the environment.
Each application management script procedure is located in the app_server_root/scriptLibraries/application/V70 directory. Use the following script procedures to update application configurations:
- addSingleFileToAnAppWithUpdateCommand
- addSingleModuleFileToAnAppWithUpdateCommand
- addUpdateSingleModuleFileToAnAppWithUpdateCommand
- addPartialAppToAnAppWithUpdateCommand
- deleteSingleFileToAnAppWithUpdateCommand
- deleteSingleModuleFileToAnAppWithUpdateCommand
- deletePartialAppToAnAppWithUpdateCommand
- updateApplicationUsingDefaultMerge
- updateApplicationWithUpdateIgnoreNewOption
- updateApplicationWithUpdateIgnoreOldOption
- updateEntireAppToAnAppWithUpdateCommand
- updatePartialAppToAnAppWithUpdateCommand
- updateSingleFileToAnAppWithUpdateCommand
- updateSingleModuleFileToAnAppWithUpdateCommand
addSingleFileToAnAppWithUpdateCommand
Add a single file to a deployed application.
To run the script, specify the application name, file name, and the content uniform resource identifier (URI) argument:
Argument Description appName Name of the application to update. fileContent Name of the file to use to update the application. contentURI The URI of the file content. Syntax
AdminApplication.addSingleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
(Windows)
AdminApplication.addSingleFileToAnAppWithUpdateCommand("myApp", "c:\sample.txt", "META-INFO/sample.txt")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.addSingleFileToAnAppWithUpdateCommand("myApp", "/sample.txt", "META-INFO/sample.txt")
addSingleModuleFileToAnAppWithUpdateCommand
Add a single module file to a deployed application.
To run the script, specify the application name, file name, and content URI arguments:
Argument Description appName Name of the application to update. fileContent Name of the file to use to update the application. contentURI The URI of the file content. Syntax
AdminApplication.addSingleModuleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
(Windows)
AdminApplication.addSingleModuleFileToAnAppWithUpdateCommand("myApp", "c:\Increment.jar", "Increment.jar")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.addSingleModuleFileToAnAppWithUpdateCommand("myApp", "/Increment.jar", "Increment.jar")
addUpdateSingleModuleFileToAnAppWithUpdateCommand
Add and update a single module file for a deployed application.
To run the script, specify the application name, file name, content URI, and context root argument:
Argument Description appName Name of the application to update. fileContent Name of the file to use to update the application. contentURI The URI of the file content. contextRoot The context root for web modules in the application. Syntax
AdminApplication.addUpdateSingleModuleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI, contextRoot)
Example usage
(Windows)
AdminApplication.addUpdateSingleModuleFileToAnAppWithUpdateCommand("myApp", "c:\DefaultWebApplication.war", "DefaultWebApplication.war", "/webapp/defaultapp")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.addUpdateSingleModuleFileToAnAppWithUpdateCommand("myApp", "/DefaultWebApplication.war", "DefaultWebApplication.war", "/webapp/defaultapp")
addPartialAppToAnAppWithUpdateCommand
Add a partial application to a deployed application.
To run the script, specify the application name and file content argument:
Argument Description appName Name of the application to update. fileContent Name of the file to use to update the application. Syntax
AdminApplication.addPartialAppToAnAppWithUpdateCommand(appName, fileContent)
Example usage
(Windows)
AdminApplication.addPartialAppToAnAppWithUpdateCommand("myApp", "c:\partialadd.zip")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.addPartialAppToAnAppWithUpdateCommand("myApp", "/partialadd.zip")
deleteSingleFileToAnAppWithUpdateCommand
Delete a single file from a deployed application.
To run the script, specify the application name, file name, and content URI arguments:
Argument Description appName Name of the application to update. fileContent Name of the file to use to update the application. contentURI The URI of the file content. Syntax
AdminApplication.deleteSingleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
(Windows)
AdminApplication.deleteSingleFileToAnAppWithUpdateCommand("myApp", "c:\sample. txt", "META-INFO/sample.txt")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.deleteSingleFileToAnAppWithUpdateCommand("myApp", "/sample. txt", "META-INFO/sample.txt")
deleteSingleModuleFileToAnAppWithUpdateCommand
Delete a single module file from a deployed application.
To run the script, specify the application name, file name, and content URI arguments:
Argument Description appName Name of the application to update. fileContent Name of the file to use to update the application. contentURI The URI of the file content. Syntax
AdminApplication.deleteSingleModuleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
(Windows)
AdminApplication.deleteSingleModuleFileToAnAppWithUpdateCommand("myApp", "c:\Increment.jar", "Increment.jar")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.deleteSingleModuleFileToAnAppWithUpdateCommand("myApp", "/Increment.jar", "Increment.jar")
deletePartialAppToAnAppWithUpdateCommand
Delete a partial application from a deployed application.
To run the script, specify the application name, file name, and the content URI arguments:
Argument Description appName Name of the application to update. fileContent Name of the file to use to update the application. contentURI The URI of the file content. Syntax
AdminApplication.deletePartialAppToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
(Windows)
AdminApplication.deletePartialAppToAnAppWithUpdateCommand("myApp", "c:\part ialdelete.zip", "partialdelete")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.deletePartialAppToAnAppWithUpdateCommand("myApp", "/part ialdelete.zip", "partialdelete")
updateApplicationUsingDefaultMerge
Update an application using default merging.
To run the script, specify the application name and EAR file arguments, as defined in the following table:
Argument Description appName Name of the application to update. earFile Name of the file to use to update the application. Syntax
AdminApplication.updateApplicationUsingDefaultMerge(appName, earFile)
Example usage
(Windows)
AdminApplication.updateApplicationUsingDefaultMerge("myApp", "c:\ears\D efaultApplication.ear")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.updateApplicationUsingDefaultMerge("myApp", "/ears/D efaultApplication.ear")
updateApplicationWithUpdateIgnoreNewOption
Update an application using -update.ignore.new option. The system ignores the bindings from the new version of the application.
To run the script, specify the application name and EAR file arguments:
Argument Description appName Name of the application to update. earFile Name of the file to use to update the application. Syntax
AdminApplication.updateApplicationWithUpdateIgnoreNewOption(appName, earFile)
Example usage
(Windows)
AdminApplication.updateApplicationWithUpdateIgnoreNewOption("myApp", "c:\ears\DefaultApplication.ear")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.updateApplicationWithUpdateIgnoreNewOption("myApp", "c:/ears/DefaultApplication.ear")
updateApplicationWithUpdateIgnoreOldOption
Updates an application using the -update.ignore.old option. The system ignores the bindings from the installed version of the application.
To run the script, specify the application name and EAR file argument:
Argument Description appName Name of the application to update. earFile Name of the file to use to update the application. Syntax
AdminApplication.updateApplicationWithUpdateIgnoreOldOption(appName, earFile)
Example usage
(Windows)
AdminApplication.updateApplicationWithUpdateIgnoreOldOption("myApp", "c:\ears\DefaultApplication.ear")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.updateApplicationWithUpdateIgnoreOldOption("myApp", "/ears/DefaultApplication.ear")
updateEntireAppToAnAppWithUpdateCommand
Update an entire deployed application.
To run the script, specify the application name and EAR file arguments:
Argument Description appName Name of the application to update. earFile Name of the file to use to update the application. Syntax
AdminApplication.updateEntireAppToAnAppWithUpdateCommand(appName, earFile)
Example usage
(Windows)
AdminApplication.updateEntireAppToAnAppWithUpdateCommand("myApp", "c:\new.ear")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.updateEntireAppToAnAppWithUpdateCommand("myApp", "/new.ear")
updatePartialAppToAnAppWithUpdateCommand
Update a partial application for a deployed application.
To run the script, specify the application name, file name,and the content URI arguments
Argument Description appName Name of the application to update. fileContent Name of the file to use to update the application. contentURI The URI of the file content. Syntax
AdminApplication.updatePartialAppToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
(Windows)
AdminApplication.updatePartialAppToAnAppWithUpdateCommand("myApp", "c:\part ialadd.zip", "partialadd")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.updatePartialAppToAnAppWithUpdateCommand("myApp", "/part ialadd.zip", "partialadd")
updateSingleFileToAnAppWithUpdateCommand
Update a single file on a deployed application.
To run the script, specify the application name, file name, and the content URI arguments, as defined in the following table:
Argument Description appName Name of the application to update. fileContent Name of the file to use to update the application. contentURI The URI of the file content. Syntax
AdminApplication.updateSingleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
(Windows)
AdminApplication.updateSingleFileToAnAppWithUpdateCommand("myApp", "c:\sample. txt", "META-INFO/sample.txt")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.updateSingleFileToAnAppWithUpdateCommand("myApp", "/sample. txt", "META-INFO/sample.txt")
updateSingleModuleFileToAnAppWithUpdateCommand
Update a single module file for a deployed application.
To run the script, specify the application name, file name, and the content URI arguments:
Argument Description appName Name of the application to update. fileContent Name of the file to use to update the application. contentURI The URI of the file content. Syntax
AdminApplication.updateSingleModuleFileToAnAppWithUpdateCommand(appName, fileContent, contentURI)
Example usage
(Windows)
AdminApplication.updateSingleModuleFileToAnAppWithUpdateCommand("myApp", "c:\sample.jar", "Increment.jar")
(AIX) (Solaris) (Linux) (HPUX) (iSeries) (ZOS)
AdminApplication.updateSingleModuleFileToAnAppWithUpdateCommand("myApp", "/sample.jar", "Increment.jar")
Use the script library to automate the application serving environment Automating application configurations Application administration scripts Application installation and uninstallation scripts Application query scripts Application export scripts Application deployment configuration scripts