简体   繁体   中英

Set WAS Process Definition Environment Entries using Jython?

Is it possible to add custom Process Definition environment entry in a WebSphere Application Server using a jython script?

I see that the existing properties in the server.xml are assigned auto-generated IDs, is it possible to retrieve those prop without knowing their ID?

 <environment xmi:id="Property_1248356598212" name="<my_prop>" value="<my_value>" required="true"/>

WAS 6.1/i5

checkout this link for configuring process definition properties using jython

some snippets that might help you

server = AdminConfig.getid('/Cell:mycell/Node:mynode/Server:server1/') processDef = AdminConfig.list('JavaProcessDef', srvid) print AdminConfig.show(processDef, 'environment')

server = AdminConfig.getid('/Cell:mycell/Node:mynode/Server:server1/') jvm = AdminConfig.list('JavaVirtualMachine', server) AdminConfig.modify(ns, [['BOOTSTRAP_ADDRESS', [['host', 'myhost'], ['port', 2810]]]])

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM