Closed polvalente closed 3 years ago
We can definitely add a telemetry event for that. And likely one for when connections are established too.
@josevalim Cool! Can I help in any way?
@josevalim I was reading #228 and maybe adding another message for timeouts could also be a way to handle this. What do you think?
That also sounds good to me! PRs are welcome!
That also sounds good to me! PRs are welcome!
Ok then! I'll try to come up with something
Resolved in #236
Is there any way to measure through telemetry if the database keeps dropping connections with DBConnection.ConnectionError?
I noticed that the
drop
private function indeps/db_connection/lib/db_connection/connection_pool.ex
does print a custom inspect whenever the connection is dropped due to timeout. Maybe that could be a place to add the event? Or is there a better place in :ecto or :ecto_sql to do so?I could work on the PR myself given the right direction!
Thanks in advance