tencent cloud

TDSQL Boundless

Release Notes
Product Introduction
Overview
Scenarios
Product Architecture
Instance Types
Compatibility Notes
Kernel Features
Kernel Overview
Kernel Version Release Notes
Functionality Features
Performance Features
Billing
Billing Overview
Purchase Method
Pricing Details
Renewal
Overdue Payments
Refund
Getting Started
Creating an Instance
Connect to Instances
User Guide
Data Migration
Data Subscription
Instance Management
Configuration Change
Parameter Configuration
Account Management
Security Group
Backup and Restoration
Database Auditing
Tag Management
Use Cases
Technical Evolution and Usage Practices of Online DDL
Lock Mechanism Analysis and Troubleshooting Practices
Data Intelligent Scheduling and Related Practices for Performance Optimization
TDSQL Boundless Selection Guide and Practical Tutorial
Developer Guide
Developer Guide (MySQL Compatibility Mode)
Developer Guide (HBase Compatibility Mode)
Performance Tuning
Performance Tuning Overview
SQL Tuning
DDL Tuning
Performance White Paper
Performance Overview
TPC-C Test
Sysbench Test
API Documentation
History
Introduction
API Category
Making API Requests
Instance APIs
Security Group APIs
Task APIs
Backup APIs
Rollback APIs
Parameter APIs
Database APIs
Data Types
Error Codes
General Reference
System Architecture
SQL Reference
Database Parameter Description
TPC-H benchmark data model reference
Error Code Information
Security and Compliance
FAQs
Agreements
Service Level Agreement
Terms of Service
Privacy Policy
Data Processing And Security Agreement
Contact Us
Glossary

BTHREAD_LIST

PDF
포커스 모드
폰트 크기
마지막 업데이트 시간: 2026-03-06 18:48:07

Function

The BTHREAD_LIST view displays the operational status of bthread coroutines in the current system. It lists all active bthreads, enabling troubleshooting of performance, blocking, and resource consumption issues.

Field Description

Field Name
Type
Description
bthread_id
bigint unsigned
The unique identifier for a bthread.
stop
smallint unsigned
Indicates whether the bthread is currently stopped (0 - running, 1 - stopped).
interrupted
smallint unsigned
Indicates whether another thread has called bthread_interrupt to interrupt the current bthread (0 - not interrupted, 1 - interrupted).
about_to_quit
smallint unsigned
Indicates whether the scheduling of the current bthread can be deferred (0 - cannot be deferred, 1 - can be deferred).
yield_count
smallint unsigned
Represents the bthread (yield) counter, which is used to determine which queue a bthread should be placed in when it actively yields the CPU.
fn
varchar(32)
The pointer to the entry function called by the bthread.
arg
varchar(32)
The pointer to the parameters of the entry function called by the bthread.
attr_stack_type
bigint unsigned
Stack type, with values 0-4, corresponding to the values of bthread_stacktype_t.
attr_flags
bigint unsigned
Bit flags, corresponding to bthread_attrflags_t.
attr_keytable_pool
varchar(32)
The pointer to the keytable.
has_tls
smallint unsigned
Indicates whether the bthread has TLS (Thread Local Storage) (0 - none, 1 - present).
uptime_ns
bigint
The total runtime of the bthread since its creation (in nanoseconds).
cputime_ns
bigint
The actual CPU execution time occupied by the bthread (in nanoseconds).
nswitch
bigint
Number of context switches.

Examples

tdsql > SELECT * FROM information_schema.bthread_list limit 1 \\G
*************************** 1. row ***************************
bthread_id: 4294980352
stop: 0
interrupted: 0
about_to_quit: 0
yield_count: 0
fn: 0x556eb9fd33a0
arg: 0x7fbc1ab9cd40
attr_stack_type: 3
attr_flags: 0
attr_keytable_pool: NULL
has_tls: 1
uptime_ns: 71092709249214
cputime_ns: 1273570
nswitch: 3
1 row in set (0.00 sec)

도움말 및 지원

문제 해결에 도움이 되었나요?

피드백