You can use the AdminApp object to set certain configurations in the application. This example uses the AdminConfig object to configure a shared library for an application.
Using Jacl:
set node [$AdminConfig getid /Cell:mycell/Node:mynode/]Example output:
mynode(cells/mycell/nodes/mynode:node.xml#Node_1)
Using Jacl:
set library [$AdminConfig create Library $node {{name mySharedLibrary} {classPath c:/mySharedLibraryClasspath}}]Example output:
MySharedLibrary(cells/mycell/nodes/mynode:libraries.xml#Library_1)This example creates a new shared library in the node scope. You can modify it to use the cell or server scope.
Using Jacl:
set library [$AdminConfig getid /Library:mySharedLibrary/]Example output:
MySharedLibrary(cells/mycell/nodes/mynode:libraries.xml#Library_1)
Using Jacl:
set deployment [$AdminConfig getid /Deployment:myApp/]Example output:
myApp(cells/mycell/applications/myApp.ear/deployments/myApp:deployment.xml#Deployment_1)
Using Jacl:
set appDeploy [$AdminConfig showAttribute $deployment deployedObject]Example output:
(cells/mycell/applications/myApp.ear/deployments/myApp:deployment.xml#ApplicationDeployment_1)
Using Jacl:
set classLoader [$AdminConfig showAttribute $appDeploy classloader]Example output:
(cells/mycell/applications/myApp.ear/deployments/myApp:deployment.xml#Classloader_1)
Using Jacl:
$AdminConfig create LibraryRef $classLoader {{libraryName MyshareLibrary} {sharedClassloader true}}Example output:
(cells/mycell/applications/myApp.ear/deployments/myApp:deployment.xml#LibraryRef_1)
Using Jacl:
$AdminConfig save