We help IT Professionals succeed at work.
Get Started

jython script for modify the contextroot of a running app in WAS 6.1

WAS
WAS asked
on
3,674 Views
Last Modified: 2014-06-10
i have trouble modifying the contextroot of a running application port-logic, below is the info and errors iam getting, please provide me with correct jython command to modify just the
context root of a running, mine is WAS6.1.0.21
wsadmin>AdminApp.edit('port-logic', ["-options"])
WASX7015E: Exception running command: "AdminApp.edit('lossb-slm', ["-options"])"; exception information:
 com.ibm.ws.scripting.ScriptingException: WASX7107E: Invalid options specified: "[options]"; valid options are:
MapModulesToServers
MapWebModToVH
CtxRootForWebMod
MapSharedLibForMod
JSPReloadForWebMod
distributeApp
nodistributeApp
useMetaDataFromBinary
nouseMetaDataFromBinary
createMBeansForResources
nocreateMBeansForResources
reloadEnabled
noreloadEnabled
allowDispatchRemoteInclude
noallowDispatchRemoteInclude
allowServiceRemoteInclude
noallowServiceRemoteInclude
verbose
installed.ear.destination
reloadInterval
validateinstall
filepermission
buildVersion
filepermission
installed.ear.destination

wsadmin>print AdminApp.view("port-logic", "-CtxRootForWebMod")


CtxRootForWebMod: Edit the Context root of web module

Context root defined in the deployment descriptor can be edited.

Web module:  port-logic.war
URI:  port-logic.war,WEB-INF/web.xml
ContextRoot:  krishna


wsadmin>


wsadmin>AdminApp.edit ( 'port-logic', ['-CtxRootForWebMod', 'Govind'])
WASX7015E: Exception running command: "AdminApp.edit ( 'port-logic', ['-CtxRootForWebMod', 'govind'])"; exception information:
 java.lang.ClassCastException: java.lang.ClassCastException: java.lang.String incompatible with java.util.List

wsadmin>
Comment
Watch Question
Software Engineer
CERTIFIED EXPERT
Commented:
This problem has been solved!
Unlock 1 Answer and 5 Comments.
See Answer
Why Experts Exchange?

Experts Exchange always has the answer, or at the least points me in the correct direction! It is like having another employee that is extremely experienced.

Jim Murphy
Programmer at Smart IT Solutions

When asked, what has been your best career decision?

Deciding to stick with EE.

Mohamed Asif
Technical Department Head

Being involved with EE helped me to grow personally and professionally.

Carl Webster
CTP, Sr Infrastructure Consultant
Ask ANY Question

Connect with Certified Experts to gain insight and support on specific technology challenges including:

  • Troubleshooting
  • Research
  • Professional Opinions
Did You Know?

We've partnered with two important charities to provide clean water and computer science education to those who need it most. READ MORE