Open adobley opened 8 months ago
Can't fix it fast, I'll publish 0.5.10 with pid in jamdb_oracle.ex like before 0.5.7
Thank you! I've got a patch that seems to fix the issue for this reproduction. But I'm fairly new to erlang, so it may not be the right way to address this issue. I'll open a draft PR in case it helps.
Sorry about the delay! This fell off my radar. This looks like it addresses our issue.
I was worried that flushing would cause information that the Plug was expecting to find would get lost. However in our current end to end tests this doesn't cause us any issues.
Thanks for addressing this so quickly! Really appreciate your help.
I'm happy to close this if this is something you're looking to promote to master.
We have been observing some failures in our tests related to the Jamdb.Oracle driver.
[error] Jamdb.Oracle (#PID<0.1313.0>) disconnected: ** (DBConnection.ConnectionError) :function_clause
We were able to narrow down the commit that introduced this behavior to https://github.com/erlangbureau/jamdb_oracle/commit/7edff839de1edb41388deee6435f3557c1bf45fb
When we add debug statements to the
:jamdb_oracle_conn
code we can see that it is erroring when trying to process a message that it read. This message in our case contains information added to the Process message queue byPlug.Conn
for use in the test behaviors. Without the genserver in:jamdb_oracle
the:jamdb_oracle_conn
is reading any message off the current Process messages. While this seems to be handled OK in our running app, as far as we have seen, it does break testing.We have a minimal reproduction in this script without the need for all our testing resources. This script just connects to a Oracle and tries to read off of the DUAL table. However, once there is some message on the Process messages it will fail for
jambd_oracle
versions0.5.7
and newer.Is there a way we can prevent the
:jamdb_oracle_conn
from reading messages that are not intended for it? This behavior is disrupting our ability to test our app.