This issue is being filed to track one of the four suggestions made in JDK-8184279.
- Redirect: Why is this an enum? This seems to needlessly restrict extensibility of
the API: For example, (as opposed to Effective Java 1st Edition’s type safe enum
pattern), it makes it impossible to ever define redirect policies at runtime (e.g.
based on a list of trusted hosts) because the set of instances is fixed at compile time,
- Redirect: Why is this an enum? This seems to needlessly restrict extensibility of
the API: For example, (as opposed to Effective Java 1st Edition’s type safe enum
pattern), it makes it impossible to ever define redirect policies at runtime (e.g.
based on a list of trusted hosts) because the set of instances is fixed at compile time,
- relates to
-
JDK-8184279 Custom HttpClient implementations
- Resolved