Network Deployment (Distributed operating systems), v8.0 > Reference > Commands (wsadmin scripting)
ResourceManagement command group
Use the Jython or Jacl scripting languages to configure resource providers with wsadmin.sh. The commands and parameters in the ResourceManagement group can be used to define and display properties for resource providers.
The ResourceManagement command group includes the following commands:
setResourceProperty
Use the setResourceProperty command to set the value of a specified property defined on a resource provider such as JDBCProvider or a connection factory such as DataSource or JMSConnectionFactory. If the property with specified key is defined already, then this command overrides the value. If no property with a specified key is defined, this command will add the property with specified key and value.
Target object The configuration object ID of a resource provider or a connection factory.
Required parameters
-propertyName
Name of the property. (String, required)
-propertyValue
Value of a property. (String, required)
Optional parameters
-propertyType
Type of the property. The default value is java.lang.String. (String, optional)
-propertyDescription
Description of the defined property. (String, optional) Sample output The command does not return output.
Examples
Batch example...
### Jacl
$AdminTask setResourceProperty {-propertyName test.property -propertyValue testValue}
Jython string: AdminTask.setResourceProperty('[-propertyName test.property -propertyValue testValue]')
Use Jython list: AdminTask.setResourceProperty(['-propertyName', 'test.property', '-propertyValue', 'testValue'])
Interactive example...
### Jacl
$AdminTask setResourceProperty {-interactive}### Jython
AdminTask.setResourceProperty('-interactive')
showResourceProperties
Use the showResourceProperties command to list all of the property values that are defined on a resource provider such as JDBC provider or a connection factory such as data source or JMS connection factory.
Target object The configuration object ID of a resource provider or a connection factory.
Required parameters None.
Optional parameters
-propertyName
Name of the property. If you specify the property name, the value of the specified property name is returned. If you do not specify the property name, all property values will be listed. Each element in the list is a property name pair. (String, optional) Sample output The command returns the property values that are defined on the resource provider or the connection factory specified.
Examples
Batch example...:
### Jacl
$AdminTask showResourceProperties {-propertyName test.property}
Jython string: print AdminTask.showResourceProperties('[-propertyName test.property]')
Use Jython list: print AdminTask.showResourceProperties(['-propertyName', 'test.property'])
Interactive example...
### Jacl
$AdminTask showResourceProperties {-interactive}### Jython
print AdminTask.showResourceProperties('-interactive')
Use the wsadmin scripting AdminTask object for scripted administration
Related
Commands using wsadmin.sh