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

com.sun.net.httpserver.HttpExchange should implement AutoCloseable

    XMLWordPrintable

    Details

    • Subcomponent:
    • Resolved In Build:
      b13

      Description

      A DESCRIPTION OF THE PROBLEM :
      Class com.sun.net.httpserver.HttpExchanage has a close() method which should be called when an HttpExchange ends. Therefore, class com.sun.net.httpserver.HttpExchanage should implement AutoCloseable.

      Expected behavior: Classes which need to be closed can be used with try-with-resources statements because they implement AutoCloseable.
      Actual behavior: HttpExchange cannot be used with try-with-resources statements because it doesn't implement AutoCloseable.


        Attachments

          Issue Links

            Activity

              People

              Assignee:
              pconcannon Patrick Concannon
              Reporter:
              webbuggrp Webbug Group
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: