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

Issue with Parameter Info when execute QueryContext with parameter encode. #443

Open
jawadpak opened this issue Feb 3, 2023 · 0 comments

Comments

@jawadpak
Copy link

jawadpak commented Feb 3, 2023

We have a DATA RACE issue with Parameter Info when our application execute the database operations in parallels. Here is the log below:

WARNING: DATA RACE
[2023-02-02T21:18:53.995Z] Read at 0x0000040017e8 by goroutine 460:
[2023-02-02T21:18:53.995Z] github.com/sijms/go-ora/v2.(*ParameterInfo).encodeValue()
[2023-02-02T21:18:53.995Z] /var/vendor/github.com/sijms/go-ora/v2/parameter_encode.go:587 +0x6ada
[2023-02-02T21:18:53.995Z] github.com/sijms/go-ora/v2.(*Stmt).NewParam()
[2023-02-02T21:18:53.995Z] /var/vendor/github.com/sijms/go-ora/v2/command.go:1498 +0x2c4
[2023-02-02T21:18:53.995Z] github.com/sijms/go-ora/v2.(*Stmt).Query()
[2023-02-02T21:18:53.995Z] /var/vendor/github.com/sijms/go-ora/v2/command.go:1644 +0x346
[2023-02-02T21:18:53.995Z] github.com/sijms/go-ora/v2.(*Stmt).QueryContext()
[2023-02-02T21:18:53.995Z] /var/vendor/github.com/sijms/go-ora/v2/command.go:1566 +0x51e
[2023-02-02T21:18:53.995Z] github.com/sijms/go-ora/v2.(*Connection).QueryContext()
[2023-02-02T21:18:53.995Z] /var//vendor/github.com/sijms/go-ora/v2/connection.go:1143 +0xc4
[2023-02-02T21:18:53.995Z] database/sql.ctxDriverQuery()
[2023-02-02T21:18:53.995Z] /usr/local/go/src/database/sql/ctxutil.go:48 +0x217
[2023-02-02T21:18:53.995Z] database/sql.(*DB).queryDC.func1()
[2023-02-02T21:18:53.995Z] /usr/local/go/src/database/sql/sql.go:1722 +0x264
[2023-02-02T21:18:53.995Z] database/sql.withLock()
[2023-02-02T21:18:53.995Z] /usr/local/go/src/database/sql/sql.go:3396 +0xb5
[2023-02-02T21:18:53.995Z] database/sql.(*DB).queryDC()
[2023-02-02T21:18:53.995Z] /usr/local/go/src/database/sql/sql.go:1717 +0x24d
[2023-02-02T21:18:53.995Z] database/sql.(*Conn).QueryContext()
[2023-02-02T21:18:53.995Z] /usr/local/go/src/database/sql/sql.go:1972 +0x13d
[2023-02-02T21:18:53.995Z] database/sql.(*Conn).QueryRowContext()
[2023-02-02T21:18:53.995Z] /usr/local/go/src/database/sql/sql.go:1982 +0x4a4

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

1 participant