<feed xmlns='http://www.w3.org/2005/Atom'>
<title>ydb/library/cpp/yt/logging/logger.cpp, branch CLI_2.32.0</title>
<subtitle>Mirror of YDB github repos</subtitle>
<id>https://code.mastervirt.ru/ydb/atom?h=CLI_2.32.0</id>
<link rel='self' href='https://code.mastervirt.ru/ydb/atom?h=CLI_2.32.0'/>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/'/>
<updated>2026-06-06T21:16:49Z</updated>
<entry>
<title>Cache process/thread id getters and use them in TError origin capture</title>
<updated>2026-06-06T21:16:49Z</updated>
<author>
<name>babenko</name>
<email>babenko@yandex-team.com</email>
</author>
<published>2026-06-06T20:52:00Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=f10c7206fb31af8057446bceef9707aabaa9456e'/>
<id>urn:sha1:f10c7206fb31af8057446bceef9707aabaa9456e</id>
<content type='text'>
## Motivation
Profiling the YT master Automaton thread showed TOriginAttributes::Capture (run on every non-OK TError) spending ~60% of its time in a getpid() syscall — uncached on glibc &gt;= 2.25. NYT::GetCurrentThreadId() (gettid) feeds hot thread-affinity / log-manager checks on the same thread.

## Changes
- New library/cpp/yt/system/process_id.* with cached GetProcessId(); GetSystemThreadId() now caches the kernel tid in TLS. Both caches reset in the child after fork.
- Moved thread_name.{h,cpp} from misc to system.
- Removed GetCurrentProcessId/GetCurrentThreadId shims from yt/yt/core/misc/proc.{h,cpp}; migrated all callers to NYT::GetProcessId / NYT::GetSystemThreadId.
- TOriginAttributes::Capture uses the cached getters; recorded Tid is now the real kernel tid (matches perf/ps).
- Added microbenchmarks (library/cpp/yt/system/benchmarks, yt/yt/core/benchmarks/error.cpp).

