001/* 002 * Copyright 2008-2018 Ping Identity Corporation 003 * All Rights Reserved. 004 */ 005/* 006 * Copyright (C) 2015-2018 Ping Identity Corporation 007 * 008 * This program is free software; you can redistribute it and/or modify 009 * it under the terms of the GNU General Public License (GPLv2 only) 010 * or the terms of the GNU Lesser General Public License (LGPLv2.1 only) 011 * as published by the Free Software Foundation. 012 * 013 * This program is distributed in the hope that it will be useful, 014 * but WITHOUT ANY WARRANTY; without even the implied warranty of 015 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 016 * GNU General Public License for more details. 017 * 018 * You should have received a copy of the GNU General Public License 019 * along with this program; if not, see <http://www.gnu.org/licenses>. 020 */ 021package com.unboundid.ldap.sdk.unboundidds.monitors; 022 023 024 025import java.util.Collections; 026import java.util.Iterator; 027import java.util.LinkedHashMap; 028import java.util.Map; 029 030import com.unboundid.ldap.sdk.Entry; 031import com.unboundid.util.Debug; 032import com.unboundid.util.NotExtensible; 033import com.unboundid.util.NotMutable; 034import com.unboundid.util.ThreadSafety; 035import com.unboundid.util.ThreadSafetyLevel; 036 037import static com.unboundid.ldap.sdk.unboundidds.monitors.MonitorMessages.*; 038 039 040 041/** 042 * This class defines a monitor entry that provides information about the 043 * processing times of operations that are performed in the server. It includes 044 * the total counts of each type of operation, the average response time for 045 * each type of operation, and counts and percentages of operations whose 046 * server-side processing time fits in defined buckets. 047 * <BR> 048 * <BLOCKQUOTE> 049 * <B>NOTE:</B> This class, and other classes within the 050 * {@code com.unboundid.ldap.sdk.unboundidds} package structure, are only 051 * supported for use against Ping Identity, UnboundID, and 052 * Nokia/Alcatel-Lucent 8661 server products. These classes provide support 053 * for proprietary functionality or for external specifications that are not 054 * considered stable or mature enough to be guaranteed to work in an 055 * interoperable way with other types of LDAP servers. 056 * </BLOCKQUOTE> 057 * <BR> 058 * The following buckets are defined in the default configuration: 059 * <UL> 060 * <LI>Less than 1ms.</LI> 061 * <LI>Greater than or equal to 1ms and less than 2ms.</LI> 062 * <LI>Greater than or equal to 2ms and less than 3ms.</LI> 063 * <LI>Greater than or equal to 3ms and less than 5ms.</LI> 064 * <LI>Greater than or equal to 5ms and less than 10ms.</LI> 065 * <LI>Greater than or equal to 10ms and less than 20ms.</LI> 066 * <LI>Greater than or equal to 20ms and less than 30ms.</LI> 067 * <LI>Greater than or equal to 30ms and less than 50ms.</LI> 068 * <LI>Greater than or equal to 50ms and less than 100ms.</LI> 069 * <LI>Greater than or equal to 100ms and less than 1000ms.</LI> 070 * <LI>Greater than or equal to 1000ms.</LI> 071 * </UL> 072 * It provides the following information for each operation, as well as for the 073 * total for all operations: 074 * <UL> 075 * <LI>The number of operations of the specified type within each bucket.</LI> 076 * <LI>The percentage of operations of the specified type within each 077 * bucket.</LI> 078 * <LI>The aggregate percentage of operations of the specified type for each 079 * bucket (i.e., the percentage of operations in that bucket or any 080 * bucket for a lower duration).</LI> 081 * </UL> 082 * The server should present at most one processing time histogram monitor 083 * entry. It can be retrieved using the 084 * {@link MonitorManager#getProcessingTimeHistogramMonitorEntry} method. 085 * This entry provides specific methods for accessing information about 086 * processing times per bucket (e.g., the 087 * {@link ProcessingTimeHistogramMonitorEntry#getAllOpsPercent} method can be 088 * used to retrieve a map containing the percent of operations within each 089 * bucket). Alternately, this information may be accessed using the generic 090 * API. See the {@link MonitorManager} class documentation for an example that 091 * demonstrates the use of the generic API for accessing monitor data. 092 */ 093@NotMutable() 094@NotExtensible() 095@ThreadSafety(level=ThreadSafetyLevel.COMPLETELY_THREADSAFE) 096public class ProcessingTimeHistogramMonitorEntry 097 extends MonitorEntry 098{ 099 /** 100 * The structural object class used in processing time histogram monitor 101 * entries. 102 */ 103 static final String PROCESSING_TIME_HISTOGRAM_MONITOR_OC = 104 "ds-processing-time-histogram-monitor-entry"; 105 106 107 108 /** 109 * The name of the attribute that contains the total number of add 110 * operations performed in the server. 111 */ 112 private static final String ATTR_ADD_TOTAL_COUNT = "addOpsTotalCount"; 113 114 115 116 /** 117 * The name of the attribute that contains the average response time in 118 * milliseconds for add operations performed in the server. 119 */ 120 private static final String ATTR_ADD_AVERAGE_RESPONSE_TIME_MS = 121 "addOpsAverageResponseTimeMillis"; 122 123 124 125 /** 126 * The name of the attribute that contains the aggregate percentage of add 127 * operations within each processing time bucket. 128 */ 129 private static final String ATTR_ADD_AGGREGATE_PERCENT = 130 "addOpsAggregatePercent"; 131 132 133 134 /** 135 * The name of the attribute that contains the total number of add operations 136 * within each processing time bucket. 137 */ 138 private static final String ATTR_ADD_COUNT = "addOpsCount"; 139 140 141 142 /** 143 * The name of the attribute that contains the percentage of add operations 144 * within each processing time bucket. 145 */ 146 private static final String ATTR_ADD_PERCENT = "addOpsPercent"; 147 148 149 150 /** 151 * The name of the attribute that contains the total number of all 152 * operations performed in the server. 153 */ 154 private static final String ATTR_ALL_TOTAL_COUNT = "allOpsTotalCount"; 155 156 157 158 /** 159 * The name of the attribute that contains the average response time in 160 * milliseconds for all operations performed in the server. 161 */ 162 private static final String ATTR_ALL_AVERAGE_RESPONSE_TIME_MS = 163 "allOpsAverageResponseTimeMillis"; 164 165 166 167 /** 168 * The name of the attribute that contains the aggregate percentage of 169 * operations of all types within each processing time bucket. 170 */ 171 private static final String ATTR_ALL_AGGREGATE_PERCENT = 172 "allOpsAggregatePercent"; 173 174 175 176 /** 177 * The name of the attribute that contains the total number of operations of 178 * all types within each processing time bucket. 179 */ 180 private static final String ATTR_ALL_COUNT = "allOpsCount"; 181 182 183 184 /** 185 * The name of the attribute that contains the percentage of operations of all 186 * types within each processing time bucket. 187 */ 188 private static final String ATTR_ALL_PERCENT = "allOpsPercent"; 189 190 191 192 /** 193 * The name of the attribute that contains the total number of bind 194 * operations performed in the server. 195 */ 196 private static final String ATTR_BIND_TOTAL_COUNT = "bindOpsTotalCount"; 197 198 199 200 /** 201 * The name of the attribute that contains the average response time in 202 * milliseconds for bind operations performed in the server. 203 */ 204 private static final String ATTR_BIND_AVERAGE_RESPONSE_TIME_MS = 205 "bindOpsAverageResponseTimeMillis"; 206 207 208 209 /** 210 * The name of the attribute that contains the aggregate percentage of bind 211 * operations within each processing time bucket. 212 */ 213 private static final String ATTR_BIND_AGGREGATE_PERCENT = 214 "bindOpsAggregatePercent"; 215 216 217 218 /** 219 * The name of the attribute that contains the total number of bind operations 220 * within each processing time bucket. 221 */ 222 private static final String ATTR_BIND_COUNT = "bindOpsCount"; 223 224 225 226 /** 227 * The name of the attribute that contains the percentage of bind operations 228 * within each processing time bucket. 229 */ 230 private static final String ATTR_BIND_PERCENT = "bindOpsPercent"; 231 232 233 234 /** 235 * The name of the attribute that contains the total number of compare 236 * operations performed in the server. 237 */ 238 private static final String ATTR_COMPARE_TOTAL_COUNT = "compareOpsTotalCount"; 239 240 241 242 /** 243 * The name of the attribute that contains the average response time in 244 * milliseconds for compare operations performed in the server. 245 */ 246 private static final String ATTR_COMPARE_AVERAGE_RESPONSE_TIME_MS = 247 "compareOpsAverageResponseTimeMillis"; 248 249 250 251 /** 252 * The name of the attribute that contains the aggregate percentage of compare 253 * operations within each processing time bucket. 254 */ 255 private static final String ATTR_COMPARE_AGGREGATE_PERCENT = 256 "compareOpsAggregatePercent"; 257 258 259 260 /** 261 * The name of the attribute that contains the total number of compare 262 * operations within each processing time bucket. 263 */ 264 private static final String ATTR_COMPARE_COUNT = "compareOpsCount"; 265 266 267 268 /** 269 * The name of the attribute that contains the percentage of compare 270 * operations within each processing time bucket. 271 */ 272 private static final String ATTR_COMPARE_PERCENT = "compareOpsPercent"; 273 274 275 276 /** 277 * The name of the attribute that contains the total number of delete 278 * operations performed in the server. 279 */ 280 private static final String ATTR_DELETE_TOTAL_COUNT = "deleteOpsTotalCount"; 281 282 283 284 /** 285 * The name of the attribute that contains the average response time in 286 * milliseconds for delete operations performed in the server. 287 */ 288 private static final String ATTR_DELETE_AVERAGE_RESPONSE_TIME_MS = 289 "deleteOpsAverageResponseTimeMillis"; 290 291 292 293 /** 294 * The name of the attribute that contains the aggregate percentage of delete 295 * operations within each processing time bucket. 296 */ 297 private static final String ATTR_DELETE_AGGREGATE_PERCENT = 298 "deleteOpsAggregatePercent"; 299 300 301 302 /** 303 * The name of the attribute that contains the total number of delete 304 * operations within each processing time bucket. 305 */ 306 private static final String ATTR_DELETE_COUNT = "deleteOpsCount"; 307 308 309 310 /** 311 * The name of the attribute that contains the percentage of delete operations 312 * within each processing time bucket. 313 */ 314 private static final String ATTR_DELETE_PERCENT = "deleteOpsPercent"; 315 316 317 318 /** 319 * The name of the attribute that contains the total number of extended 320 * operations performed in the server. 321 */ 322 private static final String ATTR_EXTENDED_TOTAL_COUNT = 323 "extendedOpsTotalCount"; 324 325 326 327 /** 328 * The name of the attribute that contains the average response time in 329 * milliseconds for extended operations performed in the server. 330 */ 331 private static final String ATTR_EXTENDED_AVERAGE_RESPONSE_TIME_MS = 332 "extendedOpsAverageResponseTimeMillis"; 333 334 335 336 /** 337 * The name of the attribute that contains the aggregate percentage of 338 * extended operations within each processing time bucket. 339 */ 340 private static final String ATTR_EXTENDED_AGGREGATE_PERCENT = 341 "extendedOpsAggregatePercent"; 342 343 344 345 /** 346 * The name of the attribute that contains the total number of extended 347 * operations within each processing time bucket. 348 */ 349 private static final String ATTR_EXTENDED_COUNT = "extendedOpsCount"; 350 351 352 353 /** 354 * The name of the attribute that contains the percentage of extended 355 * operations within each processing time bucket. 356 */ 357 private static final String ATTR_EXTENDED_PERCENT = "extendedOpsPercent"; 358 359 360 361 /** 362 * The name of the attribute that contains the total number of modify 363 * operations performed in the server. 364 */ 365 private static final String ATTR_MODIFY_TOTAL_COUNT = "modifyOpsTotalCount"; 366 367 368 369 /** 370 * The name of the attribute that contains the average response time in 371 * milliseconds for modify operations performed in the server. 372 */ 373 private static final String ATTR_MODIFY_AVERAGE_RESPONSE_TIME_MS = 374 "modifyOpsAverageResponseTimeMillis"; 375 376 377 378 /** 379 * The name of the attribute that contains the aggregate percentage of modify 380 * operations within each processing time bucket. 381 */ 382 private static final String ATTR_MODIFY_AGGREGATE_PERCENT = 383 "modifyOpsAggregatePercent"; 384 385 386 387 /** 388 * The name of the attribute that contains the total number of modify 389 * operations within each processing time bucket. 390 */ 391 private static final String ATTR_MODIFY_COUNT = "modifyOpsCount"; 392 393 394 395 /** 396 * The name of the attribute that contains the percentage of modify operations 397 * within each processing time bucket. 398 */ 399 private static final String ATTR_MODIFY_PERCENT = "modifyOpsPercent"; 400 401 402 403 /** 404 * The name of the attribute that contains the total number of modify DN 405 * operations performed in the server. 406 */ 407 private static final String ATTR_MODIFY_DN_TOTAL_COUNT = 408 "modifyDNOpsTotalCount"; 409 410 411 412 /** 413 * The name of the attribute that contains the average response time in 414 * milliseconds for modify DN operations performed in the server. 415 */ 416 private static final String ATTR_MODIFY_DN_AVERAGE_RESPONSE_TIME_MS = 417 "modifyDNOpsAverageResponseTimeMillis"; 418 419 420 421 /** 422 * The name of the attribute that contains the aggregate percentage of modify 423 * DN operations within each processing time bucket. 424 */ 425 private static final String ATTR_MODIFY_DN_AGGREGATE_PERCENT = 426 "modifyDNOpsAggregatePercent"; 427 428 429 430 /** 431 * The name of the attribute that contains the total number of modify DN 432 * operations within each processing time bucket. 433 */ 434 private static final String ATTR_MODIFY_DN_COUNT = "modifyDNOpsCount"; 435 436 437 438 /** 439 * The name of the attribute that contains the percentage of modify DN 440 * operations within each processing time bucket. 441 */ 442 private static final String ATTR_MODIFY_DN_PERCENT = "modifyDNOpsPercent"; 443 444 445 446 /** 447 * The name of the attribute that contains the total number of search 448 * operations performed in the server. 449 */ 450 private static final String ATTR_SEARCH_TOTAL_COUNT = "searchOpsTotalCount"; 451 452 453 454 /** 455 * The name of the attribute that contains the average response time in 456 * milliseconds for search operations performed in the server. 457 */ 458 private static final String ATTR_SEARCH_AVERAGE_RESPONSE_TIME_MS = 459 "searchOpsAverageResponseTimeMillis"; 460 461 462 463 /** 464 * The name of the attribute that contains the aggregate percentage of search 465 * operations within each processing time bucket. 466 */ 467 private static final String ATTR_SEARCH_AGGREGATE_PERCENT = 468 "searchOpsAggregatePercent"; 469 470 471 472 /** 473 * The name of the attribute that contains the total number of search 474 * operations within each processing time bucket. 475 */ 476 private static final String ATTR_SEARCH_COUNT = "searchOpsCount"; 477 478 479 480 /** 481 * The name of the attribute that contains the percentage of search operations 482 * within each processing time bucket. 483 */ 484 private static final String ATTR_SEARCH_PERCENT = "searchOpsPercent"; 485 486 487 488 /** 489 * The serial version UID for this serializable class. 490 */ 491 private static final long serialVersionUID = -2498009928344820276L; 492 493 494 495 // The percent of add operations in each bucket. 496 private final Map<Long,Double> addOpsPercent; 497 498 // The aggregate percent of add operations in each bucket. 499 private final Map<Long,Double> addOpsAggregatePercent; 500 501 // The percent of operations of all types in each bucket. 502 private final Map<Long,Double> allOpsPercent; 503 504 // The aggregate percent of operations of all types in each bucket. 505 private final Map<Long,Double> allOpsAggregatePercent; 506 507 // The percent of bind operations in each bucket. 508 private final Map<Long,Double> bindOpsPercent; 509 510 // The aggregate percent of bind operations in each bucket. 511 private final Map<Long,Double> bindOpsAggregatePercent; 512 513 // The percent of compare operations in each bucket. 514 private final Map<Long,Double> compareOpsPercent; 515 516 // The aggregate percent of compare operations in each bucket. 517 private final Map<Long,Double> compareOpsAggregatePercent; 518 519 // The percent of delete operations in each bucket. 520 private final Map<Long,Double> deleteOpsPercent; 521 522 // The aggregate percent of delete operations in each bucket. 523 private final Map<Long,Double> deleteOpsAggregatePercent; 524 525 // The percent of extended operations in each bucket. 526 private final Map<Long,Double> extendedOpsPercent; 527 528 // The aggregate percent of extended operations in each bucket. 529 private final Map<Long,Double> extendedOpsAggregatePercent; 530 531 // The percent of modify operations in each bucket. 532 private final Map<Long,Double> modifyOpsPercent; 533 534 // The aggregate percent of modify operations in each bucket. 535 private final Map<Long,Double> modifyOpsAggregatePercent; 536 537 // The percent of modify DN operations in each bucket. 538 private final Map<Long,Double> modifyDNOpsPercent; 539 540 // The aggregate percent of modify DN operations in each bucket. 541 private final Map<Long,Double> modifyDNOpsAggregatePercent; 542 543 // The percent of search operations in each bucket. 544 private final Map<Long,Double> searchOpsPercent; 545 546 // The aggregate percent of search operations in each bucket. 547 private final Map<Long,Double> searchOpsAggregatePercent; 548 549 // The number of add operations in each bucket. 550 private final Map<Long,Long> addOpsCount; 551 552 // The number of operations of all types in each bucket. 553 private final Map<Long,Long> allOpsCount; 554 555 // The number of bind operations in each bucket. 556 private final Map<Long,Long> bindOpsCount; 557 558 // The number of compare operations in each bucket. 559 private final Map<Long,Long> compareOpsCount; 560 561 // The number of delete operations in each bucket. 562 private final Map<Long,Long> deleteOpsCount; 563 564 // The number of extended operations in each bucket. 565 private final Map<Long,Long> extendedOpsCount; 566 567 // The number of modify operations in each bucket. 568 private final Map<Long,Long> modifyOpsCount; 569 570 // The number of modifyDN operations in each bucket. 571 private final Map<Long,Long> modifyDNOpsCount; 572 573 // The number of search operations in each bucket. 574 private final Map<Long,Long> searchOpsCount; 575 576 // The total number of add operations. 577 private final Long addOpsTotalCount; 578 579 // The total number of all operations. 580 private final Long allOpsTotalCount; 581 582 // The total number of bind operations. 583 private final Long bindOpsTotalCount; 584 585 // The total number of compare operations. 586 private final Long compareOpsTotalCount; 587 588 // The total number of delete operations. 589 private final Long deleteOpsTotalCount; 590 591 // The total number of extended operations. 592 private final Long extendedOpsTotalCount; 593 594 // The total number of modify operations. 595 private final Long modifyOpsTotalCount; 596 597 // The total number of modify DN operations. 598 private final Long modifyDNOpsTotalCount; 599 600 // The total number of search operations. 601 private final Long searchOpsTotalCount; 602 603 // The average response time in milliseconds for add operations. 604 605 private final Double addOpsAvgResponseTimeMillis; 606 607 // The average response time in milliseconds for all operations. 608 private final Double allOpsAvgResponseTimeMillis; 609 610 // The average response time in milliseconds for bind operations. 611 private final Double bindOpsAvgResponseTimeMillis; 612 613 // The average response time in milliseconds for compare operations. 614 private final Double compareOpsAvgResponseTimeMillis; 615 616 // The average response time in milliseconds for delete operations. 617 private final Double deleteOpsAvgResponseTimeMillis; 618 619 // The average response time in milliseconds for extended operations. 620 private final Double extendedOpsAvgResponseTimeMillis; 621 622 // The average response time in milliseconds for modify operations. 623 private final Double modifyOpsAvgResponseTimeMillis; 624 625 // The average response time in milliseconds for modify DN operations. 626 private final Double modifyDNOpsAvgResponseTimeMillis; 627 628 // The average response time in milliseconds for search operations. 629 private final Double searchOpsAvgResponseTimeMillis; 630 631 632 /** 633 * Creates a new processing time histogram monitor entry from the provided 634 * entry. 635 * 636 * @param entry The entry to be parsed as a processing time histogram 637 * monitor entry. It must not be {@code null}. 638 */ 639 public ProcessingTimeHistogramMonitorEntry(final Entry entry) 640 { 641 super(entry); 642 643 allOpsTotalCount = getLong(ATTR_ALL_TOTAL_COUNT); 644 allOpsAvgResponseTimeMillis = getDouble(ATTR_ALL_AVERAGE_RESPONSE_TIME_MS); 645 allOpsCount = parseCountAttribute(entry, ATTR_ALL_COUNT); 646 allOpsPercent = parsePercentAttribute(entry, ATTR_ALL_PERCENT); 647 allOpsAggregatePercent = 648 parsePercentAttribute(entry, ATTR_ALL_AGGREGATE_PERCENT); 649 650 addOpsTotalCount = getLong(ATTR_ADD_TOTAL_COUNT); 651 addOpsAvgResponseTimeMillis = getDouble(ATTR_ADD_AVERAGE_RESPONSE_TIME_MS); 652 addOpsCount = parseCountAttribute(entry, ATTR_ADD_COUNT); 653 addOpsPercent = parsePercentAttribute(entry, ATTR_ADD_PERCENT); 654 addOpsAggregatePercent = 655 parsePercentAttribute(entry, ATTR_ADD_AGGREGATE_PERCENT); 656 657 bindOpsTotalCount = getLong(ATTR_BIND_TOTAL_COUNT); 658 bindOpsAvgResponseTimeMillis = 659 getDouble(ATTR_BIND_AVERAGE_RESPONSE_TIME_MS); 660 bindOpsCount = parseCountAttribute(entry, ATTR_BIND_COUNT); 661 bindOpsPercent = parsePercentAttribute(entry, ATTR_BIND_PERCENT); 662 bindOpsAggregatePercent = 663 parsePercentAttribute(entry, ATTR_BIND_AGGREGATE_PERCENT); 664 665 compareOpsTotalCount = getLong(ATTR_COMPARE_TOTAL_COUNT); 666 compareOpsAvgResponseTimeMillis = 667 getDouble(ATTR_COMPARE_AVERAGE_RESPONSE_TIME_MS); 668 compareOpsCount = parseCountAttribute(entry, ATTR_COMPARE_COUNT); 669 compareOpsPercent = parsePercentAttribute(entry, ATTR_COMPARE_PERCENT); 670 compareOpsAggregatePercent = 671 parsePercentAttribute(entry, ATTR_COMPARE_AGGREGATE_PERCENT); 672 673 deleteOpsTotalCount = getLong(ATTR_DELETE_TOTAL_COUNT); 674 deleteOpsAvgResponseTimeMillis = 675 getDouble(ATTR_DELETE_AVERAGE_RESPONSE_TIME_MS); 676 deleteOpsCount = parseCountAttribute(entry, ATTR_DELETE_COUNT); 677 deleteOpsPercent = parsePercentAttribute(entry, ATTR_DELETE_PERCENT); 678 deleteOpsAggregatePercent = 679 parsePercentAttribute(entry, ATTR_DELETE_AGGREGATE_PERCENT); 680 681 extendedOpsTotalCount = getLong(ATTR_EXTENDED_TOTAL_COUNT); 682 extendedOpsAvgResponseTimeMillis = 683 getDouble(ATTR_EXTENDED_AVERAGE_RESPONSE_TIME_MS); 684 extendedOpsCount = parseCountAttribute(entry, ATTR_EXTENDED_COUNT); 685 extendedOpsPercent = parsePercentAttribute(entry, ATTR_EXTENDED_PERCENT); 686 extendedOpsAggregatePercent = 687 parsePercentAttribute(entry, ATTR_EXTENDED_AGGREGATE_PERCENT); 688 689 modifyOpsTotalCount = getLong(ATTR_MODIFY_TOTAL_COUNT); 690 modifyOpsAvgResponseTimeMillis = 691 getDouble(ATTR_MODIFY_AVERAGE_RESPONSE_TIME_MS); 692 modifyOpsCount = parseCountAttribute(entry, ATTR_MODIFY_COUNT); 693 modifyOpsPercent = parsePercentAttribute(entry, ATTR_MODIFY_PERCENT); 694 modifyOpsAggregatePercent = 695 parsePercentAttribute(entry, ATTR_MODIFY_AGGREGATE_PERCENT); 696 697 modifyDNOpsTotalCount = getLong(ATTR_MODIFY_DN_TOTAL_COUNT); 698 modifyDNOpsAvgResponseTimeMillis = 699 getDouble(ATTR_MODIFY_DN_AVERAGE_RESPONSE_TIME_MS); 700 modifyDNOpsCount = parseCountAttribute(entry, ATTR_MODIFY_DN_COUNT); 701 modifyDNOpsPercent = parsePercentAttribute(entry, ATTR_MODIFY_DN_PERCENT); 702 modifyDNOpsAggregatePercent = 703 parsePercentAttribute(entry, ATTR_MODIFY_DN_AGGREGATE_PERCENT); 704 705 searchOpsTotalCount = getLong(ATTR_SEARCH_TOTAL_COUNT); 706 searchOpsAvgResponseTimeMillis = 707 getDouble(ATTR_SEARCH_AVERAGE_RESPONSE_TIME_MS); 708 searchOpsCount = parseCountAttribute(entry, ATTR_SEARCH_COUNT); 709 searchOpsPercent = parsePercentAttribute(entry, ATTR_SEARCH_PERCENT); 710 searchOpsAggregatePercent = 711 parsePercentAttribute(entry, ATTR_SEARCH_AGGREGATE_PERCENT); 712 } 713 714 715 716 /** 717 * Parses the value of a specified attribute to obtain a mapping between the 718 * lower bucket boundary and an integer value. 719 * 720 * @param entry The entry containing the data to process. 721 * @param name The name of the attribute containing the data to process. 722 * 723 * @return A map with the parsed information, or an empty map if the 724 * specified attribute did not exist or could not be parsed. 725 */ 726 private static Map<Long,Long> parseCountAttribute(final Entry entry, 727 final String name) 728 { 729 final String[] values = entry.getAttributeValues(name); 730 if ((values == null) || (values.length == 0)) 731 { 732 return Collections.emptyMap(); 733 } 734 735 try 736 { 737 final LinkedHashMap<Long,Long> map = new LinkedHashMap<>(50); 738 739 // FIXME -- Do we need to figure out how to make this 740 // internationalizeable? 741 742 // The lower bound for the first bucket will always be zero, so just look 743 // for the colon to separate the label from the value. 744 int colonPos = values[0].indexOf(':'); 745 map.put(0L, Long.parseLong(values[0].substring(colonPos+1).trim())); 746 747 // For remaining values, the lower bound will be the number immediately 748 // after "Between " and immediately before "ms". 749 for (int i=1; i < values.length; i++) 750 { 751 final long lowerBound; 752 int msPos = values[i].indexOf("ms "); 753 if (msPos < 0) 754 { 755 // This must be the last value. 756 msPos = values[i].indexOf("ms:"); 757 lowerBound = Long.parseLong(values[i].substring(9, msPos)); 758 } 759 else 760 { 761 lowerBound = Long.parseLong(values[i].substring(8, msPos)); 762 } 763 764 colonPos = values[i].indexOf(':', msPos); 765 map.put(lowerBound, 766 Long.parseLong(values[i].substring(colonPos+1).trim())); 767 } 768 769 return Collections.unmodifiableMap(map); 770 } 771 catch (final Exception e) 772 { 773 Debug.debugException(e); 774 return Collections.emptyMap(); 775 } 776 } 777 778 779 780 /** 781 * Parses the value of a specified attribute to obtain a mapping between the 782 * lower bucket boundary and a floating-point value. 783 * 784 * @param entry The entry containing the data to process. 785 * @param name The name of the attribute containing the data to process. 786 * 787 * @return A map with the parsed information, or an empty map if the 788 * specified attribute did not exist or could not be parsed. 789 */ 790 private static Map<Long,Double> parsePercentAttribute(final Entry entry, 791 final String name) 792 { 793 final String[] values = entry.getAttributeValues(name); 794 if ((values == null) || (values.length == 0)) 795 { 796 return Collections.emptyMap(); 797 } 798 799 try 800 { 801 final LinkedHashMap<Long,Double> map = new LinkedHashMap<>(50); 802 803 // FIXME -- Do we need to figure out how to make this 804 // internationalizeable? 805 806 // The standard percent histogram attributes will always use the following 807 // pattern: 808 // - One "Less than Xms: N.NNNN%" line. 809 // - Zero or more "Between Xms and Yms: N.NNNN%" lines. 810 // - One "At least Xms: N.NNNN%" line. 811 // 812 // The aggregate percent histogram attributes may use the above pattern, 813 // or they may instead use the following alternate pattern (which will 814 // have one less value because the last aggregate percent is known to be 815 // 100% and will be implied rather than explicitly stated): 816 // - One or more "Less than Xms: N.NNNN%" lines. 817 // 818 // We need to support both formats. 819 boolean atLeastFound = false; 820 long lastUpperBound = 0L; 821 for (final String s : values) 822 { 823 final int colonPos = s.indexOf(':'); 824 final int pctPos = s.indexOf('%', colonPos); 825 final double percent = 826 Double.parseDouble(s.substring(colonPos+1, pctPos)); 827 828 final int msPos = s.indexOf("ms"); 829 if (s.startsWith("Less than ")) 830 { 831 map.put(lastUpperBound, percent); 832 lastUpperBound = Long.parseLong(s.substring(10, msPos)); 833 } 834 else if (s.startsWith("Between ")) 835 { 836 final long lowerBound = Long.parseLong(s.substring(8, msPos)); 837 map.put(lowerBound, percent); 838 839 final int secondMSPos = s.indexOf("ms:", msPos+1); 840 lastUpperBound = Long.parseLong(s.substring(msPos+7, secondMSPos)); 841 } 842 else 843 { 844 atLeastFound = true; 845 final long lowerBound = Long.parseLong(s.substring(9, msPos)); 846 map.put(lowerBound, percent); 847 } 848 } 849 850 if (! atLeastFound) 851 { 852 map.put(lastUpperBound, 100.0d); 853 } 854 855 return Collections.unmodifiableMap(map); 856 } 857 catch (final Exception e) 858 { 859 Debug.debugException(e); 860 return Collections.emptyMap(); 861 } 862 } 863 864 865 866 /** 867 * Retrieves the total number of operations that have been performed in the 868 * server. 869 * 870 * @return The total number of operations that have been performed in the 871 * server, or {@code null} if it was not included in the monitor 872 * entry. 873 */ 874 public final Long getAllOpsTotalCount() 875 { 876 return allOpsTotalCount; 877 } 878 879 880 881 /** 882 * Retrieves the average response time in milliseconds of all operations 883 * of all types performed in the server. 884 * 885 * @return The average response time in milliseconds of all operations of all 886 * types performed in the server, or {@code null} if it was not 887 * included in the monitor entry. 888 */ 889 public final Double getAllOpsAverageResponseTimeMillis() 890 { 891 return allOpsAvgResponseTimeMillis; 892 } 893 894 895 896 /** 897 * Retrieves a map with information about the total number of operations of 898 * all types within each of the response time buckets. The mapping will be 899 * between the lower bound for the processing time bucket in milliseconds and 900 * the number of operations whose processing time fell within that bucket. 901 * 902 * @return A map with information about the total number of operations of all 903 * types within each of the response time buckets, or an empty map if 904 * it was not included in the monitor entry. 905 */ 906 public final Map<Long,Long> getAllOpsCount() 907 { 908 return allOpsCount; 909 } 910 911 912 913 /** 914 * Retrieves a map with information about the percentage of operations of 915 * all types within each of the response time buckets. The mapping will be 916 * between the lower bound for the processing time bucket in milliseconds and 917 * the percentage of operations whose processing time fell within that bucket. 918 * 919 * @return A map with information about the percentage of operations of all 920 * types within each of the response time buckets, or an empty map if 921 * it was not included in the monitor entry. 922 */ 923 public final Map<Long,Double> getAllOpsPercent() 924 { 925 return allOpsPercent; 926 } 927 928 929 930 /** 931 * Retrieves a map with information about the aggregate percentage of 932 * operations of all types within each of the response time buckets or one of 933 * the lower response time buckets. The mapping will be between the lower 934 * bound for the processing time bucket in milliseconds and the aggregate 935 * percentage of operations whose processing time fell within that or lower 936 * response time buckets. 937 * 938 * @return A map with information about the aggregate percentage of 939 * operations of all types within each of the response time buckets, 940 * or an empty map if it was not included in the monitor entry. 941 */ 942 public final Map<Long,Double> getAllOpsAggregatePercent() 943 { 944 return allOpsAggregatePercent; 945 } 946 947 948 949 /** 950 * Retrieves the total number of add operations that have been performed 951 * in the server. 952 * 953 * @return The total number of add operations that have been performed in the 954 * server, or {@code null} if it was not included in the monitor 955 * entry. 956 */ 957 public final Long getAddOpsTotalCount() 958 { 959 return addOpsTotalCount; 960 } 961 962 963 964 /** 965 * Retrieves the average response time in milliseconds of add operations 966 * performed in the server. 967 * 968 * @return The average response time in milliseconds of add operations 969 * that have been performed in the server, or {@code null} if it was 970 * not included in the monitor entry. 971 */ 972 public final Double getAddOpsAverageResponseTimeMillis() 973 { 974 return addOpsAvgResponseTimeMillis; 975 } 976 977 978 979 /** 980 * Retrieves a map with information about the total number of add operations 981 * within each of the response time buckets. The mapping will be between 982 * the lower bound for the processing time bucket in milliseconds and the 983 * number of operations whose processing time fell within that bucket. 984 * 985 * @return A map with information about the total number of add operations 986 * within each of the response time buckets, or an empty map if it 987 * was not included in the monitor entry. 988 */ 989 public final Map<Long,Long> getAddOpsCount() 990 { 991 return addOpsCount; 992 } 993 994 995 996 /** 997 * Retrieves a map with information about the percentage of add operations 998 * within each of the response time buckets. The mapping will be between the 999 * lower bound for the processing time bucket in milliseconds and the 1000 * percentage of operations whose processing time fell within that bucket. 1001 * 1002 * @return A map with information about the percentage of add operations 1003 * within each of the response time buckets, or an empty map if it 1004 * was not included in the monitor entry. 1005 */ 1006 public final Map<Long,Double> getAddOpsPercent() 1007 { 1008 return addOpsPercent; 1009 } 1010 1011 1012 1013 /** 1014 * Retrieves a map with information about the aggregate percentage of add 1015 * operations within each of the response time buckets or one of the lower 1016 * response time buckets. The mapping will be between the lower bound for the 1017 * processing time bucket in milliseconds and the aggregate percentage of 1018 * operations whose processing time fell within that or lower response time 1019 * buckets. 1020 * 1021 * @return A map with information about the aggregate percentage of add 1022 * operations within each of the response time buckets, or an empty 1023 * map if it was not included in the monitor entry. 1024 */ 1025 public final Map<Long,Double> getAddOpsAggregatePercent() 1026 { 1027 return addOpsAggregatePercent; 1028 } 1029 1030 1031 1032 /** 1033 * Retrieves the total number of bind operations that have been performed 1034 * in the server. 1035 * 1036 * @return The total number of bind operations that have been performed in 1037 * the server, or {@code null} if it was not included in the monitor 1038 * entry. 1039 */ 1040 public final Long getBindOpsTotalCount() 1041 { 1042 return bindOpsTotalCount; 1043 } 1044 1045 1046 1047 /** 1048 * Retrieves the average response time in milliseconds of bind operations 1049 * performed in the server. 1050 * 1051 * @return The average response time in milliseconds of bind operations 1052 * that have been performed in the server, or {@code null} if it was 1053 * not included in the monitor entry. 1054 */ 1055 public final Double getBindOpsAverageResponseTimeMillis() 1056 { 1057 return bindOpsAvgResponseTimeMillis; 1058 } 1059 1060 1061 1062 /** 1063 * Retrieves a map with information about the total number of bind operations 1064 * within each of the response time buckets. The mapping will be between 1065 * the lower bound for the processing time bucket in milliseconds and the 1066 * number of operations whose processing time fell within that bucket. 1067 * 1068 * @return A map with information about the total number of bind operations 1069 * within each of the response time buckets, or an empty map if it 1070 * was not included in the monitor entry. 1071 */ 1072 public final Map<Long,Long> getBindOpsCount() 1073 { 1074 return bindOpsCount; 1075 } 1076 1077 1078 1079 /** 1080 * Retrieves a map with information about the percentage of bind operations 1081 * within each of the response time buckets. The mapping will be between the 1082 * lower bound for the processing time bucket in milliseconds and the 1083 * percentage of operations whose processing time fell within that bucket. 1084 * 1085 * @return A map with information about the percentage of bind operations 1086 * within each of the response time buckets, or an empty map if it 1087 * was not included in the monitor entry. 1088 */ 1089 public final Map<Long,Double> getBindOpsPercent() 1090 { 1091 return bindOpsPercent; 1092 } 1093 1094 1095 1096 /** 1097 * Retrieves a map with information about the aggregate percentage of bind 1098 * operations within each of the response time buckets or one of the lower 1099 * response time buckets. The mapping will be between the lower bound for the 1100 * processing time bucket in milliseconds and the aggregate percentage of 1101 * operations whose processing time fell within that or lower response time 1102 * buckets. 1103 * 1104 * @return A map with information about the aggregate percentage of bind 1105 * operations within each of the response time buckets, or an empty 1106 * map if it was not included in the monitor entry. 1107 */ 1108 public final Map<Long,Double> getBindOpsAggregatePercent() 1109 { 1110 return bindOpsAggregatePercent; 1111 } 1112 1113 1114 1115 /** 1116 * Retrieves the total number of compare operations that have been performed 1117 * in the server. 1118 * 1119 * @return The total number of compare operations that have been performed in 1120 * the server, or {@code null} if it was not included in the monitor 1121 * entry. 1122 */ 1123 public final Long getCompareOpsTotalCount() 1124 { 1125 return compareOpsTotalCount; 1126 } 1127 1128 1129 1130 /** 1131 * Retrieves the average response time in milliseconds of compare operations 1132 * performed in the server. 1133 * 1134 * @return The average response time in milliseconds of compare operations 1135 * that have been performed in the server, or {@code null} if it was 1136 * not included in the monitor entry. 1137 */ 1138 public final Double getCompareOpsAverageResponseTimeMillis() 1139 { 1140 return compareOpsAvgResponseTimeMillis; 1141 } 1142 1143 1144 1145 /** 1146 * Retrieves a map with information about the total number of compare 1147 * operations within each of the response time buckets. The mapping will 1148 * be between the lower bound for the processing time bucket in milliseconds 1149 * and the number of operations whose processing time fell within that bucket. 1150 * 1151 * @return A map with information about the total number of compare 1152 * operations within each of the response time buckets, or an empty 1153 * map if it was not included in the monitor entry. 1154 */ 1155 public final Map<Long,Long> getCompareOpsCount() 1156 { 1157 return compareOpsCount; 1158 } 1159 1160 1161 1162 /** 1163 * Retrieves a map with information about the percentage of compare operations 1164 * within each of the response time buckets. The mapping will be between the 1165 * lower bound for the processing time bucket in milliseconds and the 1166 * percentage of operations whose processing time fell within that bucket. 1167 * 1168 * @return A map with information about the percentage of compare operations 1169 * within each of the response time buckets, or an empty map if it 1170 * was not included in the monitor entry. 1171 */ 1172 public final Map<Long,Double> getCompareOpsPercent() 1173 { 1174 return compareOpsPercent; 1175 } 1176 1177 1178 1179 /** 1180 * Retrieves a map with information about the aggregate percentage of compare 1181 * operations within each of the response time buckets or one of the lower 1182 * response time buckets. The mapping will be between the lower bound for the 1183 * processing time bucket in milliseconds and the aggregate percentage of 1184 * operations whose processing time fell within that or lower response time 1185 * buckets. 1186 * 1187 * @return A map with information about the aggregate percentage of compare 1188 * operations within each of the response time buckets, or an empty 1189 * map if it was not included in the monitor entry. 1190 */ 1191 public final Map<Long,Double> getCompareOpsAggregatePercent() 1192 { 1193 return compareOpsAggregatePercent; 1194 } 1195 1196 1197 1198 /** 1199 * Retrieves the total number of delete operations that have been performed 1200 * in the server. 1201 * 1202 * @return The total number of delete operations that have been performed in 1203 * the server, or {@code null} if it was not included in the monitor 1204 * entry. 1205 */ 1206 public final Long getDeleteOpsTotalCount() 1207 { 1208 return deleteOpsTotalCount; 1209 } 1210 1211 1212 1213 /** 1214 * Retrieves the average response time in milliseconds of delete operations 1215 * performed in the server. 1216 * 1217 * @return The average response time in milliseconds of delete operations 1218 * that have been performed in the server, or {@code null} if it was 1219 * not included in the monitor entry. 1220 */ 1221 public final Double getDeleteOpsAverageResponseTimeMillis() 1222 { 1223 return deleteOpsAvgResponseTimeMillis; 1224 } 1225 1226 1227 1228 /** 1229 * Retrieves a map with information about the total number of delete 1230 * operations within each of the response time buckets. The mapping will 1231 * be between the lower bound for the processing time bucket in milliseconds 1232 * and the number of operations whose processing time fell within that bucket. 1233 * 1234 * @return A map with information about the total number of delete 1235 * operations within each of the response time buckets, or an empty 1236 * map if it was not included in the monitor entry. 1237 */ 1238 public final Map<Long,Long> getDeleteOpsCount() 1239 { 1240 return deleteOpsCount; 1241 } 1242 1243 1244 1245 /** 1246 * Retrieves a map with information about the percentage of delete operations 1247 * within each of the response time buckets. The mapping will be between the 1248 * lower bound for the processing time bucket in milliseconds and the 1249 * percentage of operations whose processing time fell within that bucket. 1250 * 1251 * @return A map with information about the percentage of delete operations 1252 * within each of the response time buckets, or an empty map if it 1253 * was not included in the monitor entry. 1254 */ 1255 public final Map<Long,Double> getDeleteOpsPercent() 1256 { 1257 return deleteOpsPercent; 1258 } 1259 1260 1261 1262 /** 1263 * Retrieves a map with information about the aggregate percentage of delete 1264 * operations within each of the response time buckets or one of the lower 1265 * response time buckets. The mapping will be between the lower bound for the 1266 * processing time bucket in milliseconds and the aggregate percentage of 1267 * operations whose processing time fell within that or lower response time 1268 * buckets. 1269 * 1270 * @return A map with information about the aggregate percentage of delete 1271 * operations within each of the response time buckets, or an empty 1272 * map if it was not included in the monitor entry. 1273 */ 1274 public final Map<Long,Double> getDeleteOpsAggregatePercent() 1275 { 1276 return deleteOpsAggregatePercent; 1277 } 1278 1279 1280 1281 /** 1282 * Retrieves the total number of extended operations that have been performed 1283 * in the server. 1284 * 1285 * @return The total number of extended operations that have been performed 1286 * in the server, or {@code null} if it was not included in the 1287 * monitor entry. 1288 */ 1289 public final Long getExtendedOpsTotalCount() 1290 { 1291 return extendedOpsTotalCount; 1292 } 1293 1294 1295 1296 /** 1297 * Retrieves the average response time in milliseconds of extended operations 1298 * performed in the server. 1299 * 1300 * @return The average response time in milliseconds of extended operations 1301 * that have been performed in the server, or {@code null} if it was 1302 * not included in the monitor entry. 1303 */ 1304 public final Double getExtendedOpsAverageResponseTimeMillis() 1305 { 1306 return extendedOpsAvgResponseTimeMillis; 1307 } 1308 1309 1310 1311 /** 1312 * Retrieves a map with information about the total number of extended 1313 * operations within each of the response time buckets. The mapping will be 1314 * between the lower bound for the processing time bucket in milliseconds and 1315 * the number of operations whose processing time fell within that bucket. 1316 * 1317 * @return A map with information about the total number of extended 1318 * operations within each of the response time buckets, or an empty 1319 * map if it was not included in the monitor entry. 1320 */ 1321 public final Map<Long,Long> getExtendedOpsCount() 1322 { 1323 return extendedOpsCount; 1324 } 1325 1326 1327 1328 /** 1329 * Retrieves a map with information about the percentage of extended 1330 * operations within each of the response time buckets. The mapping will be 1331 * between the lower bound for the processing time bucket in milliseconds and 1332 * the percentage of operations whose processing time fell within that bucket. 1333 * 1334 * @return A map with information about the percentage of extended operations 1335 * within each of the response time buckets, or an empty map if it 1336 * was not included in the monitor entry. 1337 */ 1338 public final Map<Long,Double> getExtendedOpsPercent() 1339 { 1340 return extendedOpsPercent; 1341 } 1342 1343 1344 1345 /** 1346 * Retrieves a map with information about the aggregate percentage of extended 1347 * operations within each of the response time buckets or one of the lower 1348 * response time buckets. The mapping will be between the lower bound for the 1349 * processing time bucket in milliseconds and the aggregate percentage of 1350 * operations whose processing time fell within that or lower response time 1351 * buckets. 1352 * 1353 * @return A map with information about the aggregate percentage of extended 1354 * operations within each of the response time buckets, or an empty 1355 * map if it was not included in the monitor entry. 1356 */ 1357 public final Map<Long,Double> getExtendedOpsAggregatePercent() 1358 { 1359 return extendedOpsAggregatePercent; 1360 } 1361 1362 1363 1364 /** 1365 * Retrieves the total number of modify operations that have been performed 1366 * in the server. 1367 * 1368 * @return The total number of modify operations that have been performed in 1369 * the server, or {@code null} if it was not included in the monitor 1370 * entry. 1371 */ 1372 public final Long getModifyOpsTotalCount() 1373 { 1374 return modifyOpsTotalCount; 1375 } 1376 1377 1378 1379 /** 1380 * Retrieves the average response time in milliseconds of modify operations 1381 * performed in the server. 1382 * 1383 * @return The average response time in milliseconds of modify operations 1384 * that have been performed in the server, or {@code null} if it was 1385 * not included in the monitor entry. 1386 */ 1387 public final Double getModifyOpsAverageResponseTimeMillis() 1388 { 1389 return modifyOpsAvgResponseTimeMillis; 1390 } 1391 1392 1393 1394 /** 1395 * Retrieves a map with information about the total number of modify 1396 * operations within each of the response time buckets. The mapping will 1397 * be between the lower bound for the processing time bucket in milliseconds 1398 * and the number of operations whose processing time fell within that bucket. 1399 * 1400 * @return A map with information about the total number of modify 1401 * operations within each of the response time buckets, or an empty 1402 * map if it was not included in the monitor entry. 1403 */ 1404 public final Map<Long,Long> getModifyOpsCount() 1405 { 1406 return modifyOpsCount; 1407 } 1408 1409 1410 1411 /** 1412 * Retrieves a map with information about the percentage of modify operations 1413 * within each of the response time buckets. The mapping will be between the 1414 * lower bound for the processing time bucket in milliseconds and the 1415 * percentage of operations whose processing time fell within that bucket. 1416 * 1417 * @return A map with information about the percentage of modify operations 1418 * within each of the response time buckets, or an empty map if it 1419 * was not included in the monitor entry. 1420 */ 1421 public final Map<Long,Double> getModifyOpsPercent() 1422 { 1423 return modifyOpsPercent; 1424 } 1425 1426 1427 1428 /** 1429 * Retrieves a map with information about the aggregate percentage of modify 1430 * operations within each of the response time buckets or one of the lower 1431 * response time buckets. The mapping will be between the lower bound for the 1432 * processing time bucket in milliseconds and the aggregate percentage of 1433 * operations whose processing time fell within that or lower response time 1434 * buckets. 1435 * 1436 * @return A map with information about the aggregate percentage of modify 1437 * operations within each of the response time buckets, or an empty 1438 * map if it was not included in the monitor entry. 1439 */ 1440 public final Map<Long,Double> getModifyOpsAggregatePercent() 1441 { 1442 return modifyOpsAggregatePercent; 1443 } 1444 1445 1446 1447 /** 1448 * Retrieves a map with information about the total number of modify DN 1449 * operations within each of the response time buckets. The mapping will 1450 * be between the lower bound for the processing time bucket in milliseconds 1451 * and the number of operations whose processing time fell within that bucket. 1452 * 1453 * @return A map with information about the total number of modify DN 1454 * operations within each of the response time buckets, or an empty 1455 * map if it was not included in the monitor entry. 1456 */ 1457 public final Map<Long,Long> getModifyDNOpsCount() 1458 { 1459 return modifyDNOpsCount; 1460 } 1461 1462 1463 1464 /** 1465 * Retrieves the total number of modify DN operations that have been performed 1466 * in the server. 1467 * 1468 * @return The total number of modify DN operations that have been performed 1469 * in the server, or {@code null} if it was not included in the 1470 * monitor entry. 1471 */ 1472 public final Long getModifyDNOpsTotalCount() 1473 { 1474 return modifyDNOpsTotalCount; 1475 } 1476 1477 1478 1479 /** 1480 * Retrieves the average response time in milliseconds of modify DN operations 1481 * performed in the server. 1482 * 1483 * @return The average response time in milliseconds of modify DN operations 1484 * that have been performed in the server, or {@code null} if it was 1485 * not included in the monitor entry. 1486 */ 1487 public final Double getModifyDNOpsAverageResponseTimeMillis() 1488 { 1489 return modifyDNOpsAvgResponseTimeMillis; 1490 } 1491 1492 1493 1494 /** 1495 * Retrieves a map with information about the percentage of modify DN 1496 * operations within each of the response time buckets. The mapping will be 1497 * between the lower bound for the processing time bucket in milliseconds and 1498 * the percentage of operations whose processing time fell within that bucket. 1499 * 1500 * @return A map with information about the percentage of modify DN 1501 * operations within each of the response time buckets, or an empty 1502 * map if it was not included in the monitor entry. 1503 */ 1504 public final Map<Long,Double> getModifyDNOpsPercent() 1505 { 1506 return modifyDNOpsPercent; 1507 } 1508 1509 1510 1511 /** 1512 * Retrieves a map with information about the aggregate percentage of modify 1513 * DN operations within each of the response time buckets or one of the lower 1514 * response time buckets. The mapping will be between the lower bound for the 1515 * processing time bucket in milliseconds and the aggregate percentage of 1516 * operations whose processing time fell within that or lower response time 1517 * buckets. 1518 * 1519 * @return A map with information about the aggregate percentage of modify DN 1520 * operations within each of the response time buckets, or an empty 1521 * map if it was not included in the monitor entry. 1522 */ 1523 public final Map<Long,Double> getModifyDNOpsAggregatePercent() 1524 { 1525 return modifyDNOpsAggregatePercent; 1526 } 1527 1528 1529 1530 /** 1531 * Retrieves the total number of search operations that have been performed 1532 * in the server. 1533 * 1534 * @return The total number of search operations that have been performed in 1535 * the server, or {@code null} if it was not included in the monitor 1536 * entry. 1537 */ 1538 public final Long getSearchOpsTotalCount() 1539 { 1540 return searchOpsTotalCount; 1541 } 1542 1543 1544 1545 /** 1546 * Retrieves the average response time in milliseconds of search operations 1547 * performed in the server. 1548 * 1549 * @return The average response time in milliseconds of search operations 1550 * that have been performed in the server, or {@code null} if it was 1551 * not included in the monitor entry. 1552 */ 1553 public final Double getSearchOpsAverageResponseTimeMillis() 1554 { 1555 return searchOpsAvgResponseTimeMillis; 1556 } 1557 1558 1559 1560 /** 1561 * Retrieves a map with information about the total number of search 1562 * operations within each of the response time buckets. The mapping will 1563 * be between the lower bound for the processing time bucket in milliseconds 1564 * and the number of operations whose processing time fell within that bucket. 1565 * 1566 * @return A map with information about the total number of search 1567 * operations within each of the response time buckets, or an empty 1568 * map if it was not included in the monitor entry. 1569 */ 1570 public final Map<Long,Long> getSearchOpsCount() 1571 { 1572 return searchOpsCount; 1573 } 1574 1575 1576 1577 /** 1578 * Retrieves a map with information about the percentage of search operations 1579 * within each of the response time buckets. The mapping will be between the 1580 * lower bound for the processing time bucket in milliseconds and the 1581 * percentage of operations whose processing time fell within that bucket. 1582 * 1583 * @return A map with information about the percentage of search operations 1584 * within each of the response time buckets, or an empty map if it 1585 * was not included in the monitor entry. 1586 */ 1587 public final Map<Long,Double> getSearchOpsPercent() 1588 { 1589 return searchOpsPercent; 1590 } 1591 1592 1593 1594 /** 1595 * Retrieves a map with information about the aggregate percentage of search 1596 * operations within each of the response time buckets or one of the lower 1597 * response time buckets. The mapping will be between the lower bound for the 1598 * processing time bucket in milliseconds and the aggregate percentage of 1599 * operations whose processing time fell within that or lower response time 1600 * buckets. 1601 * 1602 * @return A map with information about the aggregate percentage of search 1603 * operations within each of the response time buckets, or an empty 1604 * map if it was not included in the monitor entry. 1605 */ 1606 public final Map<Long,Double> getSearchOpsAggregatePercent() 1607 { 1608 return searchOpsAggregatePercent; 1609 } 1610 1611 1612 1613 /** 1614 * {@inheritDoc} 1615 */ 1616 @Override() 1617 public String getMonitorDisplayName() 1618 { 1619 return INFO_PROCESSING_TIME_MONITOR_DISPNAME.get(); 1620 } 1621 1622 1623 1624 /** 1625 * {@inheritDoc} 1626 */ 1627 @Override() 1628 public String getMonitorDescription() 1629 { 1630 return INFO_PROCESSING_TIME_MONITOR_DESC.get(); 1631 } 1632 1633 1634 1635 /** 1636 * {@inheritDoc} 1637 */ 1638 @Override() 1639 public Map<String,MonitorAttribute> getMonitorAttributes() 1640 { 1641 final LinkedHashMap<String,MonitorAttribute> attrs = 1642 new LinkedHashMap<>(50); 1643 1644 if (allOpsTotalCount != null) 1645 { 1646 addMonitorAttribute(attrs, 1647 ATTR_ALL_TOTAL_COUNT, 1648 INFO_PROCESSING_TIME_DISPNAME_ALL_TOTAL_COUNT.get(), 1649 INFO_PROCESSING_TIME_DESC_ALL_TOTAL_COUNT.get(), 1650 allOpsTotalCount); 1651 } 1652 1653 if (allOpsAvgResponseTimeMillis != null) 1654 { 1655 addMonitorAttribute(attrs, 1656 ATTR_ALL_AVERAGE_RESPONSE_TIME_MS, 1657 INFO_PROCESSING_TIME_DISPNAME_ALL_TOTAL_TIME.get(), 1658 INFO_PROCESSING_TIME_DESC_ALL_TOTAL_TIME.get(), 1659 allOpsAvgResponseTimeMillis); 1660 } 1661 1662 if (! allOpsCount.isEmpty()) 1663 { 1664 final Iterator<Long> iterator = allOpsCount.keySet().iterator(); 1665 Long lastValue = iterator.next(); 1666 1667 while (iterator.hasNext()) 1668 { 1669 final Long value = iterator.next(); 1670 addMonitorAttribute(attrs, 1671 "allOpsCount-" + lastValue + '-' + value, 1672 INFO_PROCESSING_TIME_DISPNAME_ALL_COUNT.get(lastValue, value), 1673 INFO_PROCESSING_TIME_DESC_ALL_COUNT.get(lastValue, value), 1674 allOpsCount.get(lastValue)); 1675 1676 lastValue = value; 1677 if (! iterator.hasNext()) 1678 { 1679 addMonitorAttribute(attrs, 1680 "allOpsCount-" + lastValue, 1681 INFO_PROCESSING_TIME_DISPNAME_ALL_COUNT_LAST.get(lastValue), 1682 INFO_PROCESSING_TIME_DESC_ALL_COUNT_LAST.get(lastValue), 1683 allOpsCount.get(lastValue)); 1684 } 1685 } 1686 } 1687 1688 if (! allOpsPercent.isEmpty()) 1689 { 1690 final Iterator<Long> iterator = allOpsPercent.keySet().iterator(); 1691 Long lastValue = iterator.next(); 1692 1693 while (iterator.hasNext()) 1694 { 1695 final Long value = iterator.next(); 1696 addMonitorAttribute(attrs, 1697 "allOpsPct-" + lastValue + '-' + value, 1698 INFO_PROCESSING_TIME_DISPNAME_ALL_PCT.get(lastValue, value), 1699 INFO_PROCESSING_TIME_DESC_ALL_PCT.get(lastValue, value), 1700 allOpsPercent.get(lastValue)); 1701 1702 lastValue = value; 1703 if (! iterator.hasNext()) 1704 { 1705 addMonitorAttribute(attrs, 1706 "allOpsPct-" + lastValue, 1707 INFO_PROCESSING_TIME_DISPNAME_ALL_PCT_LAST.get(lastValue), 1708 INFO_PROCESSING_TIME_DESC_ALL_PCT_LAST.get(lastValue), 1709 allOpsPercent.get(lastValue)); 1710 } 1711 } 1712 } 1713 1714 if (! allOpsAggregatePercent.isEmpty()) 1715 { 1716 final Iterator<Long> iterator = 1717 allOpsAggregatePercent.keySet().iterator(); 1718 Long lastValue = iterator.next(); 1719 1720 while (iterator.hasNext()) 1721 { 1722 final Long value = iterator.next(); 1723 addMonitorAttribute(attrs, 1724 "allOpsAggrPct-" + lastValue + '-' + value, 1725 INFO_PROCESSING_TIME_DISPNAME_ALL_AGGR_PCT.get(lastValue, value), 1726 INFO_PROCESSING_TIME_DESC_ALL_AGGR_PCT.get(lastValue, value), 1727 allOpsAggregatePercent.get(lastValue)); 1728 1729 lastValue = value; 1730 } 1731 } 1732 1733 if (addOpsTotalCount != null) 1734 { 1735 addMonitorAttribute(attrs, 1736 ATTR_ADD_TOTAL_COUNT, 1737 INFO_PROCESSING_TIME_DISPNAME_ADD_TOTAL_COUNT.get(), 1738 INFO_PROCESSING_TIME_DESC_ADD_TOTAL_COUNT.get(), 1739 addOpsTotalCount); 1740 } 1741 1742 if (addOpsAvgResponseTimeMillis != null) 1743 { 1744 addMonitorAttribute(attrs, 1745 ATTR_ADD_AVERAGE_RESPONSE_TIME_MS, 1746 INFO_PROCESSING_TIME_DISPNAME_ADD_TOTAL_TIME.get(), 1747 INFO_PROCESSING_TIME_DESC_ADD_TOTAL_TIME.get(), 1748 addOpsAvgResponseTimeMillis); 1749 } 1750 1751 if (! addOpsCount.isEmpty()) 1752 { 1753 final Iterator<Long> iterator = addOpsCount.keySet().iterator(); 1754 Long lastValue = iterator.next(); 1755 1756 while (iterator.hasNext()) 1757 { 1758 final Long value = iterator.next(); 1759 addMonitorAttribute(attrs, 1760 "addOpsCount-" + lastValue + '-' + value, 1761 INFO_PROCESSING_TIME_DISPNAME_ADD_COUNT.get(lastValue, value), 1762 INFO_PROCESSING_TIME_DESC_ADD_COUNT.get(lastValue, value), 1763 addOpsCount.get(lastValue)); 1764 1765 lastValue = value; 1766 if (! iterator.hasNext()) 1767 { 1768 addMonitorAttribute(attrs, 1769 "addOpsCount-" + lastValue, 1770 INFO_PROCESSING_TIME_DISPNAME_ADD_COUNT_LAST.get(lastValue), 1771 INFO_PROCESSING_TIME_DESC_ADD_COUNT_LAST.get(lastValue), 1772 addOpsCount.get(lastValue)); 1773 } 1774 } 1775 } 1776 1777 if (! addOpsPercent.isEmpty()) 1778 { 1779 final Iterator<Long> iterator = addOpsPercent.keySet().iterator(); 1780 Long lastValue = iterator.next(); 1781 1782 while (iterator.hasNext()) 1783 { 1784 final Long value = iterator.next(); 1785 addMonitorAttribute(attrs, 1786 "addOpsPct-" + lastValue + '-' + value, 1787 INFO_PROCESSING_TIME_DISPNAME_ADD_PCT.get(lastValue, value), 1788 INFO_PROCESSING_TIME_DESC_ADD_PCT.get(lastValue, value), 1789 addOpsPercent.get(lastValue)); 1790 1791 lastValue = value; 1792 if (! iterator.hasNext()) 1793 { 1794 addMonitorAttribute(attrs, 1795 "addOpsPct-" + lastValue, 1796 INFO_PROCESSING_TIME_DISPNAME_ADD_PCT_LAST.get(lastValue), 1797 INFO_PROCESSING_TIME_DESC_ADD_PCT_LAST.get(lastValue), 1798 addOpsPercent.get(lastValue)); 1799 } 1800 } 1801 } 1802 1803 if (! addOpsAggregatePercent.isEmpty()) 1804 { 1805 final Iterator<Long> iterator = 1806 addOpsAggregatePercent.keySet().iterator(); 1807 Long lastValue = iterator.next(); 1808 1809 while (iterator.hasNext()) 1810 { 1811 final Long value = iterator.next(); 1812 addMonitorAttribute(attrs, 1813 "addOpsAggrPct-" + lastValue + '-' + value, 1814 INFO_PROCESSING_TIME_DISPNAME_ADD_AGGR_PCT.get(lastValue, value), 1815 INFO_PROCESSING_TIME_DESC_ADD_AGGR_PCT.get(lastValue, value), 1816 addOpsAggregatePercent.get(lastValue)); 1817 1818 lastValue = value; 1819 } 1820 } 1821 1822 if (bindOpsTotalCount != null) 1823 { 1824 addMonitorAttribute(attrs, 1825 ATTR_BIND_TOTAL_COUNT, 1826 INFO_PROCESSING_TIME_DISPNAME_BIND_TOTAL_COUNT.get(), 1827 INFO_PROCESSING_TIME_DESC_BIND_TOTAL_COUNT.get(), 1828 bindOpsTotalCount); 1829 } 1830 1831 if (bindOpsAvgResponseTimeMillis != null) 1832 { 1833 addMonitorAttribute(attrs, 1834 ATTR_BIND_AVERAGE_RESPONSE_TIME_MS, 1835 INFO_PROCESSING_TIME_DISPNAME_BIND_TOTAL_TIME.get(), 1836 INFO_PROCESSING_TIME_DESC_BIND_TOTAL_TIME.get(), 1837 bindOpsAvgResponseTimeMillis); 1838 } 1839 1840 if (! bindOpsCount.isEmpty()) 1841 { 1842 final Iterator<Long> iterator = bindOpsCount.keySet().iterator(); 1843 Long lastValue = iterator.next(); 1844 1845 while (iterator.hasNext()) 1846 { 1847 final Long value = iterator.next(); 1848 addMonitorAttribute(attrs, 1849 "bindOpsCount-" + lastValue + '-' + value, 1850 INFO_PROCESSING_TIME_DISPNAME_BIND_COUNT.get(lastValue, value), 1851 INFO_PROCESSING_TIME_DESC_BIND_COUNT.get(lastValue, value), 1852 bindOpsCount.get(lastValue)); 1853 1854 lastValue = value; 1855 if (! iterator.hasNext()) 1856 { 1857 addMonitorAttribute(attrs, 1858 "bindOpsCount-" + lastValue, 1859 INFO_PROCESSING_TIME_DISPNAME_BIND_COUNT_LAST.get(lastValue), 1860 INFO_PROCESSING_TIME_DESC_BIND_COUNT_LAST.get(lastValue), 1861 bindOpsCount.get(lastValue)); 1862 } 1863 } 1864 } 1865 1866 if (! bindOpsPercent.isEmpty()) 1867 { 1868 final Iterator<Long> iterator = bindOpsPercent.keySet().iterator(); 1869 Long lastValue = iterator.next(); 1870 1871 while (iterator.hasNext()) 1872 { 1873 final Long value = iterator.next(); 1874 addMonitorAttribute(attrs, 1875 "bindOpsPct-" + lastValue + '-' + value, 1876 INFO_PROCESSING_TIME_DISPNAME_BIND_PCT.get(lastValue, value), 1877 INFO_PROCESSING_TIME_DESC_BIND_PCT.get(lastValue, value), 1878 bindOpsPercent.get(lastValue)); 1879 1880 lastValue = value; 1881 if (! iterator.hasNext()) 1882 { 1883 addMonitorAttribute(attrs, 1884 "bindOpsPct-" + lastValue, 1885 INFO_PROCESSING_TIME_DISPNAME_BIND_PCT_LAST.get(lastValue), 1886 INFO_PROCESSING_TIME_DESC_BIND_PCT_LAST.get(lastValue), 1887 bindOpsPercent.get(lastValue)); 1888 } 1889 } 1890 } 1891 1892 if (! bindOpsAggregatePercent.isEmpty()) 1893 { 1894 final Iterator<Long> iterator = 1895 bindOpsAggregatePercent.keySet().iterator(); 1896 Long lastValue = iterator.next(); 1897 1898 while (iterator.hasNext()) 1899 { 1900 final Long value = iterator.next(); 1901 addMonitorAttribute(attrs, 1902 "bindOpsAggrPct-" + lastValue + '-' + value, 1903 INFO_PROCESSING_TIME_DISPNAME_BIND_AGGR_PCT.get(lastValue, value), 1904 INFO_PROCESSING_TIME_DESC_BIND_AGGR_PCT.get(lastValue, value), 1905 bindOpsAggregatePercent.get(lastValue)); 1906 1907 lastValue = value; 1908 } 1909 } 1910 1911 if (compareOpsTotalCount != null) 1912 { 1913 addMonitorAttribute(attrs, 1914 ATTR_COMPARE_TOTAL_COUNT, 1915 INFO_PROCESSING_TIME_DISPNAME_COMPARE_TOTAL_COUNT.get(), 1916 INFO_PROCESSING_TIME_DESC_COMPARE_TOTAL_COUNT.get(), 1917 compareOpsTotalCount); 1918 } 1919 1920 if (compareOpsAvgResponseTimeMillis != null) 1921 { 1922 addMonitorAttribute(attrs, 1923 ATTR_COMPARE_AVERAGE_RESPONSE_TIME_MS, 1924 INFO_PROCESSING_TIME_DISPNAME_COMPARE_TOTAL_TIME.get(), 1925 INFO_PROCESSING_TIME_DESC_COMPARE_TOTAL_TIME.get(), 1926 compareOpsAvgResponseTimeMillis); 1927 } 1928 1929 if (! compareOpsCount.isEmpty()) 1930 { 1931 final Iterator<Long> iterator = compareOpsCount.keySet().iterator(); 1932 Long lastValue = iterator.next(); 1933 1934 while (iterator.hasNext()) 1935 { 1936 final Long value = iterator.next(); 1937 addMonitorAttribute(attrs, 1938 "compareOpsCount-" + lastValue + '-' + value, 1939 INFO_PROCESSING_TIME_DISPNAME_COMPARE_COUNT.get(lastValue, value), 1940 INFO_PROCESSING_TIME_DESC_COMPARE_COUNT.get(lastValue, value), 1941 compareOpsCount.get(lastValue)); 1942 1943 lastValue = value; 1944 if (! iterator.hasNext()) 1945 { 1946 addMonitorAttribute(attrs, 1947 "compareOpsCount-" + lastValue, 1948 INFO_PROCESSING_TIME_DISPNAME_COMPARE_COUNT_LAST.get(lastValue), 1949 INFO_PROCESSING_TIME_DESC_COMPARE_COUNT_LAST.get(lastValue), 1950 compareOpsCount.get(lastValue)); 1951 } 1952 } 1953 } 1954 1955 if (! compareOpsPercent.isEmpty()) 1956 { 1957 final Iterator<Long> iterator = compareOpsPercent.keySet().iterator(); 1958 Long lastValue = iterator.next(); 1959 1960 while (iterator.hasNext()) 1961 { 1962 final Long value = iterator.next(); 1963 addMonitorAttribute(attrs, 1964 "compareOpsPct-" + lastValue + '-' + value, 1965 INFO_PROCESSING_TIME_DISPNAME_COMPARE_PCT.get(lastValue, value), 1966 INFO_PROCESSING_TIME_DESC_COMPARE_PCT.get(lastValue, value), 1967 compareOpsPercent.get(lastValue)); 1968 1969 lastValue = value; 1970 if (! iterator.hasNext()) 1971 { 1972 addMonitorAttribute(attrs, 1973 "compareOpsPct-" + lastValue, 1974 INFO_PROCESSING_TIME_DISPNAME_COMPARE_PCT_LAST.get(lastValue), 1975 INFO_PROCESSING_TIME_DESC_COMPARE_PCT_LAST.get(lastValue), 1976 compareOpsPercent.get(lastValue)); 1977 } 1978 } 1979 } 1980 1981 if (! compareOpsAggregatePercent.isEmpty()) 1982 { 1983 final Iterator<Long> iterator = 1984 compareOpsAggregatePercent.keySet().iterator(); 1985 Long lastValue = iterator.next(); 1986 1987 while (iterator.hasNext()) 1988 { 1989 final Long value = iterator.next(); 1990 addMonitorAttribute(attrs, 1991 "compareOpsAggrPct-" + lastValue + '-' + value, 1992 INFO_PROCESSING_TIME_DISPNAME_COMPARE_AGGR_PCT.get(lastValue, 1993 value), 1994 INFO_PROCESSING_TIME_DESC_COMPARE_AGGR_PCT.get(lastValue, value), 1995 compareOpsAggregatePercent.get(lastValue)); 1996 1997 lastValue = value; 1998 } 1999 } 2000 2001 if (deleteOpsTotalCount != null) 2002 { 2003 addMonitorAttribute(attrs, 2004 ATTR_DELETE_TOTAL_COUNT, 2005 INFO_PROCESSING_TIME_DISPNAME_DELETE_TOTAL_COUNT.get(), 2006 INFO_PROCESSING_TIME_DESC_DELETE_TOTAL_COUNT.get(), 2007 deleteOpsTotalCount); 2008 } 2009 2010 if (deleteOpsAvgResponseTimeMillis != null) 2011 { 2012 addMonitorAttribute(attrs, 2013 ATTR_DELETE_AVERAGE_RESPONSE_TIME_MS, 2014 INFO_PROCESSING_TIME_DISPNAME_DELETE_TOTAL_TIME.get(), 2015 INFO_PROCESSING_TIME_DESC_DELETE_TOTAL_TIME.get(), 2016 deleteOpsAvgResponseTimeMillis); 2017 } 2018 2019 if (! deleteOpsCount.isEmpty()) 2020 { 2021 final Iterator<Long> iterator = deleteOpsCount.keySet().iterator(); 2022 Long lastValue = iterator.next(); 2023 2024 while (iterator.hasNext()) 2025 { 2026 final Long value = iterator.next(); 2027 addMonitorAttribute(attrs, 2028 "deleteOpsCount-" + lastValue + '-' + value, 2029 INFO_PROCESSING_TIME_DISPNAME_DELETE_COUNT.get(lastValue, value), 2030 INFO_PROCESSING_TIME_DESC_DELETE_COUNT.get(lastValue, value), 2031 deleteOpsCount.get(lastValue)); 2032 2033 lastValue = value; 2034 if (! iterator.hasNext()) 2035 { 2036 addMonitorAttribute(attrs, 2037 "deleteOpsCount-" + lastValue, 2038 INFO_PROCESSING_TIME_DISPNAME_DELETE_COUNT_LAST.get(lastValue), 2039 INFO_PROCESSING_TIME_DESC_DELETE_COUNT_LAST.get(lastValue), 2040 deleteOpsCount.get(lastValue)); 2041 } 2042 } 2043 } 2044 2045 if (! deleteOpsPercent.isEmpty()) 2046 { 2047 final Iterator<Long> iterator = deleteOpsPercent.keySet().iterator(); 2048 Long lastValue = iterator.next(); 2049 2050 while (iterator.hasNext()) 2051 { 2052 final Long value = iterator.next(); 2053 addMonitorAttribute(attrs, 2054 "deleteOpsPct-" + lastValue + '-' + value, 2055 INFO_PROCESSING_TIME_DISPNAME_DELETE_PCT.get(lastValue, value), 2056 INFO_PROCESSING_TIME_DESC_DELETE_PCT.get(lastValue, value), 2057 deleteOpsPercent.get(lastValue)); 2058 2059 lastValue = value; 2060 if (! iterator.hasNext()) 2061 { 2062 addMonitorAttribute(attrs, 2063 "deleteOpsPct-" + lastValue, 2064 INFO_PROCESSING_TIME_DISPNAME_DELETE_PCT_LAST.get(lastValue), 2065 INFO_PROCESSING_TIME_DESC_DELETE_PCT_LAST.get(lastValue), 2066 deleteOpsPercent.get(lastValue)); 2067 } 2068 } 2069 } 2070 2071 if (! deleteOpsAggregatePercent.isEmpty()) 2072 { 2073 final Iterator<Long> iterator = 2074 deleteOpsAggregatePercent.keySet().iterator(); 2075 Long lastValue = iterator.next(); 2076 2077 while (iterator.hasNext()) 2078 { 2079 final Long value = iterator.next(); 2080 addMonitorAttribute(attrs, 2081 "deleteOpsAggrPct-" + lastValue + '-' + value, 2082 INFO_PROCESSING_TIME_DISPNAME_DELETE_AGGR_PCT.get(lastValue, 2083 value), 2084 INFO_PROCESSING_TIME_DESC_DELETE_AGGR_PCT.get(lastValue, value), 2085 deleteOpsAggregatePercent.get(lastValue)); 2086 2087 lastValue = value; 2088 } 2089 } 2090 2091 if (extendedOpsTotalCount != null) 2092 { 2093 addMonitorAttribute(attrs, 2094 ATTR_EXTENDED_TOTAL_COUNT, 2095 INFO_PROCESSING_TIME_DISPNAME_EXTENDED_TOTAL_COUNT.get(), 2096 INFO_PROCESSING_TIME_DESC_EXTENDED_TOTAL_COUNT.get(), 2097 extendedOpsTotalCount); 2098 } 2099 2100 if (extendedOpsAvgResponseTimeMillis != null) 2101 { 2102 addMonitorAttribute(attrs, 2103 ATTR_EXTENDED_AVERAGE_RESPONSE_TIME_MS, 2104 INFO_PROCESSING_TIME_DISPNAME_EXTENDED_TOTAL_TIME.get(), 2105 INFO_PROCESSING_TIME_DESC_EXTENDED_TOTAL_TIME.get(), 2106 extendedOpsAvgResponseTimeMillis); 2107 } 2108 2109 if (! extendedOpsCount.isEmpty()) 2110 { 2111 final Iterator<Long> iterator = extendedOpsCount.keySet().iterator(); 2112 Long lastValue = iterator.next(); 2113 2114 while (iterator.hasNext()) 2115 { 2116 final Long value = iterator.next(); 2117 addMonitorAttribute(attrs, 2118 "extendedOpsCount-" + lastValue + '-' + value, 2119 INFO_PROCESSING_TIME_DISPNAME_EXTENDED_COUNT.get(lastValue, value), 2120 INFO_PROCESSING_TIME_DESC_EXTENDED_COUNT.get(lastValue, value), 2121 extendedOpsCount.get(lastValue)); 2122 2123 lastValue = value; 2124 if (! iterator.hasNext()) 2125 { 2126 addMonitorAttribute(attrs, 2127 "extendedOpsCount-" + lastValue, 2128 INFO_PROCESSING_TIME_DISPNAME_EXTENDED_COUNT_LAST.get(lastValue), 2129 INFO_PROCESSING_TIME_DESC_EXTENDED_COUNT_LAST.get(lastValue), 2130 extendedOpsCount.get(lastValue)); 2131 } 2132 } 2133 } 2134 2135 if (! extendedOpsPercent.isEmpty()) 2136 { 2137 final Iterator<Long> iterator = extendedOpsPercent.keySet().iterator(); 2138 Long lastValue = iterator.next(); 2139 2140 while (iterator.hasNext()) 2141 { 2142 final Long value = iterator.next(); 2143 addMonitorAttribute(attrs, 2144 "extendedOpsPct-" + lastValue + '-' + value, 2145 INFO_PROCESSING_TIME_DISPNAME_EXTENDED_PCT.get(lastValue, value), 2146 INFO_PROCESSING_TIME_DESC_EXTENDED_PCT.get(lastValue, value), 2147 extendedOpsPercent.get(lastValue)); 2148 2149 lastValue = value; 2150 if (! iterator.hasNext()) 2151 { 2152 addMonitorAttribute(attrs, 2153 "extendedOpsPct-" + lastValue, 2154 INFO_PROCESSING_TIME_DISPNAME_EXTENDED_PCT_LAST.get(lastValue), 2155 INFO_PROCESSING_TIME_DESC_EXTENDED_PCT_LAST.get(lastValue), 2156 extendedOpsPercent.get(lastValue)); 2157 } 2158 } 2159 } 2160 2161 if (! extendedOpsAggregatePercent.isEmpty()) 2162 { 2163 final Iterator<Long> iterator = 2164 extendedOpsAggregatePercent.keySet().iterator(); 2165 Long lastValue = iterator.next(); 2166 2167 while (iterator.hasNext()) 2168 { 2169 final Long value = iterator.next(); 2170 addMonitorAttribute(attrs, 2171 "extendedOpsAggrPct-" + lastValue + '-' + value, 2172 INFO_PROCESSING_TIME_DISPNAME_EXTENDED_AGGR_PCT.get(lastValue, 2173 value), 2174 INFO_PROCESSING_TIME_DESC_EXTENDED_AGGR_PCT.get(lastValue, value), 2175 extendedOpsAggregatePercent.get(lastValue)); 2176 2177 lastValue = value; 2178 } 2179 } 2180 2181 if (modifyOpsTotalCount != null) 2182 { 2183 addMonitorAttribute(attrs, 2184 ATTR_MODIFY_TOTAL_COUNT, 2185 INFO_PROCESSING_TIME_DISPNAME_MODIFY_TOTAL_COUNT.get(), 2186 INFO_PROCESSING_TIME_DESC_MODIFY_TOTAL_COUNT.get(), 2187 modifyOpsTotalCount); 2188 } 2189 2190 if (modifyOpsAvgResponseTimeMillis != null) 2191 { 2192 addMonitorAttribute(attrs, 2193 ATTR_MODIFY_AVERAGE_RESPONSE_TIME_MS, 2194 INFO_PROCESSING_TIME_DISPNAME_MODIFY_TOTAL_TIME.get(), 2195 INFO_PROCESSING_TIME_DESC_MODIFY_TOTAL_TIME.get(), 2196 modifyOpsAvgResponseTimeMillis); 2197 } 2198 2199 if (! modifyOpsCount.isEmpty()) 2200 { 2201 final Iterator<Long> iterator = modifyOpsCount.keySet().iterator(); 2202 Long lastValue = iterator.next(); 2203 2204 while (iterator.hasNext()) 2205 { 2206 final Long value = iterator.next(); 2207 addMonitorAttribute(attrs, 2208 "modifyOpsCount-" + lastValue + '-' + value, 2209 INFO_PROCESSING_TIME_DISPNAME_MODIFY_COUNT.get(lastValue, value), 2210 INFO_PROCESSING_TIME_DESC_MODIFY_COUNT.get(lastValue, value), 2211 modifyOpsCount.get(lastValue)); 2212 2213 lastValue = value; 2214 if (! iterator.hasNext()) 2215 { 2216 addMonitorAttribute(attrs, 2217 "modifyOpsCount-" + lastValue, 2218 INFO_PROCESSING_TIME_DISPNAME_MODIFY_COUNT_LAST.get(lastValue), 2219 INFO_PROCESSING_TIME_DESC_MODIFY_COUNT_LAST.get(lastValue), 2220 modifyOpsCount.get(lastValue)); 2221 } 2222 } 2223 } 2224 2225 if (! modifyOpsPercent.isEmpty()) 2226 { 2227 final Iterator<Long> iterator = modifyOpsPercent.keySet().iterator(); 2228 Long lastValue = iterator.next(); 2229 2230 while (iterator.hasNext()) 2231 { 2232 final Long value = iterator.next(); 2233 addMonitorAttribute(attrs, 2234 "modifyOpsPct-" + lastValue + '-' + value, 2235 INFO_PROCESSING_TIME_DISPNAME_MODIFY_PCT.get(lastValue, value), 2236 INFO_PROCESSING_TIME_DESC_MODIFY_PCT.get(lastValue, value), 2237 modifyOpsPercent.get(lastValue)); 2238 2239 lastValue = value; 2240 if (! iterator.hasNext()) 2241 { 2242 addMonitorAttribute(attrs, 2243 "modifyOpsPct-" + lastValue, 2244 INFO_PROCESSING_TIME_DISPNAME_MODIFY_PCT_LAST.get(lastValue), 2245 INFO_PROCESSING_TIME_DESC_MODIFY_PCT_LAST.get(lastValue), 2246 modifyOpsPercent.get(lastValue)); 2247 } 2248 } 2249 } 2250 2251 if (! modifyOpsAggregatePercent.isEmpty()) 2252 { 2253 final Iterator<Long> iterator = 2254 modifyOpsAggregatePercent.keySet().iterator(); 2255 Long lastValue = iterator.next(); 2256 2257 while (iterator.hasNext()) 2258 { 2259 final Long value = iterator.next(); 2260 addMonitorAttribute(attrs, 2261 "modifyOpsAggrPct-" + lastValue + '-' + value, 2262 INFO_PROCESSING_TIME_DISPNAME_MODIFY_AGGR_PCT.get(lastValue, 2263 value), 2264 INFO_PROCESSING_TIME_DESC_MODIFY_AGGR_PCT.get(lastValue, value), 2265 modifyOpsAggregatePercent.get(lastValue)); 2266 2267 lastValue = value; 2268 } 2269 } 2270 2271 if (modifyDNOpsTotalCount != null) 2272 { 2273 addMonitorAttribute(attrs, 2274 ATTR_MODIFY_DN_TOTAL_COUNT, 2275 INFO_PROCESSING_TIME_DISPNAME_MODIFY_DN_TOTAL_COUNT.get(), 2276 INFO_PROCESSING_TIME_DESC_MODIFY_DN_TOTAL_COUNT.get(), 2277 modifyDNOpsTotalCount); 2278 } 2279 2280 if (modifyDNOpsAvgResponseTimeMillis != null) 2281 { 2282 addMonitorAttribute(attrs, 2283 ATTR_MODIFY_DN_AVERAGE_RESPONSE_TIME_MS, 2284 INFO_PROCESSING_TIME_DISPNAME_MODIFY_DN_TOTAL_TIME.get(), 2285 INFO_PROCESSING_TIME_DESC_MODIFY_DN_TOTAL_TIME.get(), 2286 modifyDNOpsAvgResponseTimeMillis); 2287 } 2288 2289 if (! modifyDNOpsCount.isEmpty()) 2290 { 2291 final Iterator<Long> iterator = modifyDNOpsCount.keySet().iterator(); 2292 Long lastValue = iterator.next(); 2293 2294 while (iterator.hasNext()) 2295 { 2296 final Long value = iterator.next(); 2297 addMonitorAttribute(attrs, 2298 "modifyDNOpsCount-" + lastValue + '-' + value, 2299 INFO_PROCESSING_TIME_DISPNAME_MODIFY_DN_COUNT.get(lastValue, 2300 value), 2301 INFO_PROCESSING_TIME_DESC_MODIFY_DN_COUNT.get(lastValue, value), 2302 modifyDNOpsCount.get(lastValue)); 2303 2304 lastValue = value; 2305 if (! iterator.hasNext()) 2306 { 2307 addMonitorAttribute(attrs, 2308 "modifyDNOpsCount-" + lastValue, 2309 INFO_PROCESSING_TIME_DISPNAME_MODIFY_DN_COUNT_LAST.get( 2310 lastValue), 2311 INFO_PROCESSING_TIME_DESC_MODIFY_DN_COUNT_LAST.get(lastValue), 2312 modifyDNOpsCount.get(lastValue)); 2313 } 2314 } 2315 } 2316 2317 if (! modifyDNOpsPercent.isEmpty()) 2318 { 2319 final Iterator<Long> iterator = modifyDNOpsPercent.keySet().iterator(); 2320 Long lastValue = iterator.next(); 2321 2322 while (iterator.hasNext()) 2323 { 2324 final Long value = iterator.next(); 2325 addMonitorAttribute(attrs, 2326 "modifyDNOpsPct-" + lastValue + '-' + value, 2327 INFO_PROCESSING_TIME_DISPNAME_MODIFY_DN_PCT.get(lastValue, value), 2328 INFO_PROCESSING_TIME_DESC_MODIFY_DN_PCT.get(lastValue, value), 2329 modifyDNOpsPercent.get(lastValue)); 2330 2331 lastValue = value; 2332 if (! iterator.hasNext()) 2333 { 2334 addMonitorAttribute(attrs, 2335 "modifyDNOpsPct-" + lastValue, 2336 INFO_PROCESSING_TIME_DISPNAME_MODIFY_DN_PCT_LAST.get(lastValue), 2337 INFO_PROCESSING_TIME_DESC_MODIFY_DN_PCT_LAST.get(lastValue), 2338 modifyDNOpsPercent.get(lastValue)); 2339 } 2340 } 2341 } 2342 2343 if (! modifyDNOpsAggregatePercent.isEmpty()) 2344 { 2345 final Iterator<Long> iterator = 2346 modifyDNOpsAggregatePercent.keySet().iterator(); 2347 Long lastValue = iterator.next(); 2348 2349 while (iterator.hasNext()) 2350 { 2351 final Long value = iterator.next(); 2352 addMonitorAttribute(attrs, 2353 "modifyDNOpsAggrPct-" + lastValue + '-' + value, 2354 INFO_PROCESSING_TIME_DISPNAME_MODIFY_DN_AGGR_PCT.get(lastValue, 2355 value), 2356 INFO_PROCESSING_TIME_DESC_MODIFY_DN_AGGR_PCT.get(lastValue, value), 2357 modifyDNOpsAggregatePercent.get(lastValue)); 2358 2359 lastValue = value; 2360 } 2361 } 2362 2363 if (searchOpsTotalCount != null) 2364 { 2365 addMonitorAttribute(attrs, 2366 ATTR_SEARCH_TOTAL_COUNT, 2367 INFO_PROCESSING_TIME_DISPNAME_SEARCH_TOTAL_COUNT.get(), 2368 INFO_PROCESSING_TIME_DESC_SEARCH_TOTAL_COUNT.get(), 2369 searchOpsTotalCount); 2370 } 2371 2372 if (searchOpsAvgResponseTimeMillis != null) 2373 { 2374 addMonitorAttribute(attrs, 2375 ATTR_SEARCH_AVERAGE_RESPONSE_TIME_MS, 2376 INFO_PROCESSING_TIME_DISPNAME_SEARCH_TOTAL_TIME.get(), 2377 INFO_PROCESSING_TIME_DESC_SEARCH_TOTAL_TIME.get(), 2378 searchOpsAvgResponseTimeMillis); 2379 } 2380 2381 if (! searchOpsCount.isEmpty()) 2382 { 2383 final Iterator<Long> iterator = searchOpsCount.keySet().iterator(); 2384 Long lastValue = iterator.next(); 2385 2386 while (iterator.hasNext()) 2387 { 2388 final Long value = iterator.next(); 2389 addMonitorAttribute(attrs, 2390 "searchOpsCount-" + lastValue + '-' + value, 2391 INFO_PROCESSING_TIME_DISPNAME_SEARCH_COUNT.get(lastValue, value), 2392 INFO_PROCESSING_TIME_DESC_SEARCH_COUNT.get(lastValue, value), 2393 searchOpsCount.get(lastValue)); 2394 2395 lastValue = value; 2396 if (! iterator.hasNext()) 2397 { 2398 addMonitorAttribute(attrs, 2399 "searchOpsCount-" + lastValue, 2400 INFO_PROCESSING_TIME_DISPNAME_SEARCH_COUNT_LAST.get(lastValue), 2401 INFO_PROCESSING_TIME_DESC_SEARCH_COUNT_LAST.get(lastValue), 2402 searchOpsCount.get(lastValue)); 2403 } 2404 } 2405 } 2406 2407 if (! searchOpsPercent.isEmpty()) 2408 { 2409 final Iterator<Long> iterator = searchOpsPercent.keySet().iterator(); 2410 Long lastValue = iterator.next(); 2411 2412 while (iterator.hasNext()) 2413 { 2414 final Long value = iterator.next(); 2415 addMonitorAttribute(attrs, 2416 "searchOpsPct-" + lastValue + '-' + value, 2417 INFO_PROCESSING_TIME_DISPNAME_SEARCH_PCT.get(lastValue, value), 2418 INFO_PROCESSING_TIME_DESC_SEARCH_PCT.get(lastValue, value), 2419 searchOpsPercent.get(lastValue)); 2420 2421 lastValue = value; 2422 if (! iterator.hasNext()) 2423 { 2424 addMonitorAttribute(attrs, 2425 "searchOpsPct-" + lastValue, 2426 INFO_PROCESSING_TIME_DISPNAME_SEARCH_PCT_LAST.get(lastValue), 2427 INFO_PROCESSING_TIME_DESC_SEARCH_PCT_LAST.get(lastValue), 2428 searchOpsPercent.get(lastValue)); 2429 } 2430 } 2431 } 2432 2433 if (! searchOpsAggregatePercent.isEmpty()) 2434 { 2435 final Iterator<Long> iterator = 2436 searchOpsAggregatePercent.keySet().iterator(); 2437 Long lastValue = iterator.next(); 2438 2439 while (iterator.hasNext()) 2440 { 2441 final Long value = iterator.next(); 2442 addMonitorAttribute(attrs, 2443 "searchOpsAggrPct-" + lastValue + '-' + value, 2444 INFO_PROCESSING_TIME_DISPNAME_SEARCH_AGGR_PCT.get(lastValue, 2445 value), 2446 INFO_PROCESSING_TIME_DESC_SEARCH_AGGR_PCT.get(lastValue, value), 2447 searchOpsAggregatePercent.get(lastValue)); 2448 2449 lastValue = value; 2450 } 2451 } 2452 2453 return Collections.unmodifiableMap(attrs); 2454 } 2455}