Tencent/mars

Xlog中native logWrite2方法能否增加线程名称输出?

Open

#410 opened on Jun 4, 2018

View on GitHub
 (2 comments) (0 reactions) (0 assignees)C++ (17,407 stars) (3,635 forks)batch import
help wanted

Description

在多线程场景下,光凭线程ID很难知道具体是哪里的线程。java中创建线程或线程池时,都可以指定名称,这样就很容易知道是哪个线程执行了该方法,有线程名称输出似乎更加容易定位问题,但光凭线程ID很难判断。

是否可以在native logWrite2方法增加线程名称输出?

Contributor guide