The Diagnostic System Module and Its Resource Descriptor Referencing the Diagnostics System Module from Config.xml

Understanding WLDF Configuration 4-5

4.6.1 The Diagnostic System Module and Its Resource Descriptor

You create a diagnostic system module through the Administration Console or the WebLogic Scripting Tool WLST. It is created as a WLDFResourceBean, and the configuration is persisted in a resource descriptor file configuration file, called DIAG_MODULE.xml, where DIAG_MODULE is the name of the diagnostic module. You can specify a name for the descriptor file, but it is not required. If you do not provide a file name, a file name is generated based on the value in the descriptor files name element. The file is created by default in the DOMAIN_ NAME\config\diagnostics directory, where DOMAIN_NAME is the name of the domains home directory. The file has the extension .xml. For instructions on creating a diagnostic system module, see Create diagnostic system modules in the Oracle WebLogic Server Administration Console Help.

4.6.2 Referencing the Diagnostics System Module from Config.xml

When you create a diagnostic system module using the Administration Console or the WebLogic Scripting Tool WLST, WebLogic Server creates it in DOMAIN_ NAMEconfigdiagnostics, and a reference to the module is added to the domains config.xml file. The config.xml file can contain multiple references to diagnostic modules, in one or more wldf-system-resource elements. The wldf-system-resource element includes the name of the diagnostic module file and the list of servers and clusters to which the module is targeted. For example, Example 4–2 shows a config.xml file with a module named myDiagnosticModule targeted to the server myserver and another module named newDiagnosticMod targeted to servers ManagedServer1 and ManagedServer2. Example 4–2 Sample WLDF Configuration Information in the Config.xml File for a Domain domain -- Other domain-level configuration elements -- wldf-system-resource xmlns=http:xmlns.oracle.comweblogicweblogic-diagnostics namemyDiagnosticModulename targetmyservertarget descriptor-file-namediagnosticsMyDiagnosticModule.xml descriptor-file-name descriptionMy diagnostic moduledescription Note: The diagnostic module conforms to the diagnostics.xsd schema, available at http:xmlns.oracle.comweblogicweblogic-diagnostic s1.0weblogic-diagnostics.xsd . Note: Oracle recommends that you do not write XML configuration files directly. But if you have a valid reason to do so, you should first create a diagnostic module from the Console. That way, you can start with the valid XML that the Console creates. For instructions, see Create diagnostic system modules in the Oracle WebLogic Server Administration Console Help. 4-6 Configuring and Using the Diagnostics Framework for Oracle WebLogic Server wldf-system-resource wldf-system-resource namenewDiagnosticModname targetManagedServer1,ManagedServer2target descriptor-file-namediagnosticsnewDiagnosticMod.xml descriptor-file-name descriptionA diagnostic module for my managed serversdescription wldf-system-resource -- Other WLDF system resource configurations -- domain The relationship of the config.xml file and the MyDiagnosticModule.xml file is shown in Figure 4–1 . Figure 4–1 Relationship of config.xml to System Descriptor File

4.6.3 The DIAG_MODULE.xml Resource Descriptor Configuration