Our AOT processing needs a code generation library and we're quite happy using JavaPoet in Spring Native. It would be quite unusual for the core container to have a direct dependency on a third-party so the plan is to jarjar it in org.springframework.javapoet in the spring-core module.

Comment From: snicoll

We've decided to depend on JavaPoet directly for now with an optional dependency in modules that require it.

Comment From: snicoll

With our design evolving where certain components can provide both the regular runtime behavior and something that can generate a pre-processed version of it, it became apparent that it's odd to rely on an optional dependency of javapoet.

We've decided to give the repackaging another try.