DB, SQL
The following provides the options related to the Node.js agent DB and SQL.
-
profile_sql_param_enabled Boolean
Default
false
Collecting SQL parameters is enabled. However, the parameters can be retrieved only by entering a separate security key. Set the security key to 6 digits in paramkey.txt of the agent installation path. If paramkey.txt does not exist, it is automatically generated and a random key is set.
-
profile_connection_open_enabled Boolean
Default
true
It records DB connection open data in the trace details.
-
profile_error_sql_time_max Int
Default
30000
If the SQL execution time exceeds the set value, it is treated as TOO SLOW error. If it is set to
0
, it is not treated as an error. -
trace_sql_normalize_enabled Boolean
Default
true
It enables the function to normalize any SQL statements by extracting the literal part from each SQL statement.
-
hook_connection_open_patterns String
It registers the method to call upon DB connection open. It is common to register getConnection of any connection pool that has not been set.
Examplehook_connection_open_patterns=mypool.ConPool.getConnection
-
trace_sql_error_stack Boolean
Default
false
SQL errors are stored as stacks (MySQL, MariaDB, PostgreSQL, SQL Server).
-
trace_sql_error_depth Int
Default
50
Set the number of lines of errors to be stored when applying the
trace_sql_error_stack
option.