Skip to content

Pool cannot be used when connection is broken without rst due to DB hang #227

@choijunwoo

Description

@choijunwoo

Bug Report

Versions

  • Driver: 8.0.31
  • Database: mysql 8.0.28
  • Java: 17
  • OS: rocky8

Current Behavior

  • If the DB hangs for some reason, the application cannot receive rst and the connections will remain in the established state. I guess if there are max size of connections in the pool and a new acquire connection occurs, the request will fail because the connection cannot be newly created.

  • Image
  • Image

Steps to reproduce

  1. use long sleep statement
  2. packet drop use iptable on mysql server
  3. restart mysql and wait close fin-wait socket
  4. remove iptable rule

Expected behavior/code

Possible Solution

  • I think there should be a similar function to connection timeout or query timeout

Additional context

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions