Scripting objects
wsadmin.sh operates on configurations and running objects through the following set of management objects:
WAS System Management performs two administrative functions:
- Configuration of WAS installations
- Manipulating currently running JMS MBeans
The AdminConfig and AdminApp objects handle configuration functionality. One can invoke configuration functions with or without being connected to a server.
The AdminControl object manages running objects.
One can use the Help object to obtain information about the AdminConfig, AdminApp and AdminControl objects, and to obtain interface information about running MBeans.
Jacl
Jacl is an alternate implementation of TCL, and is written entirely in Java code.
The basic syntax for a Jacl command is:
Command arg1 arg2 arg3 ...The command is either the name of a built-in command or a Jacl procedure. For example:
In this example, the command is "puts", which takes two arguments: an I/O stream identifier and a string. puts writes the string to the I/O stream along with a trailing new line character. Arguments are interpreted by the command. In the example, stdout is used to identify the standard output stream. The use of stdout as a name is a convention employed by puts and the other I/O commands. Use stderr to identify the standard error output, and use stdin to identify the standard input.puts stdout {Hello, world!} => Hello, World!
ObjectName, Attribute, and AttributeList
WAS scripting commands use the underlying JMX classes, ObjectName, Attribute, and AttributeList, to manipulate object names, attributes and attribute lists. WAS ObjectNames uniquely identify running objects.
When ObjectNames classes are represented by strings, they have the following pattern:
[domainName]:property=value[,property=value]*For example, you can specify...
WebSphere:name=servername, type=ApplicationServer,node=nodename,*One can obtain the ObjectName for a running object with the getObjectName command.
Attributes of these objects consist of a name and a value. One can extract the name and value with the getName and getValue commands. You can also extract a list of attributes.