001/* 002 * CDDL HEADER START 003 * 004 * The contents of this file are subject to the terms of the 005 * Common Development and Distribution License, Version 1.0 only 006 * (the "License"). You may not use this file except in compliance 007 * with the License. 008 * 009 * You can obtain a copy of the license at legal-notices/CDDLv1_0.txt 010 * or http://forgerock.org/license/CDDLv1.0.html. 011 * See the License for the specific language governing permissions 012 * and limitations under the License. 013 * 014 * When distributing Covered Code, include this CDDL HEADER in each 015 * file and include the License file at legal-notices/CDDLv1_0.txt. 016 * If applicable, add the following below this CDDL HEADER, with the 017 * fields enclosed by brackets "[]" replaced with your own identifying 018 * information: 019 * Portions Copyright [yyyy] [name of copyright owner] 020 * 021 * CDDL HEADER END 022 * 023 * 024 * Copyright 2008 Sun Microsystems, Inc. 025 */ 026package org.forgerock.opendj.server.config.meta; 027 028 029 030import java.util.Collection; 031import java.util.SortedSet; 032import org.forgerock.opendj.config.AdministratorAction; 033import org.forgerock.opendj.config.BooleanPropertyDefinition; 034import org.forgerock.opendj.config.ClassPropertyDefinition; 035import org.forgerock.opendj.config.client.ConcurrentModificationException; 036import org.forgerock.opendj.config.client.ManagedObject; 037import org.forgerock.opendj.config.client.MissingMandatoryPropertiesException; 038import org.forgerock.opendj.config.client.OperationRejectedException; 039import org.forgerock.opendj.config.DefaultBehaviorProvider; 040import org.forgerock.opendj.config.DefinedDefaultBehaviorProvider; 041import org.forgerock.opendj.config.DurationPropertyDefinition; 042import org.forgerock.opendj.config.EnumPropertyDefinition; 043import org.forgerock.opendj.config.ManagedObjectAlreadyExistsException; 044import org.forgerock.opendj.config.ManagedObjectDefinition; 045import org.forgerock.opendj.config.PropertyOption; 046import org.forgerock.opendj.config.PropertyProvider; 047import org.forgerock.opendj.config.server.ConfigurationChangeListener; 048import org.forgerock.opendj.config.server.ServerManagedObject; 049import org.forgerock.opendj.config.StringPropertyDefinition; 050import org.forgerock.opendj.config.Tag; 051import org.forgerock.opendj.config.UndefinedDefaultBehaviorProvider; 052import org.forgerock.opendj.ldap.DN; 053import org.forgerock.opendj.ldap.LdapException; 054import org.forgerock.opendj.server.config.client.ProfilerPluginCfgClient; 055import org.forgerock.opendj.server.config.meta.PluginCfgDefn.PluginType; 056import org.forgerock.opendj.server.config.server.PluginCfg; 057import org.forgerock.opendj.server.config.server.ProfilerPluginCfg; 058 059 060 061/** 062 * An interface for querying the Profiler Plugin managed object 063 * definition meta information. 064 * <p> 065 * The Profiler plug-in captures profiling information about 066 * operations performed inside the JVM while the OpenDJ directory 067 * server is running. 068 */ 069public final class ProfilerPluginCfgDefn extends ManagedObjectDefinition<ProfilerPluginCfgClient, ProfilerPluginCfg> { 070 071 /** The singleton configuration definition instance. */ 072 private static final ProfilerPluginCfgDefn INSTANCE = new ProfilerPluginCfgDefn(); 073 074 075 076 /** 077 * Defines the set of permissable values for the "profile-action" property. 078 * <p> 079 * Specifies the action that should be taken by the profiler. 080 * <p> 081 * A value of "start" causes the profiler thread to start collecting 082 * data if it is not already active. A value of "stop" causes the 083 * profiler thread to stop collecting data and write it to disk, and 084 * a value of "cancel" causes the profiler thread to stop collecting 085 * data and discard anything that has been captured. These operations 086 * occur immediately. 087 */ 088 public static enum ProfileAction { 089 090 /** 091 * Stop collecting profile data and discard what has been 092 * captured. 093 */ 094 CANCEL("cancel"), 095 096 097 098 /** 099 * Do not take any action. 100 */ 101 NONE("none"), 102 103 104 105 /** 106 * Start collecting profile data. 107 */ 108 START("start"), 109 110 111 112 /** 113 * Stop collecting profile data and write what has been captured 114 * to a file in the profile directory. 115 */ 116 STOP("stop"); 117 118 119 120 /** String representation of the value. */ 121 private final String name; 122 123 124 125 /** Private constructor. */ 126 private ProfileAction(String name) { this.name = name; } 127 128 129 130 /** {@inheritDoc} */ 131 public String toString() { return name; } 132 133 } 134 135 136 137 /** The "enable-profiling-on-startup" property definition. */ 138 private static final BooleanPropertyDefinition PD_ENABLE_PROFILING_ON_STARTUP; 139 140 141 142 /** The "invoke-for-internal-operations" property definition. */ 143 private static final BooleanPropertyDefinition PD_INVOKE_FOR_INTERNAL_OPERATIONS; 144 145 146 147 /** The "java-class" property definition. */ 148 private static final ClassPropertyDefinition PD_JAVA_CLASS; 149 150 151 152 /** The "plugin-type" property definition. */ 153 private static final EnumPropertyDefinition<PluginType> PD_PLUGIN_TYPE; 154 155 156 157 /** The "profile-action" property definition. */ 158 private static final EnumPropertyDefinition<ProfileAction> PD_PROFILE_ACTION; 159 160 161 162 /** The "profile-directory" property definition. */ 163 private static final StringPropertyDefinition PD_PROFILE_DIRECTORY; 164 165 166 167 /** The "profile-sample-interval" property definition. */ 168 private static final DurationPropertyDefinition PD_PROFILE_SAMPLE_INTERVAL; 169 170 171 172 /** Build the "enable-profiling-on-startup" property definition. */ 173 static { 174 BooleanPropertyDefinition.Builder builder = BooleanPropertyDefinition.createBuilder(INSTANCE, "enable-profiling-on-startup"); 175 builder.setOption(PropertyOption.MANDATORY); 176 builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "enable-profiling-on-startup")); 177 builder.setDefaultBehaviorProvider(new UndefinedDefaultBehaviorProvider<Boolean>()); 178 PD_ENABLE_PROFILING_ON_STARTUP = builder.getInstance(); 179 INSTANCE.registerPropertyDefinition(PD_ENABLE_PROFILING_ON_STARTUP); 180 } 181 182 183 184 /** Build the "invoke-for-internal-operations" property definition. */ 185 static { 186 BooleanPropertyDefinition.Builder builder = BooleanPropertyDefinition.createBuilder(INSTANCE, "invoke-for-internal-operations"); 187 builder.setOption(PropertyOption.ADVANCED); 188 builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "invoke-for-internal-operations")); 189 DefaultBehaviorProvider<Boolean> provider = new DefinedDefaultBehaviorProvider<Boolean>("false"); 190 builder.setDefaultBehaviorProvider(provider); 191 PD_INVOKE_FOR_INTERNAL_OPERATIONS = builder.getInstance(); 192 INSTANCE.registerPropertyDefinition(PD_INVOKE_FOR_INTERNAL_OPERATIONS); 193 } 194 195 196 197 /** Build the "java-class" property definition. */ 198 static { 199 ClassPropertyDefinition.Builder builder = ClassPropertyDefinition.createBuilder(INSTANCE, "java-class"); 200 builder.setOption(PropertyOption.MANDATORY); 201 builder.setOption(PropertyOption.ADVANCED); 202 builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "java-class")); 203 DefaultBehaviorProvider<String> provider = new DefinedDefaultBehaviorProvider<String>("org.opends.server.plugins.profiler.ProfilerPlugin"); 204 builder.setDefaultBehaviorProvider(provider); 205 builder.addInstanceOf("org.opends.server.api.plugin.DirectoryServerPlugin"); 206 PD_JAVA_CLASS = builder.getInstance(); 207 INSTANCE.registerPropertyDefinition(PD_JAVA_CLASS); 208 } 209 210 211 212 /** Build the "plugin-type" property definition. */ 213 static { 214 EnumPropertyDefinition.Builder<PluginType> builder = EnumPropertyDefinition.createBuilder(INSTANCE, "plugin-type"); 215 builder.setOption(PropertyOption.MULTI_VALUED); 216 builder.setOption(PropertyOption.MANDATORY); 217 builder.setOption(PropertyOption.ADVANCED); 218 builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.COMPONENT_RESTART, INSTANCE, "plugin-type")); 219 DefaultBehaviorProvider<PluginType> provider = new DefinedDefaultBehaviorProvider<PluginType>("startup"); 220 builder.setDefaultBehaviorProvider(provider); 221 builder.setEnumClass(PluginType.class); 222 PD_PLUGIN_TYPE = builder.getInstance(); 223 INSTANCE.registerPropertyDefinition(PD_PLUGIN_TYPE); 224 } 225 226 227 228 /** Build the "profile-action" property definition. */ 229 static { 230 EnumPropertyDefinition.Builder<ProfileAction> builder = EnumPropertyDefinition.createBuilder(INSTANCE, "profile-action"); 231 builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "profile-action")); 232 DefaultBehaviorProvider<ProfileAction> provider = new DefinedDefaultBehaviorProvider<ProfileAction>("none"); 233 builder.setDefaultBehaviorProvider(provider); 234 builder.setEnumClass(ProfileAction.class); 235 PD_PROFILE_ACTION = builder.getInstance(); 236 INSTANCE.registerPropertyDefinition(PD_PROFILE_ACTION); 237 } 238 239 240 241 /** Build the "profile-directory" property definition. */ 242 static { 243 StringPropertyDefinition.Builder builder = StringPropertyDefinition.createBuilder(INSTANCE, "profile-directory"); 244 builder.setOption(PropertyOption.MANDATORY); 245 builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "profile-directory")); 246 builder.setDefaultBehaviorProvider(new UndefinedDefaultBehaviorProvider<String>()); 247 builder.setPattern(".*", "DIR"); 248 PD_PROFILE_DIRECTORY = builder.getInstance(); 249 INSTANCE.registerPropertyDefinition(PD_PROFILE_DIRECTORY); 250 } 251 252 253 254 /** Build the "profile-sample-interval" property definition. */ 255 static { 256 DurationPropertyDefinition.Builder builder = DurationPropertyDefinition.createBuilder(INSTANCE, "profile-sample-interval"); 257 builder.setOption(PropertyOption.MANDATORY); 258 builder.setAdministratorAction(new AdministratorAction(AdministratorAction.Type.NONE, INSTANCE, "profile-sample-interval")); 259 builder.setDefaultBehaviorProvider(new UndefinedDefaultBehaviorProvider<Long>()); 260 builder.setBaseUnit("ms"); 261 builder.setUpperLimit("2147483647"); 262 builder.setLowerLimit("1"); 263 PD_PROFILE_SAMPLE_INTERVAL = builder.getInstance(); 264 INSTANCE.registerPropertyDefinition(PD_PROFILE_SAMPLE_INTERVAL); 265 } 266 267 268 269 // Register the tags associated with this managed object definition. 270 static { 271 INSTANCE.registerTag(Tag.valueOf("core-server")); 272 } 273 274 275 276 /** 277 * Get the Profiler Plugin configuration definition singleton. 278 * 279 * @return Returns the Profiler Plugin configuration definition 280 * singleton. 281 */ 282 public static ProfilerPluginCfgDefn getInstance() { 283 return INSTANCE; 284 } 285 286 287 288 /** 289 * Private constructor. 290 */ 291 private ProfilerPluginCfgDefn() { 292 super("profiler-plugin", PluginCfgDefn.getInstance()); 293 } 294 295 296 297 /** {@inheritDoc} */ 298 public ProfilerPluginCfgClient createClientConfiguration( 299 ManagedObject<? extends ProfilerPluginCfgClient> impl) { 300 return new ProfilerPluginCfgClientImpl(impl); 301 } 302 303 304 305 /** {@inheritDoc} */ 306 public ProfilerPluginCfg createServerConfiguration( 307 ServerManagedObject<? extends ProfilerPluginCfg> impl) { 308 return new ProfilerPluginCfgServerImpl(impl); 309 } 310 311 312 313 /** {@inheritDoc} */ 314 public Class<ProfilerPluginCfg> getServerConfigurationClass() { 315 return ProfilerPluginCfg.class; 316 } 317 318 319 320 /** 321 * Get the "enabled" property definition. 322 * <p> 323 * Indicates whether the plug-in is enabled for use. 324 * 325 * @return Returns the "enabled" property definition. 326 */ 327 public BooleanPropertyDefinition getEnabledPropertyDefinition() { 328 return PluginCfgDefn.getInstance().getEnabledPropertyDefinition(); 329 } 330 331 332 333 /** 334 * Get the "enable-profiling-on-startup" property definition. 335 * <p> 336 * Indicates whether the profiler plug-in is to start collecting 337 * data automatically when the directory server is started. 338 * <p> 339 * This property is read only when the server is started, and any 340 * changes take effect on the next restart. This property is 341 * typically set to "false" unless startup profiling is required, 342 * because otherwise the volume of data that can be collected can 343 * cause the server to run out of memory if it is not turned off in a 344 * timely manner. 345 * 346 * @return Returns the "enable-profiling-on-startup" property definition. 347 */ 348 public BooleanPropertyDefinition getEnableProfilingOnStartupPropertyDefinition() { 349 return PD_ENABLE_PROFILING_ON_STARTUP; 350 } 351 352 353 354 /** 355 * Get the "invoke-for-internal-operations" property definition. 356 * <p> 357 * Indicates whether the plug-in should be invoked for internal 358 * operations. 359 * <p> 360 * Any plug-in that can be invoked for internal operations must 361 * ensure that it does not create any new internal operatons that can 362 * cause the same plug-in to be re-invoked. 363 * 364 * @return Returns the "invoke-for-internal-operations" property definition. 365 */ 366 public BooleanPropertyDefinition getInvokeForInternalOperationsPropertyDefinition() { 367 return PD_INVOKE_FOR_INTERNAL_OPERATIONS; 368 } 369 370 371 372 /** 373 * Get the "java-class" property definition. 374 * <p> 375 * Specifies the fully-qualified name of the Java class that 376 * provides the plug-in implementation. 377 * 378 * @return Returns the "java-class" property definition. 379 */ 380 public ClassPropertyDefinition getJavaClassPropertyDefinition() { 381 return PD_JAVA_CLASS; 382 } 383 384 385 386 /** 387 * Get the "plugin-type" property definition. 388 * <p> 389 * Specifies the set of plug-in types for the plug-in, which 390 * specifies the times at which the plug-in is invoked. 391 * 392 * @return Returns the "plugin-type" property definition. 393 */ 394 public EnumPropertyDefinition<PluginType> getPluginTypePropertyDefinition() { 395 return PD_PLUGIN_TYPE; 396 } 397 398 399 400 /** 401 * Get the "profile-action" property definition. 402 * <p> 403 * Specifies the action that should be taken by the profiler. 404 * <p> 405 * A value of "start" causes the profiler thread to start collecting 406 * data if it is not already active. A value of "stop" causes the 407 * profiler thread to stop collecting data and write it to disk, and 408 * a value of "cancel" causes the profiler thread to stop collecting 409 * data and discard anything that has been captured. These operations 410 * occur immediately. 411 * 412 * @return Returns the "profile-action" property definition. 413 */ 414 public EnumPropertyDefinition<ProfileAction> getProfileActionPropertyDefinition() { 415 return PD_PROFILE_ACTION; 416 } 417 418 419 420 /** 421 * Get the "profile-directory" property definition. 422 * <p> 423 * Specifies the path to the directory where profile information is 424 * to be written. This path may be either an absolute path or a path 425 * that is relative to the root of the OpenDJ directory server 426 * instance. 427 * <p> 428 * The directory must exist and the directory server must have 429 * permission to create new files in it. 430 * 431 * @return Returns the "profile-directory" property definition. 432 */ 433 public StringPropertyDefinition getProfileDirectoryPropertyDefinition() { 434 return PD_PROFILE_DIRECTORY; 435 } 436 437 438 439 /** 440 * Get the "profile-sample-interval" property definition. 441 * <p> 442 * Specifies the sample interval in milliseconds to be used when 443 * capturing profiling information in the server. 444 * <p> 445 * When capturing data, the profiler thread sleeps for this length 446 * of time between calls to obtain traces for all threads running in 447 * the JVM. 448 * 449 * @return Returns the "profile-sample-interval" property definition. 450 */ 451 public DurationPropertyDefinition getProfileSampleIntervalPropertyDefinition() { 452 return PD_PROFILE_SAMPLE_INTERVAL; 453 } 454 455 456 457 /** 458 * Managed object client implementation. 459 */ 460 private static class ProfilerPluginCfgClientImpl implements 461 ProfilerPluginCfgClient { 462 463 /** Private implementation. */ 464 private ManagedObject<? extends ProfilerPluginCfgClient> impl; 465 466 467 468 /** Private constructor. */ 469 private ProfilerPluginCfgClientImpl( 470 ManagedObject<? extends ProfilerPluginCfgClient> impl) { 471 this.impl = impl; 472 } 473 474 475 476 /** {@inheritDoc} */ 477 public Boolean isEnabled() { 478 return impl.getPropertyValue(INSTANCE.getEnabledPropertyDefinition()); 479 } 480 481 482 483 /** {@inheritDoc} */ 484 public void setEnabled(boolean value) { 485 impl.setPropertyValue(INSTANCE.getEnabledPropertyDefinition(), value); 486 } 487 488 489 490 /** {@inheritDoc} */ 491 public Boolean isEnableProfilingOnStartup() { 492 return impl.getPropertyValue(INSTANCE.getEnableProfilingOnStartupPropertyDefinition()); 493 } 494 495 496 497 /** {@inheritDoc} */ 498 public void setEnableProfilingOnStartup(boolean value) { 499 impl.setPropertyValue(INSTANCE.getEnableProfilingOnStartupPropertyDefinition(), value); 500 } 501 502 503 504 /** {@inheritDoc} */ 505 public boolean isInvokeForInternalOperations() { 506 return impl.getPropertyValue(INSTANCE.getInvokeForInternalOperationsPropertyDefinition()); 507 } 508 509 510 511 /** {@inheritDoc} */ 512 public void setInvokeForInternalOperations(Boolean value) { 513 impl.setPropertyValue(INSTANCE.getInvokeForInternalOperationsPropertyDefinition(), value); 514 } 515 516 517 518 /** {@inheritDoc} */ 519 public String getJavaClass() { 520 return impl.getPropertyValue(INSTANCE.getJavaClassPropertyDefinition()); 521 } 522 523 524 525 /** {@inheritDoc} */ 526 public void setJavaClass(String value) { 527 impl.setPropertyValue(INSTANCE.getJavaClassPropertyDefinition(), value); 528 } 529 530 531 532 /** {@inheritDoc} */ 533 public SortedSet<PluginType> getPluginType() { 534 return impl.getPropertyValues(INSTANCE.getPluginTypePropertyDefinition()); 535 } 536 537 538 539 /** {@inheritDoc} */ 540 public void setPluginType(Collection<PluginType> values) { 541 impl.setPropertyValues(INSTANCE.getPluginTypePropertyDefinition(), values); 542 } 543 544 545 546 /** {@inheritDoc} */ 547 public ProfileAction getProfileAction() { 548 return impl.getPropertyValue(INSTANCE.getProfileActionPropertyDefinition()); 549 } 550 551 552 553 /** {@inheritDoc} */ 554 public void setProfileAction(ProfileAction value) { 555 impl.setPropertyValue(INSTANCE.getProfileActionPropertyDefinition(), value); 556 } 557 558 559 560 /** {@inheritDoc} */ 561 public String getProfileDirectory() { 562 return impl.getPropertyValue(INSTANCE.getProfileDirectoryPropertyDefinition()); 563 } 564 565 566 567 /** {@inheritDoc} */ 568 public void setProfileDirectory(String value) { 569 impl.setPropertyValue(INSTANCE.getProfileDirectoryPropertyDefinition(), value); 570 } 571 572 573 574 /** {@inheritDoc} */ 575 public Long getProfileSampleInterval() { 576 return impl.getPropertyValue(INSTANCE.getProfileSampleIntervalPropertyDefinition()); 577 } 578 579 580 581 /** {@inheritDoc} */ 582 public void setProfileSampleInterval(long value) { 583 impl.setPropertyValue(INSTANCE.getProfileSampleIntervalPropertyDefinition(), value); 584 } 585 586 587 588 /** {@inheritDoc} */ 589 public ManagedObjectDefinition<? extends ProfilerPluginCfgClient, ? extends ProfilerPluginCfg> definition() { 590 return INSTANCE; 591 } 592 593 594 595 /** {@inheritDoc} */ 596 public PropertyProvider properties() { 597 return impl; 598 } 599 600 601 602 /** {@inheritDoc} */ 603 public void commit() throws ManagedObjectAlreadyExistsException, 604 MissingMandatoryPropertiesException, ConcurrentModificationException, 605 OperationRejectedException, LdapException { 606 impl.commit(); 607 } 608 609 610 611 /** {@inheritDoc} */ 612 public String toString() { 613 return impl.toString(); 614 } 615 } 616 617 618 619 /** 620 * Managed object server implementation. 621 */ 622 private static class ProfilerPluginCfgServerImpl implements 623 ProfilerPluginCfg { 624 625 /** Private implementation. */ 626 private ServerManagedObject<? extends ProfilerPluginCfg> impl; 627 628 /** The value of the "enabled" property. */ 629 private final boolean pEnabled; 630 631 /** The value of the "enable-profiling-on-startup" property. */ 632 private final boolean pEnableProfilingOnStartup; 633 634 /** The value of the "invoke-for-internal-operations" property. */ 635 private final boolean pInvokeForInternalOperations; 636 637 /** The value of the "java-class" property. */ 638 private final String pJavaClass; 639 640 /** The value of the "plugin-type" property. */ 641 private final SortedSet<PluginType> pPluginType; 642 643 /** The value of the "profile-action" property. */ 644 private final ProfileAction pProfileAction; 645 646 /** The value of the "profile-directory" property. */ 647 private final String pProfileDirectory; 648 649 /** The value of the "profile-sample-interval" property. */ 650 private final long pProfileSampleInterval; 651 652 653 654 /** Private constructor. */ 655 private ProfilerPluginCfgServerImpl(ServerManagedObject<? extends ProfilerPluginCfg> impl) { 656 this.impl = impl; 657 this.pEnabled = impl.getPropertyValue(INSTANCE.getEnabledPropertyDefinition()); 658 this.pEnableProfilingOnStartup = impl.getPropertyValue(INSTANCE.getEnableProfilingOnStartupPropertyDefinition()); 659 this.pInvokeForInternalOperations = impl.getPropertyValue(INSTANCE.getInvokeForInternalOperationsPropertyDefinition()); 660 this.pJavaClass = impl.getPropertyValue(INSTANCE.getJavaClassPropertyDefinition()); 661 this.pPluginType = impl.getPropertyValues(INSTANCE.getPluginTypePropertyDefinition()); 662 this.pProfileAction = impl.getPropertyValue(INSTANCE.getProfileActionPropertyDefinition()); 663 this.pProfileDirectory = impl.getPropertyValue(INSTANCE.getProfileDirectoryPropertyDefinition()); 664 this.pProfileSampleInterval = impl.getPropertyValue(INSTANCE.getProfileSampleIntervalPropertyDefinition()); 665 } 666 667 668 669 /** {@inheritDoc} */ 670 public void addProfilerChangeListener( 671 ConfigurationChangeListener<ProfilerPluginCfg> listener) { 672 impl.registerChangeListener(listener); 673 } 674 675 676 677 /** {@inheritDoc} */ 678 public void removeProfilerChangeListener( 679 ConfigurationChangeListener<ProfilerPluginCfg> listener) { 680 impl.deregisterChangeListener(listener); 681 } 682 /** {@inheritDoc} */ 683 public void addChangeListener( 684 ConfigurationChangeListener<PluginCfg> listener) { 685 impl.registerChangeListener(listener); 686 } 687 688 689 690 /** {@inheritDoc} */ 691 public void removeChangeListener( 692 ConfigurationChangeListener<PluginCfg> listener) { 693 impl.deregisterChangeListener(listener); 694 } 695 696 697 698 /** {@inheritDoc} */ 699 public boolean isEnabled() { 700 return pEnabled; 701 } 702 703 704 705 /** {@inheritDoc} */ 706 public boolean isEnableProfilingOnStartup() { 707 return pEnableProfilingOnStartup; 708 } 709 710 711 712 /** {@inheritDoc} */ 713 public boolean isInvokeForInternalOperations() { 714 return pInvokeForInternalOperations; 715 } 716 717 718 719 /** {@inheritDoc} */ 720 public String getJavaClass() { 721 return pJavaClass; 722 } 723 724 725 726 /** {@inheritDoc} */ 727 public SortedSet<PluginType> getPluginType() { 728 return pPluginType; 729 } 730 731 732 733 /** {@inheritDoc} */ 734 public ProfileAction getProfileAction() { 735 return pProfileAction; 736 } 737 738 739 740 /** {@inheritDoc} */ 741 public String getProfileDirectory() { 742 return pProfileDirectory; 743 } 744 745 746 747 /** {@inheritDoc} */ 748 public long getProfileSampleInterval() { 749 return pProfileSampleInterval; 750 } 751 752 753 754 /** {@inheritDoc} */ 755 public Class<? extends ProfilerPluginCfg> configurationClass() { 756 return ProfilerPluginCfg.class; 757 } 758 759 760 761 /** {@inheritDoc} */ 762 public DN dn() { 763 return impl.getDN(); 764 } 765 766 767 768 /** {@inheritDoc} */ 769 public String toString() { 770 return impl.toString(); 771 } 772 } 773}