+

Search Tips   |   Advanced Search

Change the class loader order of the console module deployed in Integrated Solutions Console

Run this JACL script to change the class loader order of the console module deployed in the Integrated Solutions Console.

The following JACL script serves as an example of how to change the class loader order of the console module deployed in the Integrated Solutions Console. Other scripting types, such as JYTHON, could be used.

  1. Copy the following script into a file.
    set app [$AdminConfig getid /Deployment:isclite/]
    set webModules [$AdminConfig list WebModuleDeployment $app]
     
    foreach webModule $webModules {
         set uri [$AdminConfig showAttribute  $webModule uri]
         if {$uri  == "<WAR_NAME>"} {
             #modify the classloader for <WAR_NAME>
             set cl [$AdminConfig list Classloader $webModule]
             # check if the classloader exist 
             if {$cl == ""} {
                    # create a new one with the appropriate mode
                    $AdminConfig create Classloader $webModule  {{mode <MODE>}}
             } else {
                  # modify the existing one              $AdminConfig modify $cl  {{mode <MODE>}}
             }
         }
    }
    
    # save the configuration change $AdminConfig save

  2. Change the <WAR_NAME> on the two lines of this sample to the name of the console module file deployed in the Integrated Solutions Console which class loader order to change.

  3. Change the <MODE> on the two lines of this sample to PARENT_LAST or PARENT_FIRST as required.

  4. Save the file to any directory using, for example, the file name classloaderorder.jacl.

  5. Start the wsadmin scripting client from the <WAS-install>/profiles/<profile_name>/bin directory.

  6. Issue the following command.

      wsadmin -f <path to jacl file>/classloader.jacl