You can use the AdminConfig object and scripting to disable application loading in deployed targets.
The following example uses the AdminConfig object to disable application loading in deployed targets:
set deployments [$AdminConfig getid /Deployment:myApp/]
deployments = AdminConfig.getid("/Deployment:myApp/")
set | is a Jacl command |
deployments | is a variable name |
$ | is a Jacl operator for substituting a variable name with its value |
AdminConfig | is an object that represents the WebSphere® Application Server configuration |
getid | is an AdminConfig command |
Deployment | is an attribute |
myApp | ![]() ![]() jun2010 ![]() ![]() ![]() jun2010 gotcha |
myApp(cells/mycell/applications/myApp.ear/deployments/myApp|deployment.xml#Deployment_1)
set deploymentObj1 [$AdminConfig showAttribute $deployments deployedObject] set targetMap1 [lindex [$AdminConfig showAttribute $deploymentObj1 targetMappings] 0]
(cells/mycell/applications/ivtApp.ear/deployments/ivtApp|deployment.xml#DeploymentTargetMapping_1)
deploymentObj1 = AdminConfig.showAttribute(deployments, 'deployedObject') targetMap1 = AdminConfig.showAttribute(deploymentObj1, 'targetMappings') targetMap1 = targetMap1[1:len(targetMap1)-1].split(" ") print targetMap1
targetMap1 = targetMap1[1:len(targetMap1)-1].split(" ")or
targetMap1 = targetMap1[1:len(targetMap1)-1].split(java.lang.System.getProperty("line.separator"))
targetMap1 = targetMap1[1:len(targetMap1)-1].split(" ")
['(cells/mycell/applications/ivtApp.ear/deployments/ivtApp|deployment.xml#DeploymentTargetMapping_1)']
set | is a Jacl command |
deploymentObj1 | is a variable name |
$ | is a Jacl operator for substituting a variable name with its value |
AdminConfig | is an object that represents the WebSphere Application Server configuration |
showAttribute | is an AdminConfig command |
deployments | evaluates the ID of the Deployment object that is specified in step number 1 |
deployedObject | is an attribute |
targetMap1 | is a variable name |
targetMappings | is an attribute |
lindex | is a Jacl command |
is a Jython command |
foreach tm $targetMap1 { $AdminConfig modify $tm {{enable false}} }
for targetMapping in targetMap1: AdminConfig.modify(targetMapping, [["enable", "false"]])
AdminConfig.save()
In this information ...Related reference
| IBM Redbooks, demos, education, and more(Index) Use IBM Suggests to retrieve related content from ibm.com and beyond, identified for your convenience. This feature requires Internet access. Most of the following links will take you to information that is not part of the formal product documentation and is provided "as is." Some of these links go to non-IBM Web sites and are provided for your convenience only and do not in any manner serve as an endorsement by IBM of those Web sites, the material thereon, or the owner thereof. |