Title: Call a getter faster with reflection, MethodHandles or
LamdbaMetaFactory
Abstract:
What is the fastest way to read a getter from a Java class without knowing the class at compilation time? Java frameworks often do this. A lot. And it can directly influence their performance. So I’ve benchmarked different approaches, such as reflection, method handles, LamdbaMetaFactory and code generation. Recently I updated them for JDK 11.
Especially MethodHandles have an interesting catch 22 situation, which I'll explain during the presentation. Brief bio: Lead of OptaPlanner, the open source constraint solver in Java
Microblog URL: https://twitter.com/GeoffreyDeSmetBlog URL: https://www.optaplanner.org/blog/