Web client
V/
JMX client Java
PMI Client Wrapper JMX ConnectorRMI/SOAP PerfServlet PerfMBeans AppServer
TivoliMViever /^
What's more , we can create custom-made statistics to best meet our monitoring needs && displays and monitors in a portal. PMI instrumentation is based on j2ee1.4 and the custom supports all the statistic types, countstatistic timestatistic,rangetatistic, boundedrangestatistic.but as a feature , it cannot support the uerdefined statistic types.
We can use Admin Client API to get the custom performance data. Was6.1.0,%WAS_HOME%AppServe\runtimes path includes two jar files, and they r all client related Jar files.,%WAS_HOME%AppServe\properties\jmx.properties we can modify these configuration which will stand the corresponding ones of conf.properties.With the Jar file com.ibm.ws.admin.client_6.1.0.jar, as following will give a simple sample about retrieving the custom interesting performance data and here just to get the server node.
1
import java.util.HashSet;
2
import java.util.Iterator;
3
import java.util.Set;
4
5
import javax.management.MalformedObjectNameException;
6
import javax.management.ObjectName;
7
8
import com.ibm.websphere.management.AdminClient;
9
import com.ibm.websphere.management.AdminClientFactory;
10
import com.ibm.websphere.management.exception.AdminException;
11
12
/**
13
* @author QuQiang
14
*
15
*/
16
public class Test {
17
18
public static void main(String[] args) {
19
AdminClient ad = null;
20
boolean failed = false;
21
java.util.Properties props = new java.util.Properties();
22
props.put(AdminClient.CONNECTOR_TYPE, "connector");
23
props.put(AdminClient.CONNECTOR_HOST, "host");
24
props.put(AdminClient.CONNECTOR_PORT, "port");
25
try {
26
ad = AdminClientFactory.createAdminClient(props);
27
javax.management.ObjectName on = new javax.management.ObjectName(
28
"WebSphere:*");
29
Set objectNameSet = ad.queryNames(on, null);
30
HashSet nodeSet = new HashSet();
31
for (Iterator i = objectNameSet.iterator(); i.hasNext(); on = (ObjectName) i
32
.next()) {
33
String type = on.getKeyProperty("type");
34
if (type != null && type.equals("Server")) {
35
System.out.println(on.getKeyProperty("name"));//node objectName
36
}
37
}
38
39
} catch (MalformedObjectNameException me) {
40
failed = true;
41
new AdminException(me).printStackTrace();
42
System.out.println("ObjectName: exception");
43
} catch (Exception ex) {
44
failed = true;
45
new AdminException(ex).printStackTrace();
46
System.out.println("getAdminClient: exception");
47
}
48
}
49
}

2

3

4

5

6

7

8

9

10

11

12

13

14

15

16

17

18

19

20

21

22

23

24

25

26

27

28

29

30

31

32

33

34

35

36

37

38

39

40

41

42

43

44

45

46

47

48

49
