DTO Constructor Autowiring Breaks
dto-constructor-autowiring-breaks
The current approach relies on blocking JDBC calls managed by a limited connection pool and semaphore-based throttling; the question highlights a mismatch between blocking thread-per-request behavior and the differences in how virtual threads and reactive event-loop drivers manage threads and waiting. | Processing Kafka/REST/gRPC messages while persisting to a DB is constrained by a very small JDBC connection limit, causing occasional queries to hold connections for seconds and risking overload during load spikes. | Use virtual threads for blocking DB/IO work to improve scalability under the same small pool, or switch to a reactive database driver/event-loop model to avoid blocking carrier threads; adjust concurrency/throttling accordingly (semaphore/backpressure) rather than assuming the current JDBC + thread pool design remains optimal.