Overview

2025-11-28 06:00:51  Updated

A diagnostic point describes the key procedure in the routing and forwarding process on OceanBase Database Proxy (ODP). You can view diagnostic points to learn about the routing and forwarding process. This topic describes how to troubleshoot issues based on diagnostic points.

Troubleshooting procedure

After you obtain diagnostic information, you can perform different troubleshooting operations based on whether the routed request is in the transaction.

Request in the transaction

If a request in a transaction is inaccurately routed, two cases are involved.

  • Distributed transaction routing

    • If the current request is inaccurately routed, check the diagnostic points based on the diagnostic procedure.

    • If the current request is routed to the coordinator node, extract the SQL statement in [Trans First Query], pass the statement to the explain route command to run the command again, and check the diagnostic points based on the diagnostic procedure.

  • Non-distributed transaction routing

    The current request is routed together with the first statement in the transaction. In this case, extract the SQL statement in [Trans First Query], pass the statement to the explain route command to run the command again, and check the diagnostic points based on the diagnostic procedure.

Request not in the transaction

If an inaccurately routed request is not in a transaction, you can directly check the diagnostic points based on the diagnostic procedure.

Diagnostic procedure

After you obtain diagnostic information by running the explain route command or from diagnostic logs, you can check each diagnostic point based on the following procedure. For more information about the variables to diagnose at each diagnostic point, see the following topics of diagnostic points.

The following table summarizes the diagnostic points based on the execution sequence. A higher diagnostic level indicates more detailed diagnostic information.

Note

  • Not all data of diagnostic points is recorded in logs or returned in the result set. Only data useful to the current situation is recorded or returned.

  • The TABLE_ENTRY_LOOKUP_START and PARTITION_ID_CALC_START diagnostic points have no data and are used only to maintain the tree structure of diagnostic points.

Diagnostic phase Diagnostic point Diagnostic point level
Syntax parsing SQL_PARSE 1
Routing information acquisition ROUTE_INFO 1
Replica location acquisition LOCATION_CACHE_LOOKUP 1
ROUTINE_ENTRY_LOOKUP_DONE 2
TABLE_ENTRY_LOOKUP_START 2
FETCH_TABLE_RELATED_DATA 3
TABLE_ENTRY_LOOKUP_DONE 2
PARTITION_ID_CALC_START 2
EXPR_PARSE 3
CALC_ROWID 3
RESOLVE_EXPR 3
RESOLVE_TOKEN 4
CALC_PARTITION_ID 3
PARTITION_ID_CALC_DONE 2
PARTITION_ENTRY_LOOKUP_DONE 2
Node selection based on the routing strategy ROUTE_POLICY 1
Replica access control CONGESTION_CONTROL 1
Response handling HANDLE_RESPONSE 1
Replication selection and retry RETRY 1

Diagnostic skills

  • Pay attention to the WARN information in Route Prompts and the diagnostic data near the corresponding diagnostic point.

  • Pay attention to the error information in Route Plan.

  • Set route_diagnosis_level to 4 and monitor_log_level to 'TRACE' and view the diagnostic results of all user requests in the diagnostic logs.

    For more information about route_diagnosis_level, see route_diagnosis_level. For more information about monitor_log_level, see monitor_log_level.

Contact Us