JdbcTemplate acquired a multi-batch batchUpdate variant in 3.1 that was designed to split a given large collection of batch arguments into multiple batches of a specified size. This method and its ParameterizedPreparedStatementSetter callback interface were never mirrored in NamedParameterJdbcTemplate - and to this day, it is an odd one out on JdbcTemplate in terms of design.
Since there are no indications that modern-day JDBC drivers still suggest an external split into multiple batches, we do not intend to reflect this capability in the recent JdbcClient API. Due to the mismatch with NamedParameterJdbcTemplate and the unusual design, we rather intend to deprecate that multi-batch method on JdbcTemplate itself.
It is worth noting that batches can always be split up by the caller into multiple batchUpdate call sequences, if actually needed anywhere. There is no need to have this baked into Spring's JDBC client APIs as a first-class capability.
JdbcTemplateacquired a multi-batchbatchUpdatevariant in 3.1 that was designed to split a given large collection of batch arguments into multiple batches of a specified size. This method and itsParameterizedPreparedStatementSettercallback interface were never mirrored inNamedParameterJdbcTemplate- and to this day, it is an odd one out onJdbcTemplatein terms of design.Since there are no indications that modern-day JDBC drivers still suggest an external split into multiple batches, we do not intend to reflect this capability in the recent
JdbcClientAPI. Due to the mismatch withNamedParameterJdbcTemplateand the unusual design, we rather intend to deprecate that multi-batch method onJdbcTemplateitself.It is worth noting that batches can always be split up by the caller into multiple
batchUpdatecall sequences, if actually needed anywhere. There is no need to have this baked into Spring's JDBC client APIs as a first-class capability.