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

Db on connect triggers fail to execute some time [CORE4761] #5064

Closed
firebird-automations opened this issue Apr 21, 2015 · 7 comments
Closed

Comments

@firebird-automations
Copy link
Collaborator

Submitted by: Lauri Zoova (lz)

Database connect trigger is not always not executed.

For example, given such trigger:

CREATE OR ALTER trigger trg_db_connect
active on connect position 0
AS
begin
rdb$set_context('USER_SESSION', 'ACTIVE_LANGUAGE', 'en');
end

The value "en" is sometimes not found after successfully connecting to the database. Typically the issue is observed when multiple attachments to the server (and same database?) are attempted at the same time.

Commits: 7105562 FirebirdSQL/fbt-repository@34898a9

====== Test Details ======

Race condition, see comments below.

@firebird-automations
Copy link
Collaborator Author

Modified by: @asfernandes

assignee: Adriano dos Santos Fernandes [ asfernandes ]

@firebird-automations
Copy link
Collaborator Author

Commented by: @hvlad

Reproduced.
The issue is due to race condition in MET_load_db_triggers - while one attachment loads triggers, another one could see it as already loaded empty vector.

@firebird-automations
Copy link
Collaborator Author

Modified by: @hvlad

assignee: Adriano dos Santos Fernandes [ asfernandes ] => Vlad Khorsun [ hvlad ]

@firebird-automations
Copy link
Collaborator Author

Commented by: @hvlad

Only SuperServer v2.5 is affected

@firebird-automations
Copy link
Collaborator Author

Modified by: @hvlad

status: Open [ 1 ] => Resolved [ 5 ]

resolution: Fixed [ 1 ]

Fix Version: 2.5.5 [ 10670 ]

@firebird-automations
Copy link
Collaborator Author

Modified by: @pavel-zotov

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

QA Status: Cannot be tested

Test Details: Race condition, see comments below.

@firebird-automations
Copy link
Collaborator Author

Modified by: @pcisar

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

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