Updating ejb deployment descriptor in installed applications with the wsadmin tool

open wsadmin shell


ksh ./wsadmin.sh -lang jython -conntype SOAP -host yourhost.com -port 8879 -user userid -password password

print AdminApp.update('MyAppName', 'file', '[-operation update -contents /home/users/sg/1.xml -contenturi MyEJB.jar/META-INF/ejb-jar.xml]')

where

  • ‘MyAppName’ is display name of my application, deployed with .ear file
  • /home/users/sg/1.xml ejb deployment descriptor that I want to update in my application
  • MyEJB.jar/META-INF/ejb-jar.xml MyEJB.jar is the ejb deployed with in enterprise application (EAP), I want to update deployment descriptor of this ejb.
  • NOTE that -contenturi is
    MyEJB.jar/META-INF/ejb-jar.xml
    NOT
    MyEJB.jar,META-INF/ejb-jar.xml
    if you put , instead of / you will get
    com.ibm.websphere.management.exception.AdminException: ERROR: File does not exist for update operation

    P.S always look in dmgr logs for errors in deployment.

    Advertisements

    Leave a Reply

    Fill in your details below or click an icon to log in:

    WordPress.com Logo

    You are commenting using your WordPress.com account. Log Out / Change )

    Twitter picture

    You are commenting using your Twitter account. Log Out / Change )

    Facebook photo

    You are commenting using your Facebook account. Log Out / Change )

    Google+ photo

    You are commenting using your Google+ account. Log Out / Change )

    Connecting to %s