com.sun.net.httpserver.HttpExchange represents a request response exchange. In https://bugs.openjdk.org/browse/JDK-8235786 we updated the normative text of the getAttribute() and setAttribute() methods to match the JDK's built-in implementation of those methods.
The updated normative text, although matching the current implementation, can now potentially cause existing subclasses which overridde those abstract public methods to behave differently from the method specification. In fact, a mail in the net-dev mailing list has pointed out that there are existing subclasses out there which implement these methods differently and the updated method specification contradicts those implementations causing compatibility issues. The net-dev mailing list discussion is here https://mail.openjdk.org/pipermail/net-dev/2024-December/025171.html.
We should redo the documentation of these methods to separate out the JDK's built-in implementation details from the normative text.
The updated normative text, although matching the current implementation, can now potentially cause existing subclasses which overridde those abstract public methods to behave differently from the method specification. In fact, a mail in the net-dev mailing list has pointed out that there are existing subclasses out there which implement these methods differently and the updated method specification contradicts those implementations causing compatibility issues. The net-dev mailing list discussion is here https://mail.openjdk.org/pipermail/net-dev/2024-December/025171.html.
We should redo the documentation of these methods to separate out the JDK's built-in implementation details from the normative text.
- csr for
-
JDK-8345582 Additional clarification to the com.sun.net.httpserver.HttpExchange.getAttribute() and setAttribute() methods after JDK-8235786
-
- Closed
-
- relates to
-
JDK-8345794 Backout doc change introduced by JDK-8235786
-
- Resolved
-
-
JDK-8235786 Javadoc for com/sun/net/httpserver/HttpExchange.java#setAttribute is unclear
-
- Closed
-
- links to
-
Review(master) openjdk/jdk/22577