DEV Community

Discussion on: New Web Framework?

Collapse
 
cjbrooks12 profile image
Casey Brooks

I don't trust generated code either in most cases. It's too easy for scaffolds to fall out of date or require a lot of work to make the generated code do the additional stuff you need.

However, Java's annotation processing API is really nice for compile time code generation, so you know it is always up to date and works exactly as it should. Code generation that gets destroyed and recreated continually can be quite invaluable.

In my opinion, code generation can work but it shouldn't be static generation, only done once. It should be part of your build process.

Collapse
 
_pankajc profile image
Pankaj

Is this dynamic code generation responsible for slower server start ups in spring boot? I'm learning spring boot right now and love it so far except for the slower server start ups.