| | |
| | | { |
| | | this.configEntryDN = configEntryDN; |
| | | |
| | | alertGenerators = new CopyOnWriteArrayList<AlertGenerator>(); |
| | | invokableComponents = new CopyOnWriteArrayList<InvokableComponent>(); |
| | | monitorProviders = |
| | | new CopyOnWriteArrayList<MonitorProvider< |
| | | ? extends MonitorProviderCfg>>(); |
| | | alertGenerators = new CopyOnWriteArrayList<>(); |
| | | invokableComponents = new CopyOnWriteArrayList<>(); |
| | | monitorProviders = new CopyOnWriteArrayList<>(); |
| | | |
| | | MBeanServer mBeanServer = DirectoryServer.getJMXMBeanServer(); |
| | | if (mBeanServer != null) |
| | |
| | | |
| | | if (iterator.hasNext()) |
| | | { |
| | | List<String> stringValues = new ArrayList<String>(); |
| | | List<String> stringValues = new ArrayList<>(); |
| | | stringValues.add(value.toString()); |
| | | |
| | | while (iterator.hasNext()) |
| | |
| | | |
| | | if (iterator.hasNext()) |
| | | { |
| | | List<String> stringValues = new ArrayList<String>(); |
| | | List<String> stringValues = new ArrayList<>(); |
| | | stringValues.add(value.toString()); |
| | | |
| | | while (iterator.hasNext()) |
| | |
| | | return new MBeanInfo(CLASS_NAME, null, null, null, null, null); |
| | | } |
| | | |
| | | List<MBeanAttributeInfo> attrs = new ArrayList<MBeanAttributeInfo>(); |
| | | for (MonitorProvider<? extends MonitorProviderCfg> monitor : |
| | | monitorProviders) |
| | | List<MBeanAttributeInfo> attrs = new ArrayList<>(); |
| | | for (MonitorProvider<? extends MonitorProviderCfg> monitor : monitorProviders) |
| | | { |
| | | for (org.opends.server.types.Attribute a : monitor.getMonitorData()) |
| | | { |
| | |
| | | } |
| | | } |
| | | |
| | | MBeanAttributeInfo[] mBeanAttributes = new MBeanAttributeInfo[attrs.size()]; |
| | | attrs.toArray(mBeanAttributes); |
| | | MBeanAttributeInfo[] mBeanAttributes = attrs.toArray(new MBeanAttributeInfo[attrs.size()]); |
| | | |
| | | |
| | | List<MBeanNotificationInfo> notifications = |
| | | new ArrayList<MBeanNotificationInfo>(); |
| | | List<MBeanNotificationInfo> notifications = new ArrayList<>(); |
| | | for (AlertGenerator generator : alertGenerators) |
| | | { |
| | | String className = generator.getClassName(); |
| | |
| | | { |
| | | String[] types = { type }; |
| | | String description = alerts.get(type); |
| | | notifications.add(new MBeanNotificationInfo(types, className, |
| | | description)); |
| | | notifications.add(new MBeanNotificationInfo(types, className, description)); |
| | | } |
| | | } |
| | | |
| | | |
| | | MBeanNotificationInfo[] mBeanNotifications = |
| | | new MBeanNotificationInfo[notifications.size()]; |
| | | MBeanNotificationInfo[] mBeanNotifications = new MBeanNotificationInfo[notifications.size()]; |
| | | notifications.toArray(mBeanNotifications); |
| | | |
| | | |
| | | List<MBeanOperationInfo> ops = new ArrayList<MBeanOperationInfo>(); |
| | | List<MBeanOperationInfo> ops = new ArrayList<>(); |
| | | for (InvokableComponent component : invokableComponents) |
| | | { |
| | | for (InvokableMethod method : component.getOperationSignatures()) |