Search code examples
javamodel-view-controllerjspscriptlet

Comparison of JSP Scriptlet versus MVC with regards to performance


I came from an interview and the CTO (Chief Technology Officer) told me that there have a system (which has been running for over 5 years) and they still prefer not to use MVC purely on performance. I know most MVC uses reflection to invoke methods (which is, in essence slow) but many MVC (I know Struts does it, I read the code) cache the methods it invokes so I doesn't have to "find" the method to invoke all the time.

For now, they stick to scriptlets (and they don't use JSPTags). I wonder, is there a huge performance going purely scriplets than MVC? They prefer stateless vs stateful sessions to avoid session migration, session tracking, etc.

If what the CTO says is true, why is MVC still preferred (I know why MVC is there, but with regards to performance).


Solution

  • Contra arguments:

    • Reflection isn't that slow anymore since a good couple of years.
    • Hardware performance has insanely been increased the last couple of years.
    • MVC leads finally to faster development. Less wasted time = more $$$ saves.

    I'd pass the job.