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

infinity wait in deadlock #101

Open
Den2016 opened this issue Apr 9, 2020 · 5 comments
Open

infinity wait in deadlock #101

Den2016 opened this issue Apr 9, 2020 · 5 comments

Comments

@Den2016
Copy link

Den2016 commented Apr 9, 2020

when third-party program lock some table and i try to commit my updates on this table - i dont get error, commitSync just infinity wait, until table is unlock

how get an error, if table, or record locks?

if i update locked record in IBExpert, i get deadlock error immediately, without any waits

@xdenser
Copy link
Owner

xdenser commented Apr 9, 2020

this depends on transaction lock resolution parameter
it may be 'wait' and 'no_wait'
but this library does set this parameter explicitly
so default is used, default is 'wait'

@Den2016
Copy link
Author

Den2016 commented Apr 10, 2020

how to set 'no_wait'?

i try this

        let conn = this.con.startNewTransactionSync()
        try {
            let res = conn.prepareSync("SET TRANSACTION NO WAIT");
            res = res.execSync();

but get error

In FBStatement::execSync - invalid transaction handle (expecting explicit transaction start)

i try querySync instead prepare/exec - same result

In querySync - invalid transaction handle (expecting explicit transaction start)

@xdenser
Copy link
Owner

xdenser commented Apr 10, 2020

currently library does not support setting this parameter

@Den2016
Copy link
Author

Den2016 commented Apr 10, 2020

can i hope that someday it will be?

@Den2016
Copy link
Author

Den2016 commented Apr 16, 2020

Ден, а ты по русски говоришь?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants