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

Races when starting and quickly shutting down blocking AST thread [CORE1418] #1836

Closed
firebird-automations opened this issue Aug 20, 2007 · 7 comments

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: @AlexPeshkoff

When engine tries to attach to any database, it starts (if not running yet) blocking AST thread. In case when database does not exist, that thread need to be shutted down. To do it, main thread posts own_wakeup event, and waits for blocking thread to shutdown (or 10 seconds timeout). But in case, when blocking thread performed event clear and wait calls after that post (i.e. have not started yet when was already requested to shutdown), it will never be awakened and will keep running after that 10secs timeout. When closing server process, it leads to AV due to attempts to work with deallocated shared memory.

Commits: 0959770 d34e401

@firebird-automations
Copy link
Collaborator Author

Modified by: @AlexPeshkoff

status: Open [ 1 ] => In Progress [ 3 ]

@firebird-automations
Copy link
Collaborator Author

Commented by: @AlexPeshkoff

Use of native semaphore (incapsulated into class Semaphore) to synchronize blocking AST thread startup solved a problem.

@firebird-automations
Copy link
Collaborator Author

Modified by: @AlexPeshkoff

status: In Progress [ 3 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

Fix Version: 2.1 Beta 2 [ 10190 ]

Fix Version: 2.0.3 [ 10200 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

status: Resolved [ 5 ] => Closed [ 6 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

Workflow: jira [ 12851 ] => Firebird [ 13911 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

QA Status: No test

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

status: Closed [ 6 ] => Closed [ 6 ]

QA Status: No test => Cannot be tested

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