## Microbenchmarks (release)
| | before | after |
|---|---|---|
| getpid | 101 ns | 0.33 ns |
| gettid | 102 ns | 1.64 ns |
| Capture | 161 ns | 50 ns |
| failed TError | 221 ns | 74 ns |
commit_hash:ee37ae57d61a5a2dd33daee935270f4bb93b7ff9
</content>
</entry>
<entry>
<title>Add a guard for per-fiber extra logging tags</title>
<updated>2025-08-22T11:45:50Z</updated>
<author>
<name>ifsmirnov</name>
<email>ifsmirnov@yandex-team.com</email>
</author>
<published>2025-08-22T10:43:37Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=46353fdbb6821d7aef22f4b0f7c5be8fcaa07b4f'/>
<id>urn:sha1:46353fdbb6821d7aef22f4b0f7c5be8fcaa07b4f</id>
<content type='text'>
commit_hash:3dfc664a8e26d9bfec6e997c848d5f66ede6e925
</content>
</entry>
<entry>
<title>Move more checks to the inlined part of IsLevelEnabled</title>
<updated>2025-05-20T13:03:58Z</updated>
<author>
<name>babenko</name>
<email>babenko@yandex-team.com</email>
</author>
<published>2025-05-20T12:47:30Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=a10c4008e6927e48e6ccb308444392752a5b6898'/>
<id>urn:sha1:a10c4008e6927e48e6ccb308444392752a5b6898</id>
<content type='text'>
commit_hash:ad986b1f46f36765b3d80b8e527b1f25ad966d42
</content>
</entry>
<entry>
<title>Make TLogger respect rvalues</title>
<updated>2025-04-09T07:08:02Z</updated>
<author>
<name>pogorelov</name>
<email>pogorelov@yandex-team.com</email>
</author>
<published>2025-04-09T06:51:18Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=8aaf2a74f96af4031b1dd50661e0514977129470'/>
<id>urn:sha1:8aaf2a74f96af4031b1dd50661e0514977129470</id>
<content type='text'>
commit_hash:dc29e989d9edbb7f171ba47632de428289393058
</content>
</entry>
<entry>
<title>Switch to std::string for logging tags</title>
<updated>2025-01-19T10:37:57Z</updated>
<author>
<name>babenko</name>
<email>babenko@yandex-team.com</email>
</author>
<published>2025-01-19T10:22:02Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=96874a96dab68de59f4cdf92626eb09d9629149b'/>
<id>urn:sha1:96874a96dab68de59f4cdf92626eb09d9629149b</id>
<content type='text'>
[nodiff:caesar]
commit_hash:62fa96ca05b1a4018e2e51e6b589483cd3a44fc4
</content>
</entry>
<entry>
<title>Fix regression: static anchors are not updated properly</title>
<updated>2024-10-30T12:52:26Z</updated>
<author>
<name>babenko</name>
<email>babenko@yandex-team.com</email>
</author>
<published>2024-10-30T11:45:00Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=7891efa0c4d0a1bbf82be8885a53017e06f2adf5'/>
<id>urn:sha1:7891efa0c4d0a1bbf82be8885a53017e06f2adf5</id>
<content type='text'>
commit_hash:ab0bd9b2d0569820e495c714baecb05145ed35bf
</content>
</entry>
<entry>
<title>YT-21566: Access thread local variables via noinline functions</title>
<updated>2024-04-25T23:41:13Z</updated>
<author>
<name>lukyan</name>
<email>lukyan@yandex-team.com</email>
</author>
<published>2024-04-25T23:21:44Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=5bbe44ff4e12b6d5496d56ecca97b0c4db340509'/>
<id>urn:sha1:5bbe44ff4e12b6d5496d56ecca97b0c4db340509</id>
<content type='text'>
970c33b44a7bd166b2716d86d3d2053dcaf05d7d
</content>
</entry>
<entry>
<title>Use volatile TLS in library/cpp/yt</title>
<updated>2023-12-05T17:50:57Z</updated>
<author>
<name>lukyan</name>
<email>lukyan@yandex-team.com</email>
</author>
<published>2023-12-05T16:07:41Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=d5b84ed65f77eab0135b9d0ee025556f4507b62b'/>
<id>urn:sha1:d5b84ed65f77eab0135b9d0ee025556f4507b62b</id>
<content type='text'>
</content>
</entry>
<entry>
<title>YT-19210: expose YQL shared library for YT.</title>
<updated>2023-07-28T21:02:16Z</updated>
<author>
<name>max42</name>
<email>max42@yandex-team.com</email>
</author>
<published>2023-07-28T21:02:16Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=73b89de71748a21e102d27b9f3ed1bf658766cb5'/>
<id>urn:sha1:73b89de71748a21e102d27b9f3ed1bf658766cb5</id>
<content type='text'>
After this, a new target libyqlplugin.so appears. in open-source cmake build.
Diff in open-source YDB repo looks like the following: https://paste.yandex-team.ru/f302bdb4-7ef2-4362-91c7-6ca45f329264</content>
</entry>
<entry>
<title>Revert "YT-19324: move YT provider to ydb/library/yql"</title>
<updated>2023-06-30T08:13:34Z</updated>
<author>
<name>max42</name>
<email>max42@yandex-team.com</email>
</author>
<published>2023-06-30T08:13:34Z</published>
<link rel='alternate' type='text/html' href='https://code.mastervirt.ru/ydb/commit/?id=3e1899838408bbad47622007aa382bc8a2b01f87'/>
<id>urn:sha1:3e1899838408bbad47622007aa382bc8a2b01f87</id>
<content type='text'>
This reverts commit ca272f12fdd0e8d5c3e957fc87939148f1caaf72, reversing
changes made to 49f8acfc8b0b5c0071b804423bcf53fda26c7c12.</content>
</entry>
</feed>
