Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8361428

java.nio.BufferCleaner exits VM if a cleaning action throws

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Unresolved
    • Icon: P4 P4
    • None
    • None
    • core-libs
    • None

      When java.nio.BufferCleaner invokes a cleaning action, is does so within a try/catch that prints an error message (including stack trace) and then exits the VM (via System.exit) with a failure code.

      This behavior was based on that of jdk.internal.ref.Cleaner, which the BufferCleaner mechanism is replacing in the java.nio context. That behavior by jdk.internal.ref.Cleaner is very old, from before the mercurial age.

      But that doesn't seem ideal for BufferCleaner. It should probably log the exception in some way and then continue processing cleanups.

            Unassigned Unassigned
            kbarrett Kim Barrett
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated: