• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

BeanPropertySqlParamterSource vs ParameterMap

 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I know that the BeanPropertySqlParamterSource can make things easier, and potentially prevent issues from miss typing the parameter map or row mapper, but what about performance.

I have been trying to find something online that talks about the performance difference between the two, but I have not had any luck. From what I have seen it does the BeanPropertySqlParameterSource does use reflection to call your getters and setters (not necessarily bad). I have to assume that it is a longer code path. Anyways has anyone done any testing? I keep going back and forth, but continue to lean towards coding the parameter maps and row mappers.

Thanks
 
Bartender
Posts: 1682
7
Android Mac OS X IntelliJ IDE Spring Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I doubt the performance difference is going to be noticeable. The fact that you are not finding any complaints online about it supports this theory. I would not prematurely optimize. If you are using it and not having performance issues than don't worry about it. Choose the method you are most comfortable with and use it.
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
reply
    Bookmark Topic Watch Topic
  • New Topic