Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added naming of backup engine threads #2053

Closed
wants to merge 4 commits into from

Conversation

s-sharan
Copy link

Changed the naming of backup engine threads from "ldb" to "backup_engine"
Test Plan:
screen shot 2017-03-29 at 10 23 46 am

@ajkr
Copy link
Contributor

ajkr commented Mar 29, 2017

In this case the background worker thread is actually thread 19. Thread 1 is the user thread who's calling CreateNewBackup, we don't want to rename this one.

@ajkr
Copy link
Contributor

ajkr commented Mar 29, 2017

@facebook-github-bot
Copy link
Contributor

@s-sharan updated the pull request - view changes

@s-sharan
Copy link
Author

Fixed it

backup_engine

@@ -647,6 +647,7 @@ Status BackupEngineImpl::Initialize() {
// background
for (int t = 0; t < options_.max_background_operations; t++) {
threads_.emplace_back([this]() {
pthread_setname_np(pthread_self(), "backup_engine");
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it's glibc-specific, maybe conditionally compile this line using #ifdef OS_LINUX

@facebook-github-bot
Copy link
Contributor

@s-sharan updated the pull request - view changes

Copy link
Contributor

@ajkr ajkr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Thanks for your contribution to RocksDB! 👍

@facebook-github-bot
Copy link
Contributor

@ajkr has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants