Skip to content

Instantly share code, notes, and snippets.

@rosik
rosik / README.md
Last active October 8, 2025 13:26
GDB script to log specific breakpoints hits

Run with

gdb -x ./gdbscript --batch --return-child-result --args ut/ydb-core-blobstorage-pdisk-ut.bak +TPDiskTest::TestStartEncryptedOrPlainAndRestart > stack_traces.stderr.log 2>&1
@rosik
rosik / sync_rollback.lua
Created November 3, 2022 17:31
Reproduce sync tx rollback
-- Related to the discussion in https://github.com/tarantool/tarantool/issues/7592
_G.log = require('log')
_G.json = require('json')
_G.fiber = require('fiber')
box.cfg({
election_mode = "manual",
memtx_use_mvcc_engine = true,
replication_synchro_quorum = 2,
@rosik
rosik / deadlock.lua
Last active August 18, 2020 16:43
Two fibers yield, but event loop is locked forever
#!/usr/bin/env tarantool
local log = require('log')
local fiber = require('fiber')
local c1 = fiber.channel(0)
local c2 = fiber.channel(0)
local f1 = fiber.new(function()
for i = 1, 10 do
c1:put(true)
ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDBldGroeaN1r6CUlsRkWR8eUEhepqJK4hnFSuHrWGReFC7QYLbrqxq18L/rsIIAYPC1SN9aGHv0PPfboIAOskxbgxyTASrxQNbFrWMf04OBsw5j3OBY9aGvGbruo0mSqFGrjk+dXoVRf9Iy7woHmXtpHfMSzYxTP5309b6GidOaMt5CX3XZwonqwqWfJ6QyeRWSHNHVwYX68hu74AGzxRxjAkE/xE3+SQZrwgL5r6W/H7mCCLk5Wg7+JIrVmZa7aWM1MVGtk28Y5fFXmHmUdkrCYVBlZZ6V2hjSoQ5ELaelqUIY3ibgb9noqnjS1ThwLlNgl3WFvgWQsgk3SYVmVXQOcUyDryLWvFHDtaMAgq99uTCX5CKY97ZwWQvL1kg7PlVBs8P15SgVOhehACae7WCEzPtDoEiwTbUDnuYnMLmN1DG2G/QieBfMwYHK2WD4h7VKY/01QZ+Rwf2W6+dcEejDA7xJWvtyCt0mdtPABGEtSeDuexxFKGByTC/8brMlBc= rosik@rlap