Why exactly is DataClassRowMapper/BeanPropertyRowMapper way less performant than custom row mapper?
The title. I was doing performance tuning, and I somehow guessed that these spring provided rowmappers were a bottleneck. I removed that, and I have a custom rowmapper (basically, it caches the mapping from record's attributes to respective column in resultSet in a map-index, and searches by column index. Since my queries are static and map 1-1 to entity classes, this works very well). My solution was simple, but I'm trying to find exactly "why" spring provided rowmappers are way less optimized - is it due to some multi threading environment, or a lot of work which need not to be done? Also, why is searching by index way faster than searching by column name? I'm using Oracle. If anyone has any references, or any hints on how I could go forward in this knowledge hunt, I'll be grateful. Currently not getting anything relevant on Google search.