Creates a new configuration object in configuration repository and returns its reference as wdr.config.ConfigObject.

obj.create( <typeName>, [ <propertyName>, ], attributes )

Arguments

typeName

name of object type

propertyName

parent object’s property in context of which the new object will be created

attributes

list of new object’s attributes

Result

After successful execution, a reference to newly created wdr.config.ConfigObject is being returned.

Examples

  • Creating Server object in the scope of a Node and modifying the newly created object
node = getid1('/Node:wdrNode01/')
server = node.create('Server', name = 'wdrServer02')
server.processDefinitions[0].jvmEntries[0].maximumHeapSize = 1024
  • Creating a Property in scope of JavaVirtualMachine property systemProperties
server = getid1('/Server:wdrServer/')
property = server.processDefinitions[0].jvmEntries[0].create('Property', 'systemProperties', name='user.language', value='pl')
property.description = 'This JVM is going to write logs in Polish language. Powodzenia :)'

See also