tarantool / tarantool/tarantool
Crash at exit if there's active net.box connection in application thread
Nobody has claimed this yet.
- Dominant language
- Lua
- Stars
- 3.7k
- Forks
- 419
- Avg merge
- 1d 23h
- Merged PRs (30d)
- 88
Description
Bug description
If an application thread has an active connection when Tarantool exits, an assertion failure occurs:
tarantool: ./src/box/lua/net_box.c:571: netbox_transport_destroy: Assertion `transport->worker == NULL' failed.
Reproduced with a debug build of Tarantool 3.8.0-entrypoint-67-g210970c87815. Tarantool 3.7 is likely to be affected as well.
Steps to reproduce
Create a listening Tarantool instance:
box.cfg{listen = 3301}
In another terminal, run the following script:
box.cfg{app_threads = 1}
require('experimental.threads').eval('app', [[
require('net.box').connect(3301)
]])
os.exit(0)
Actual behavior
Tarantool crashes with an asserion failure.
Expected behavior
Tarantool exits without errors.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start in src/box/lua/net_box.c around netbox_transport_destroy and reproduce the assertion with the Lua script in the issue using a debug build. Trace shutdown with an active net.box connection in an application thread, then verify that the same reproduction exits without errors.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- lua
- Domain
- backend
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Clearly specified
- Newbie friendliness
- 65/100