Modifying nested attributes using wsadmin.sh

 

 

Using Jacl

### Obtain the configuration ID of the object...

set t1 [$AdminConfig getid /DataSource:DSName/]


### Modify one of the object parents and specify the location of the
### nested attribute within the parent...

$AdminConfig modify $t1 {{connectionPool {{reapTime 2003}}}}
$AdminConfig save

 

Using Jython

### Obtain the configuration ID of the object...

t1=AdminConfig.getid('/DataSource:DSName/')


### Modify one of the object parents and specify the location of the
### nested attribute within the parent...

AdminConfig.modify(t1, [["connectionPool", [["reapTime", 2003]]]])
AdminConfig.save()


### Using Jython string

AdminConfig.modify(t1, '[[connectionPool [[reapTime 2003]]]]')

 

Example

Using Jacl

set techsamp [$AdminConfig getid /DataSource:DataSource/]
set pool [$AdminConfig showAttribute $techsamp connectionPool]
$AdminConfig modify $pool {{reapTime 2003}}

Using Jython list

techsamp=AdminConfig.getid('/DataSource:DSName/')
pool=AdminConfig.showAttribute(techsamp,'connectionPool')
AdminConfig.modify(pool,[['reapTime',2003]])

Using Jython string

techsamp=AdminConfig.getid('/DataSource:DSName/')
pool=AdminConfig.showAttribute(techsamp,'connectionPool')
AdminConfig.modify(pool,'[[reapTime 2003]]')