= 7.1.0. Windows is not currently supported) // ============================== USING FUNCTIONS (2) // scoutapm_get_calls() - PECL_scoutapm >= PECL_scoutapm_1_0_0 // scoutapm_list_instrumented_functions() - PECL_scoutapm >= PECL_scoutapm_1_0_2 // ============================== USING CLASSES (0) // ============================== USING DATA_TYPES (1) // array // ============================== END // REQUIREMENTS // ============================== // ============================== BEGIN // PHP_OTHER_SCOUTAPM // ============================== ABOUT // PHP Manual / Function Reference / Other Services / ScoutAPM // URL: https://www.php.net/manual/en/book.scoutapm.php // ============================== DESCRIPTION // SCOUTAPM // // SCOUTAPM - BEGIN // ScoutAPM // // INTRODUCTION // INSTALLING_CONFIGURING // PREDEFINED_CONSTANTS // SCOUTAPM_FUNCTIONS // // INTRODUCTION - BEGIN // Introduction // // Note: This extension is not available on Windows platforms. // ScoutAPM's extension for PHP provides additional capabilities to application monitoring over just using the base PHP userland library. // // LITERATURE_SOURCES // * PHP_NET (2023-09-30) // URL: https://www.php.net/manual/en/intro.scoutapm.php // INTRODUCTION - END // // INSTALLING_CONFIGURING - BEGIN // Installing/Configuring // // REQUIREMENTS // INSTALLATION // RUNTIME_CONFIGURATION // // REQUIREMENTS - BEGIN // Requirements // // * PHP >= 7.1.0 // * Windows is not currently supported // // LITERATURE_SOURCES // * PHP_NET (2023-09-30) // URL: https://www.php.net/manual/en/scoutapm.requirements.php // REQUIREMENTS - END // // INSTALLATION - BEGIN // Installation // // This extension is available on PECL. Run: // [code] // $ sudo pecl install scoutapm // [/code] // // You may need to add Scout to your php.ini, for example: // [code] // extension=scoutapm.so // [/code] // // LITERATURE_SOURCES // * PHP_NET (2023-09-30) // URL: https://www.php.net/manual/en/scoutapm.installation.php // INSTALLATION - END // // RUNTIME_CONFIGURATION - BEGIN // Runtime Configuration // // This extension has no configuration directives defined in php.ini. // // LITERATURE_SOURCES // * PHP_NET (2023-09-30) // URL: https://www.php.net/manual/en/scoutapm.configuration.php // RUNTIME_CONFIGURATION - END // // LITERATURE_SOURCES // * PHP_NET (2023-09-30) // URL: https://www.php.net/manual/en/scoutapm.setup.php // INSTALLING_CONFIGURING - END // // PREDEFINED_CONSTANTS - BEGIN // Predefined Constants // // This extension has no constants defined. // // LITERATURE_SOURCES // * PHP_NET (2023-09-30) // URL: https://www.php.net/manual/en/scoutapm.constants.php // PREDEFINED_CONSTANTS - END // // SCOUTAPM_FUNCTIONS - BEGIN // Scoutapm Functions // // Table of Contents // * scoutapm_get_calls - Returns a list of instrumented calls that have occurred // * scoutapm_list_instrumented_functions - List functions scoutapm will instrument. // // LITERATURE_SOURCES // * PHP_NET (2023-09-30) // URL: https://www.php.net/manual/en/ref.scoutapm.php // SCOUTAPM_FUNCTIONS - END // // LITERATURE_SOURCES // * PHP_NET (2023-09-30) // URL: https://www.php.net/manual/en/book.scoutapm.php // SCOUTAPM - END // ============================== // ============================== BEGIN // PHP_OTHER_SCOUTAPM_SCOUTAPM_GET_CALLS // ============================== PUBLIC // ============================== ABOUT // Returns a list of instrumented calls that have occurred. // ============================== SUPPORT // PECL_scoutapm_1_0_0 // ============================== USING FUNCTIONS (1) // scoutapm_get_calls() - PECL_scoutapm >= PECL_scoutapm_1_0_0 // ============================== CODE function php_other_scoutapm_scoutapm_get_calls() { $return_scoutapm_get_calls = null; // ========== SCOUTAPM_GET_CALLS - BEGIN // ===== ABOUT // Returns a list of instrumented calls that have occurred // ===== DESCRIPTION // Returns a list of any instrumented function calls since scoutapm_get_calls() was last called. The list is cleared each time the function is called. // ===== SUPPORTED // PECL_scoutapm >= PECL_scoutapm_1_0_0 // ===== SYNTAX // scoutapm_get_calls(): array // ===== CODE $return_scoutapm_get_calls = scoutapm_get_calls( // This function has no parameters. ); // Return Values // scoutapm_get_calls() returns an array containing a list of all recorded calls to instrumented function calls. // // [examples] // Examples // [example] // Example #1 Fetch instrumented calls // [php] // // file_get_contents('a.txt'); // file_get_contents('b.txt'); // // print_r(scoutapm_get_calls()); // [/php] // The above example will output something similar to: // [result] // Array // ( // [0] => Array // ( // [function] => file_get_contents // [entered] => 1576839727.7934 // [exited] => 1576839727.7935 // [time_taken] => 2.7894973754883E-5 // [argv] => Array // ( // [0] => a.txt // ) // // ) // // [1] => Array // ( // [function] => file_get_contents // [entered] => 1576839727.7935 // [exited] => 1576839727.7935 // [time_taken] => 7.8678131103516E-6 // [argv] => Array // ( // [0] => b.txt // ) // // ) // // ) // [/result] // [/example] // [/examples] // ===== LITERATURE_SOURCES // * PHP_NET (2023-09-30) // URL: https://www.php.net/manual/en/function.scoutapm-get-calls.php // ========== SCOUTAPM_GET_CALLS - END // SYNTAX: // array scoutapm_get_calls() return $return_scoutapm_get_calls; // array } // ============================== END // PHP_OTHER_SCOUTAPM_SCOUTAPM_GET_CALLS // ============================== // ============================== BEGIN // PHP_OTHER_SCOUTAPM_SCOUTAPM_LIST_INSTRUMENTED_FUNCTIONS // ============================== PUBLIC // ============================== ABOUT // List functions scoutapm will instrument. // ============================== SUPPORT // PECL_scoutapm_1_0_2 // ============================== USING FUNCTIONS (1) // scoutapm_list_instrumented_functions() - PECL_scoutapm >= PECL_scoutapm_1_0_2 // ============================== CODE function php_other_scoutapm_scoutapm_list_instrumented_functions() { $return_scoutapm_list_instrumented_functions = null; // ========== SCOUTAPM_LIST_INSTRUMENTED_FUNCTIONS - BEGIN // ===== ABOUT // List functions scoutapm will instrument. // ===== DESCRIPTION // Returns a list of the functions the extension will instrument. // ===== SUPPORTED // PECL_scoutapm >= PECL_scoutapm_1_0_2 // ===== SYNTAX // scoutapm_list_instrumented_functions(): array // ===== CODE $return_scoutapm_list_instrumented_functions = scoutapm_list_instrumented_functions( // This function has no parameters. ); // Return Values // scoutapm_list_instrumented_functions() returns an array containing a list of all functions that the scoutapm extension is able to instrument in the current installation. // // [examples] // Examples // [example] // Example #1 Fetch the list of functions scoutapm will instrument // [php] // print_r(scoutapm_list_instrumented_functions()); // [/php] // The above example will output something similar to: // [result] // Array // ( // [0] => file_get_contents // [1] => file_put_contents // [2] => fopen // [3] => fread // [4] => fwrite // [5] => pdo->exec // [6] => pdo->query // [7] => pdo->prepare // [8] => pdostatement->execute // ) // [/result] // [/example] // [/examples] // ===== LITERATURE_SOURCES // * PHP_NET (2023-09-30) // URL: https://www.php.net/manual/en/function.scoutapm-list-instrumented-functions.php // ========== SCOUTAPM_LIST_INSTRUMENTED_FUNCTIONS - END // SYNTAX: // array scoutapm_list_instrumented_functions() return $return_scoutapm_list_instrumented_functions; // array } // ============================== END // PHP_OTHER_SCOUTAPM_SCOUTAPM_LIST_INSTRUMENTED_FUNCTIONS // ============================== // ============================== END // PHP_OTHER_SCOUTAPM // ============================== ?>