Details
-
Type:
New Feature
-
Status:
Closed
-
Priority:
Major
-
Resolution: Won't Fix
-
Affects Version/s: 1.8.2
-
Fix Version/s: None
-
Component/s: ObjectMapper
-
Labels:None
-
Number of attachments :
Description
We should be able to customize the URLConnection used for read operations so we can configure things like userAgent. I don't necessarily want people to know that I'm using Java to probe their sites ![]()
JsonFactory._optimizedStreamFromURL() takes a URL and returns an InputStream using URL.openStream(). URL.openStream() is shorthand for url.openConnection().getInputStream().
I propose that we register some sort of factory with ObjectMapper that takes in a URL and returns an InputStream, then use this factory in optimizedStreamFromURL().
Interesting. Yes, I can see why this would be useful.