Optimize ValueInstantiator
construction for default Collection
, Map
types
#2416
Milestone
ValueInstantiator
construction for default Collection
, Map
types
#2416
Based on profiling it looks like attempts to discover creator for default
Collection
(ArrayList
) andMap
(LinkedHashMap
) types is a huge time sink, even thought actual creator in both cases will just be the default constructor. While this lookup cost is usually amortized across many calls it is a problem for cold-start case, including usage on Android platform, Lambda services and possibly some stream processing (spark streaming?).The main reason is that some common usage (such as binding as "untyped" (nominal type of
java.lang.Object
) or asList
/Map
) will use this codepath.So let's see handling can be changed to short-cut these 2 common cases.
The text was updated successfully, but these errors were encountered: