• 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

Handler Class - Is it correct?

 
Greenhorn
Posts: 5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,
As part of the java application I am developing, I have written a handler class (VOFactory.java) which uses reflection to populate java objects from data extracted from an Oracle database. My application only has approximately 40 concurrent users, but performance is currently atrocious and profiling has idenitified that the majority of memory is being used by the handler class.

Is there any chance that someone way more experienced and skilled than myself could take a look at the code below and suggest where I might be going wrong. Its driving me nuts!!!




This in turn is called from the following method located within my factory class (VOFactory.java):





Any advice or assistance that anyone is able to offer on this would be greatly appreciated.

Cheers,

PVH
 
drifter
Posts: 1364
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You might want to mosey over to the Java APIs forum, where the authors of Java Reflection in Action are helping to answer questions this week:

"This week, we're delighted to have Ira R. Forman and Nate Forman amongst us, helping to answer questions in the Other Java APIs forum.

We'll be selecting four random posters in this forum to win a free copy of their book, Java Reflection in Action, provided by the publisher, Manning."
 
Ranch Hand
Posts: 5093
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Your main problem is your largescale use of reflection.
While using it can help you do things that aren't otherwise possible (at least not easily) it does have a pretty hefty performance penalty.
 
Don't listen to Steve. Just read this tiny ad:
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic