SlideShare a Scribd company logo
1 of 28
What’s new in Spring Batch 4.3?
Mahmoud Ben Hassine
September 2–3, 2020
springone.io
Safe Harbor Statement
The following is intended to outline the general direction of VMware's offerings. It is intended for information purposes only and may not be incorporated
into any contract. Any information regarding pre-release of VMware offerings, future updates or other planned modifications is subject to ongoing
evaluation by VMware and is subject to change. This information is provided without warranty or any kind, express or implied, and is not a commitment to
deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions regarding VMware's offerings. These purchasing
decisions should only be based on features currently available. The development, release, and timing of any features or functionality described for
VMware's offerings in this presentation remain at the sole discretion of VMware. VMware has no obligation to update forward looking information in this
presentation.
2
About me
3
• Principal Software Engineer at VMware
• Spring Batch Co-Lead
• Open Source enthusiast
Github: @benas
Twitter: @b_e_n_a_s
Mahmoud Ben Hassine
Agenda
4
• Current status
• What’s new in Spring Batch 4.3?
• New features
• Performance improvements
• Dependencies updates
• Deprecations and technical debt
• What’s next?
• Q+A
Current status
(Sep 2020)
History of Spring Batch (1/2)
6
• Step scope
• Chunk-oriented processing
• Remote chunking/partitioning
• Java 5
• Spring Framework 3
v2.0
Apr 11, 2009
• Initial APIs
• Item-oriented processing
• XML configuration
• Java 1.4
• Spring Framework 2.5
• Job scope
• JSR-352 support
• SQLite support
• Spring Batch Integration
• Spring Boot support
• Builders for readers
• Builders for writers
• Java 8
• Spring Framework 5
v3.0
May 22, 2014
v1.0
Mar 28, 2008
v4.0
Dec 1, 2017
History of Spring Batch (2/2)
7
• @SpringBatchTest annotation
• @EnableBatchIntegration
annotation
• JSR 380 Bean Validation support
• Json reader/writer
• JSR 305 support
v4.1
Oct 29, 2018
• Apache Avro support
• Apache Kafka support
• Micrometer support
• Performance improvements
• Java 14 records support
• GraalVM support
• Kafka support refinement
• Performance improvements
• Deprecations
• Builders for readers
• Builders for writers
• Java 8
• Spring Framework 5
v4.3
Oct XX, 2020
v4.2
Oct 02, 2019
v4.0
Dec 1, 2017
v5.0
XXX XX, 20XX
• Spring Framework 6
• Java XX
• TBD
History of Spring Batch (2/2)
8
• @SpringBatchTest annotation
• @EnableBatchIntegration
annotation
• JSR 380 Bean Validation support
• Json reader/writer
• JSR 305 support
v4.1
Oct 29, 2018
• Apache Avro support
• Apache Kafka support
• Micrometer support
• Performance improvements
• Java 14 records support
• GraalVM support
• Kafka support refinement
• Performance improvements
• Deprecations
• Builders for readers
• Builders for writers
• Java 8
• Spring Framework 5
v4.3
Oct XX, 2020
v4.2
Oct 02, 2019
v4.0
Dec 1, 2017
v5.0
XXX XX, 20XX
• Spring Framework 6
• Java XX
• TBD
What’s new in v4.3?
(currently in M2)
New features
Java 14 records support
11
• Use records as items in chunk-oriented steps
• Leverage Spring Framework support for records
id,name
1,foo
2,bar
persons.csv
FlatFileItemReader<Person> reader = new FlatFileItemReaderBuilder<Person>()
.name("personItemReader")
.resource(new FileSystemResource("persons.csv"))
.delimited()
.names("id", "name")
.targetType(Person.class)
.build();
public class Person {
private int id;
Private String name;
// constructors
// getters and setters
// equals and hashcode
// toString
}
public record Person(int id, String name) {}
GraalVM support
12
• Leverage Spring Framework support for GraalVM
• Spring Batch jobs run correctly on GraalVM
• Reflection
• Proxies
• etc
Faster startup time + Better memory usage
Kafka support refinement
13
• Ability to start reading from a custom offset in a given partition
• Ability to start reading from the offset stored in Kafka
Image source: http://kafka.apache.org/intro
v4.3: read from custom offsetv4.2: read from the beginning
Support for annotation-based job execution
listeners
14
class MyListener implements JobExecutionListener {
@Override
public void beforeJob(JobExecution jobExecution) {
// do something before job execution
}
@Override
public void afterJob(JobExecution jobExecution) {
// do something after job execution
}
}
class MyListener {
@BeforeJob
public void beforeJob(JobExecution jobExecution) {
// do something before job execution
}
@AfterJob
public void afterJob(JobExecution jobExecution) {
// do something after job execution
}
}
v4.2: interface-based listeners v4.3: interface-based + annotation-based
listeners
Add SynchronizedItemStreamWriter
15
@Bean
public StaxEventItemWriter<Person> itemWriter() {
Jaxb2Marshaller marchaller = new Jaxb2Marshaller();
marchaller.setClassesToBeBound(Person.class);
return new StaxEventItemWriterBuilder<Person>()
.name("personItemWriter")
.resource(new FileSystemResource("persons.xml"))
.marshaller(marchaller)
.rootTagName("persons")
.build();
}
Expected output
• Some item writers are not safe to use in a multi-threaded step
(StaxEventItemWriter, JsonItemWriter, etc)
<persons>
<person>
<id>1</id>
<name>foo</name>
</person>
<person>
<id>2</id>
<name>foo</name>
</person>
</persons>
Actual output
<persons>
<name>foo</name>
<person>
<id>1</id>
</person>
<id>2<person>
<name>foo</name>
</id>
</person>
</persons>
Item writer bean
definition
Add SynchronizedItemStreamWriter
16
@Bean
public SynchronizedItemStreamWriter<Person> itemWriter() {
Jaxb2Marshaller marchaller = new Jaxb2Marshaller();
marchaller.setClassesToBeBound(Person.class);
StaxEventItemWriter<Person> personWriter = new StaxEventItemWriterBuilder<Person>()
.name("personItemWriter")
.resource(new FileSystemResource("persons.xml"))
.marshaller(marchaller)
.rootTagName("persons")
.build();
SynchronizedItemStreamWriter<Person> synchronizedPersonWriter = new SynchronizedItemStreamWriter<>();
synchronizedPersonWriter.setDelegate(personWriter);
return synchronizedPersonWriter;
}
• Some item writers are not safe to use in a multi-threaded step
(StaxEventItemWriter, JsonItemWriter, etc)
=> SynchronizedItemStreamWriter to the
rescue!
Other new features
17
• Add JpaNamedQueryProvider
• Add encoding parameter in StaxEventItemReader
• Micrometer support improvements
• Add DataFieldMaxValueJobParametersIncrementer
• etc
https://spring.io/blog/2020/08/13/spring-batch-4-3-0-m2-is-out
https://spring.io/blog/2020/06/26/spring-batch-4-3-0-m1-is-released-now
Performance improvements
for(item in chunk) {
mongoTemplate.save(item);
}
v4.2 (pseudo
code)
BulkOperations bulkOperations = mongoTemplate.bulkOps();
for(item in chunk) {
bulkOperation.add(item);
}
bulkOperations.execute();
v4.3 (pseudo
code)
Use bulk operations in MongoItemWriter
19
https://github.com/benas/spring-batch-lab/tree/master/issues/gh3713
for(item in chunk) {
repository.save(item);
}
v4.2 (pseudo
code)
repository.saveAll(items);
v4.3 (pseudo
code)
Use bulk operations in RepositoryItemWriter
20
https://github.com/benas/spring-batch-lab/tree/master/issues/gh3720
int getStepExecutionCount(JobInstance jobInstance, String stepName) {
int count = 0;
List<JobExecution> jobExecutions = findJobExecutions(jobInstance);
for (JobExecution jobExecution : jobExecutions) {
List<StepExecution> stepExecutions =
findStepExecutions(jobExecution);
count += countStepExecutions(stepExecutions, stepName);
}
return count;
}
v4.2 (pseudo
code)
v4.3 (pseudo
code)
int getStepExecutionCount(JobInstance jobInstance, String stepName) {
String query = “select count(id) from ... where ...”;
return jdbcTemplate.queryForObject(
query,
new Object[] {jobInstance, stepName},
Integer.class);
}
Job/Step start time improvement
21
https://github.com/benas/spring-batch-lab/tree/master/issues/gh3657
Dependencies updates
Dependencies updates
23
• Spring Framework 5.3
• Spring Integration 5.4
• Spring Data 2020.0
• Spring AMQP 2.3.0
• Spring for Apache Kafka 2.6.0
• Micrometer 1.5.3
Deprecations and
technical debt
Deprecations and technical debt
25
• API deprecation in preparation for v5
• Improve build process
• Improve test infrastructure
• Docker-based tests with testcontainers
• Junit 5
• Improve test coverage
• etc
What’s next?
Release plan for 2020+
27
• Spring Batch 4.3.0-RC1 (Sep 16, 2020) and 4.3.0 (Oct, 2020)
• Bug fix releases for Spring Batch v4.2.x (Same EOL as Spring Boot v2.3)
• Bug fix releases for Spring Batch v4.3.x (Same EOL as Spring Boot v2.4)
• Spring Batch v5 (Spring Framework v6)
Thank you!
Q+A
springone.slack.com: #session-whats-new-in-spring-batch
#springone@springon
e

More Related Content

What's hot

Spring Boot Revisited with KoFu and JaFu
Spring Boot Revisited with KoFu and JaFuSpring Boot Revisited with KoFu and JaFu
Spring Boot Revisited with KoFu and JaFuVMware Tanzu
 
Spring Cloud Function: Where We Were, Where We Are, and Where We’re Going
Spring Cloud Function: Where We Were, Where We Are, and Where We’re GoingSpring Cloud Function: Where We Were, Where We Are, and Where We’re Going
Spring Cloud Function: Where We Were, Where We Are, and Where We’re GoingVMware Tanzu
 
Spring: Your Next Java Micro-Framework
Spring: Your Next Java Micro-FrameworkSpring: Your Next Java Micro-Framework
Spring: Your Next Java Micro-FrameworkVMware Tanzu
 
Spring Data JDBC: Beyond the Obvious
Spring Data JDBC: Beyond the ObviousSpring Data JDBC: Beyond the Obvious
Spring Data JDBC: Beyond the ObviousVMware Tanzu
 
Microservices with Java, Spring Boot and Spring Cloud
Microservices with Java, Spring Boot and Spring CloudMicroservices with Java, Spring Boot and Spring Cloud
Microservices with Java, Spring Boot and Spring CloudEberhard Wolff
 
Microservice With Spring Boot and Spring Cloud
Microservice With Spring Boot and Spring CloudMicroservice With Spring Boot and Spring Cloud
Microservice With Spring Boot and Spring CloudEberhard Wolff
 
Introduction to WebMvc.fn
Introduction to WebMvc.fnIntroduction to WebMvc.fn
Introduction to WebMvc.fnVMware Tanzu
 
A Series of Fortunate Events: Building an Operator in Java
A Series of Fortunate Events: Building an Operator in JavaA Series of Fortunate Events: Building an Operator in Java
A Series of Fortunate Events: Building an Operator in JavaVMware Tanzu
 
Spring IO 2016 - Spring Cloud Microservices, a journey inside a financial entity
Spring IO 2016 - Spring Cloud Microservices, a journey inside a financial entitySpring IO 2016 - Spring Cloud Microservices, a journey inside a financial entity
Spring IO 2016 - Spring Cloud Microservices, a journey inside a financial entityToni Jara
 
Ingress? That’s So 2020! Introducing the Kubernetes Gateway API
Ingress? That’s So 2020! Introducing the Kubernetes Gateway APIIngress? That’s So 2020! Introducing the Kubernetes Gateway API
Ingress? That’s So 2020! Introducing the Kubernetes Gateway APIVMware Tanzu
 
Walking Through Spring Cloud Data Flow
Walking Through Spring Cloud Data FlowWalking Through Spring Cloud Data Flow
Walking Through Spring Cloud Data FlowVMware Tanzu
 
Simplify Cloud Applications using Spring Cloud
Simplify Cloud Applications using Spring CloudSimplify Cloud Applications using Spring Cloud
Simplify Cloud Applications using Spring CloudRamnivas Laddad
 
Spring Native and Spring AOT
Spring Native and Spring AOTSpring Native and Spring AOT
Spring Native and Spring AOTVMware Tanzu
 
You Can Be Cloud Native, Too
You Can Be Cloud Native, TooYou Can Be Cloud Native, Too
You Can Be Cloud Native, TooVMware Tanzu
 
Spring cloud for microservices architecture
Spring cloud for microservices architectureSpring cloud for microservices architecture
Spring cloud for microservices architectureIgor Khotin
 
Micronaut: A new way to build microservices
Micronaut: A new way to build microservicesMicronaut: A new way to build microservices
Micronaut: A new way to build microservicesLuram Archanjo
 
Debugging Complex Issues in Web Applications
Debugging Complex Issues in Web ApplicationsDebugging Complex Issues in Web Applications
Debugging Complex Issues in Web ApplicationsVMware Tanzu
 
Weaving Through the Mesh: Making Sense of Istio and Overlapping Technologies
Weaving Through the Mesh: Making Sense of Istio and Overlapping TechnologiesWeaving Through the Mesh: Making Sense of Istio and Overlapping Technologies
Weaving Through the Mesh: Making Sense of Istio and Overlapping TechnologiesVMware Tanzu
 

What's hot (20)

Spring to Image
Spring to ImageSpring to Image
Spring to Image
 
Spring Boot Revisited with KoFu and JaFu
Spring Boot Revisited with KoFu and JaFuSpring Boot Revisited with KoFu and JaFu
Spring Boot Revisited with KoFu and JaFu
 
Spring Cloud Function: Where We Were, Where We Are, and Where We’re Going
Spring Cloud Function: Where We Were, Where We Are, and Where We’re GoingSpring Cloud Function: Where We Were, Where We Are, and Where We’re Going
Spring Cloud Function: Where We Were, Where We Are, and Where We’re Going
 
Spring: Your Next Java Micro-Framework
Spring: Your Next Java Micro-FrameworkSpring: Your Next Java Micro-Framework
Spring: Your Next Java Micro-Framework
 
Spring Data JDBC: Beyond the Obvious
Spring Data JDBC: Beyond the ObviousSpring Data JDBC: Beyond the Obvious
Spring Data JDBC: Beyond the Obvious
 
Microservices with Java, Spring Boot and Spring Cloud
Microservices with Java, Spring Boot and Spring CloudMicroservices with Java, Spring Boot and Spring Cloud
Microservices with Java, Spring Boot and Spring Cloud
 
Microservice With Spring Boot and Spring Cloud
Microservice With Spring Boot and Spring CloudMicroservice With Spring Boot and Spring Cloud
Microservice With Spring Boot and Spring Cloud
 
Introduction to WebMvc.fn
Introduction to WebMvc.fnIntroduction to WebMvc.fn
Introduction to WebMvc.fn
 
A Series of Fortunate Events: Building an Operator in Java
A Series of Fortunate Events: Building an Operator in JavaA Series of Fortunate Events: Building an Operator in Java
A Series of Fortunate Events: Building an Operator in Java
 
Spring IO 2016 - Spring Cloud Microservices, a journey inside a financial entity
Spring IO 2016 - Spring Cloud Microservices, a journey inside a financial entitySpring IO 2016 - Spring Cloud Microservices, a journey inside a financial entity
Spring IO 2016 - Spring Cloud Microservices, a journey inside a financial entity
 
Ingress? That’s So 2020! Introducing the Kubernetes Gateway API
Ingress? That’s So 2020! Introducing the Kubernetes Gateway APIIngress? That’s So 2020! Introducing the Kubernetes Gateway API
Ingress? That’s So 2020! Introducing the Kubernetes Gateway API
 
Walking Through Spring Cloud Data Flow
Walking Through Spring Cloud Data FlowWalking Through Spring Cloud Data Flow
Walking Through Spring Cloud Data Flow
 
Simplify Cloud Applications using Spring Cloud
Simplify Cloud Applications using Spring CloudSimplify Cloud Applications using Spring Cloud
Simplify Cloud Applications using Spring Cloud
 
Spring Native and Spring AOT
Spring Native and Spring AOTSpring Native and Spring AOT
Spring Native and Spring AOT
 
Springboot Microservices
Springboot MicroservicesSpringboot Microservices
Springboot Microservices
 
You Can Be Cloud Native, Too
You Can Be Cloud Native, TooYou Can Be Cloud Native, Too
You Can Be Cloud Native, Too
 
Spring cloud for microservices architecture
Spring cloud for microservices architectureSpring cloud for microservices architecture
Spring cloud for microservices architecture
 
Micronaut: A new way to build microservices
Micronaut: A new way to build microservicesMicronaut: A new way to build microservices
Micronaut: A new way to build microservices
 
Debugging Complex Issues in Web Applications
Debugging Complex Issues in Web ApplicationsDebugging Complex Issues in Web Applications
Debugging Complex Issues in Web Applications
 
Weaving Through the Mesh: Making Sense of Istio and Overlapping Technologies
Weaving Through the Mesh: Making Sense of Istio and Overlapping TechnologiesWeaving Through the Mesh: Making Sense of Istio and Overlapping Technologies
Weaving Through the Mesh: Making Sense of Istio and Overlapping Technologies
 

Similar to What’s New in Spring Batch?

Java EE8 - by Kito Mann
Java EE8 - by Kito Mann Java EE8 - by Kito Mann
Java EE8 - by Kito Mann Kile Niklawski
 
Spring 3.1: a Walking Tour
Spring 3.1: a Walking TourSpring 3.1: a Walking Tour
Spring 3.1: a Walking TourJoshua Long
 
Grails 3.0 Preview
Grails 3.0 PreviewGrails 3.0 Preview
Grails 3.0 Previewgraemerocher
 
Micronaut Deep Dive - Devoxx Belgium 2019
Micronaut Deep Dive - Devoxx Belgium 2019Micronaut Deep Dive - Devoxx Belgium 2019
Micronaut Deep Dive - Devoxx Belgium 2019graemerocher
 
Spring 3 - An Introduction
Spring 3 - An IntroductionSpring 3 - An Introduction
Spring 3 - An IntroductionThorsten Kamann
 
A Walking Tour of (almost) all of Springdom
A Walking Tour of (almost) all of Springdom A Walking Tour of (almost) all of Springdom
A Walking Tour of (almost) all of Springdom Joshua Long
 
Spring MVC framework
Spring MVC frameworkSpring MVC framework
Spring MVC frameworkMohit Gupta
 
201209 tech days .net 4.5 核心功能及綜覽
201209 tech days .net 4.5 核心功能及綜覽201209 tech days .net 4.5 核心功能及綜覽
201209 tech days .net 4.5 核心功能及綜覽Meng-Ru (Raymond) Tsai
 
Ajug - The Spring Update
Ajug - The Spring UpdateAjug - The Spring Update
Ajug - The Spring UpdateGunnar Hillert
 
Introducing Spring Framework 5.3
Introducing Spring Framework 5.3Introducing Spring Framework 5.3
Introducing Spring Framework 5.3VMware Tanzu
 
Elements for an iOS Backend
Elements for an iOS BackendElements for an iOS Backend
Elements for an iOS BackendLaurent Cerveau
 
Java EE 8 Update
Java EE 8 UpdateJava EE 8 Update
Java EE 8 UpdateRyan Cuprak
 
Spring Batch in Code - simple DB to DB batch applicaiton
Spring Batch in Code - simple DB to DB batch applicaitonSpring Batch in Code - simple DB to DB batch applicaiton
Spring Batch in Code - simple DB to DB batch applicaitontomi vanek
 
AAI-1713 Introduction to Java EE 7
AAI-1713 Introduction to Java EE 7AAI-1713 Introduction to Java EE 7
AAI-1713 Introduction to Java EE 7WASdev Community
 
AAI 1713-Introduction to Java EE 7
AAI 1713-Introduction to Java EE 7AAI 1713-Introduction to Java EE 7
AAI 1713-Introduction to Java EE 7Kevin Sutter
 

Similar to What’s New in Spring Batch? (20)

Java EE8 - by Kito Mann
Java EE8 - by Kito Mann Java EE8 - by Kito Mann
Java EE8 - by Kito Mann
 
Spring 3.1: a Walking Tour
Spring 3.1: a Walking TourSpring 3.1: a Walking Tour
Spring 3.1: a Walking Tour
 
Grails 3.0 Preview
Grails 3.0 PreviewGrails 3.0 Preview
Grails 3.0 Preview
 
Micronaut Deep Dive - Devoxx Belgium 2019
Micronaut Deep Dive - Devoxx Belgium 2019Micronaut Deep Dive - Devoxx Belgium 2019
Micronaut Deep Dive - Devoxx Belgium 2019
 
Get ready for spring 4
Get ready for spring 4Get ready for spring 4
Get ready for spring 4
 
Spring 3 - An Introduction
Spring 3 - An IntroductionSpring 3 - An Introduction
Spring 3 - An Introduction
 
A Walking Tour of (almost) all of Springdom
A Walking Tour of (almost) all of Springdom A Walking Tour of (almost) all of Springdom
A Walking Tour of (almost) all of Springdom
 
JSF2
JSF2JSF2
JSF2
 
Spring MVC framework
Spring MVC frameworkSpring MVC framework
Spring MVC framework
 
201209 tech days .net 4.5 核心功能及綜覽
201209 tech days .net 4.5 核心功能及綜覽201209 tech days .net 4.5 核心功能及綜覽
201209 tech days .net 4.5 核心功能及綜覽
 
Ajug - The Spring Update
Ajug - The Spring UpdateAjug - The Spring Update
Ajug - The Spring Update
 
Introducing Spring Framework 5.3
Introducing Spring Framework 5.3Introducing Spring Framework 5.3
Introducing Spring Framework 5.3
 
The Spring Update
The Spring UpdateThe Spring Update
The Spring Update
 
Elements for an iOS Backend
Elements for an iOS BackendElements for an iOS Backend
Elements for an iOS Backend
 
Java EE 8
Java EE 8Java EE 8
Java EE 8
 
Java EE 8 Update
Java EE 8 UpdateJava EE 8 Update
Java EE 8 Update
 
struts
strutsstruts
struts
 
Spring Batch in Code - simple DB to DB batch applicaiton
Spring Batch in Code - simple DB to DB batch applicaitonSpring Batch in Code - simple DB to DB batch applicaiton
Spring Batch in Code - simple DB to DB batch applicaiton
 
AAI-1713 Introduction to Java EE 7
AAI-1713 Introduction to Java EE 7AAI-1713 Introduction to Java EE 7
AAI-1713 Introduction to Java EE 7
 
AAI 1713-Introduction to Java EE 7
AAI 1713-Introduction to Java EE 7AAI 1713-Introduction to Java EE 7
AAI 1713-Introduction to Java EE 7
 

More from VMware Tanzu

What AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About ItWhat AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About ItVMware Tanzu
 
Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023VMware Tanzu
 
Enhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at ScaleEnhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at ScaleVMware Tanzu
 
Spring Update | July 2023
Spring Update | July 2023Spring Update | July 2023
Spring Update | July 2023VMware Tanzu
 
Platforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a ProductPlatforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a ProductVMware Tanzu
 
Building Cloud Ready Apps
Building Cloud Ready AppsBuilding Cloud Ready Apps
Building Cloud Ready AppsVMware Tanzu
 
Spring Boot 3 And Beyond
Spring Boot 3 And BeyondSpring Boot 3 And Beyond
Spring Boot 3 And BeyondVMware Tanzu
 
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdfSpring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdfVMware Tanzu
 
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023VMware Tanzu
 
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023VMware Tanzu
 
tanzu_developer_connect.pptx
tanzu_developer_connect.pptxtanzu_developer_connect.pptx
tanzu_developer_connect.pptxVMware Tanzu
 
Tanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - FrenchTanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - FrenchVMware Tanzu
 
Tanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - EnglishTanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - EnglishVMware Tanzu
 
Virtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - EnglishVirtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - EnglishVMware Tanzu
 
Tanzu Developer Connect - French
Tanzu Developer Connect - FrenchTanzu Developer Connect - French
Tanzu Developer Connect - FrenchVMware Tanzu
 
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023VMware Tanzu
 
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring BootSpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring BootVMware Tanzu
 
SpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software EngineerSpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software EngineerVMware Tanzu
 
SpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs PracticeSpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs PracticeVMware Tanzu
 
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense SolutionsSpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense SolutionsVMware Tanzu
 

More from VMware Tanzu (20)

What AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About ItWhat AI Means For Your Product Strategy And What To Do About It
What AI Means For Your Product Strategy And What To Do About It
 
Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023Make the Right Thing the Obvious Thing at Cardinal Health 2023
Make the Right Thing the Obvious Thing at Cardinal Health 2023
 
Enhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at ScaleEnhancing DevEx and Simplifying Operations at Scale
Enhancing DevEx and Simplifying Operations at Scale
 
Spring Update | July 2023
Spring Update | July 2023Spring Update | July 2023
Spring Update | July 2023
 
Platforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a ProductPlatforms, Platform Engineering, & Platform as a Product
Platforms, Platform Engineering, & Platform as a Product
 
Building Cloud Ready Apps
Building Cloud Ready AppsBuilding Cloud Ready Apps
Building Cloud Ready Apps
 
Spring Boot 3 And Beyond
Spring Boot 3 And BeyondSpring Boot 3 And Beyond
Spring Boot 3 And Beyond
 
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdfSpring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
Spring Cloud Gateway - SpringOne Tour 2023 Charles Schwab.pdf
 
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
Simplify and Scale Enterprise Apps in the Cloud | Boston 2023
 
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
Simplify and Scale Enterprise Apps in the Cloud | Seattle 2023
 
tanzu_developer_connect.pptx
tanzu_developer_connect.pptxtanzu_developer_connect.pptx
tanzu_developer_connect.pptx
 
Tanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - FrenchTanzu Virtual Developer Connect Workshop - French
Tanzu Virtual Developer Connect Workshop - French
 
Tanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - EnglishTanzu Developer Connect Workshop - English
Tanzu Developer Connect Workshop - English
 
Virtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - EnglishVirtual Developer Connect Workshop - English
Virtual Developer Connect Workshop - English
 
Tanzu Developer Connect - French
Tanzu Developer Connect - FrenchTanzu Developer Connect - French
Tanzu Developer Connect - French
 
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
Simplify and Scale Enterprise Apps in the Cloud | Dallas 2023
 
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring BootSpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
SpringOne Tour: Deliver 15-Factor Applications on Kubernetes with Spring Boot
 
SpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software EngineerSpringOne Tour: The Influential Software Engineer
SpringOne Tour: The Influential Software Engineer
 
SpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs PracticeSpringOne Tour: Domain-Driven Design: Theory vs Practice
SpringOne Tour: Domain-Driven Design: Theory vs Practice
 
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense SolutionsSpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
SpringOne Tour: Spring Recipes: A Collection of Common-Sense Solutions
 

Recently uploaded

Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...soniya singh
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio, Inc.
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number SystemsJheuzeDellosa
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfkalichargn70th171
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsAlberto González Trastoy
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVshikhaohhpro
 
chapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptchapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptkotipi9215
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software DevelopersVinodh Ram
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideChristina Lin
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityNeo4j
 
Engage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The UglyEngage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The UglyFrank van der Linden
 
Hand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxHand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxbodapatigopi8531
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...MyIntelliSource, Inc.
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...stazi3110
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...kellynguyen01
 
Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...aditisharan08
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)OPEN KNOWLEDGE GmbH
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdfWave PLM
 
Salesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantSalesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantAxelRicardoTrocheRiq
 

Recently uploaded (20)

Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
Russian Call Girls in Karol Bagh Aasnvi ➡️ 8264348440 💋📞 Independent Escort S...
 
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed DataAlluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
Alluxio Monthly Webinar | Cloud-Native Model Training on Distributed Data
 
What is Binary Language? Computer Number Systems
What is Binary Language?  Computer Number SystemsWhat is Binary Language?  Computer Number Systems
What is Binary Language? Computer Number Systems
 
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdfThe Ultimate Test Automation Guide_ Best Practices and Tips.pdf
The Ultimate Test Automation Guide_ Best Practices and Tips.pdf
 
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time ApplicationsUnveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
Unveiling the Tech Salsa of LAMs with Janus in Real-Time Applications
 
Optimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTVOptimizing AI for immediate response in Smart CCTV
Optimizing AI for immediate response in Smart CCTV
 
chapter--4-software-project-planning.ppt
chapter--4-software-project-planning.pptchapter--4-software-project-planning.ppt
chapter--4-software-project-planning.ppt
 
Professional Resume Template for Software Developers
Professional Resume Template for Software DevelopersProfessional Resume Template for Software Developers
Professional Resume Template for Software Developers
 
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop SlideBuilding Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
Building Real-Time Data Pipelines: Stream & Batch Processing workshop Slide
 
Exploring iOS App Development: Simplifying the Process
Exploring iOS App Development: Simplifying the ProcessExploring iOS App Development: Simplifying the Process
Exploring iOS App Development: Simplifying the Process
 
EY_Graph Database Powered Sustainability
EY_Graph Database Powered SustainabilityEY_Graph Database Powered Sustainability
EY_Graph Database Powered Sustainability
 
Engage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The UglyEngage Usergroup 2024 - The Good The Bad_The Ugly
Engage Usergroup 2024 - The Good The Bad_The Ugly
 
Hand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptxHand gesture recognition PROJECT PPT.pptx
Hand gesture recognition PROJECT PPT.pptx
 
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
Try MyIntelliAccount Cloud Accounting Software As A Service Solution Risk Fre...
 
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
Building a General PDE Solving Framework with Symbolic-Numeric Scientific Mac...
 
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
Short Story: Unveiling the Reasoning Abilities of Large Language Models by Ke...
 
Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...Unit 1.1 Excite Part 1, class 9, cbse...
Unit 1.1 Excite Part 1, class 9, cbse...
 
Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)Der Spagat zwischen BIAS und FAIRNESS (2024)
Der Spagat zwischen BIAS und FAIRNESS (2024)
 
5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf5 Signs You Need a Fashion PLM Software.pdf
5 Signs You Need a Fashion PLM Software.pdf
 
Salesforce Certified Field Service Consultant
Salesforce Certified Field Service ConsultantSalesforce Certified Field Service Consultant
Salesforce Certified Field Service Consultant
 

What’s New in Spring Batch?

  • 1. What’s new in Spring Batch 4.3? Mahmoud Ben Hassine September 2–3, 2020 springone.io
  • 2. Safe Harbor Statement The following is intended to outline the general direction of VMware's offerings. It is intended for information purposes only and may not be incorporated into any contract. Any information regarding pre-release of VMware offerings, future updates or other planned modifications is subject to ongoing evaluation by VMware and is subject to change. This information is provided without warranty or any kind, express or implied, and is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions regarding VMware's offerings. These purchasing decisions should only be based on features currently available. The development, release, and timing of any features or functionality described for VMware's offerings in this presentation remain at the sole discretion of VMware. VMware has no obligation to update forward looking information in this presentation. 2
  • 3. About me 3 • Principal Software Engineer at VMware • Spring Batch Co-Lead • Open Source enthusiast Github: @benas Twitter: @b_e_n_a_s Mahmoud Ben Hassine
  • 4. Agenda 4 • Current status • What’s new in Spring Batch 4.3? • New features • Performance improvements • Dependencies updates • Deprecations and technical debt • What’s next? • Q+A
  • 6. History of Spring Batch (1/2) 6 • Step scope • Chunk-oriented processing • Remote chunking/partitioning • Java 5 • Spring Framework 3 v2.0 Apr 11, 2009 • Initial APIs • Item-oriented processing • XML configuration • Java 1.4 • Spring Framework 2.5 • Job scope • JSR-352 support • SQLite support • Spring Batch Integration • Spring Boot support • Builders for readers • Builders for writers • Java 8 • Spring Framework 5 v3.0 May 22, 2014 v1.0 Mar 28, 2008 v4.0 Dec 1, 2017
  • 7. History of Spring Batch (2/2) 7 • @SpringBatchTest annotation • @EnableBatchIntegration annotation • JSR 380 Bean Validation support • Json reader/writer • JSR 305 support v4.1 Oct 29, 2018 • Apache Avro support • Apache Kafka support • Micrometer support • Performance improvements • Java 14 records support • GraalVM support • Kafka support refinement • Performance improvements • Deprecations • Builders for readers • Builders for writers • Java 8 • Spring Framework 5 v4.3 Oct XX, 2020 v4.2 Oct 02, 2019 v4.0 Dec 1, 2017 v5.0 XXX XX, 20XX • Spring Framework 6 • Java XX • TBD
  • 8. History of Spring Batch (2/2) 8 • @SpringBatchTest annotation • @EnableBatchIntegration annotation • JSR 380 Bean Validation support • Json reader/writer • JSR 305 support v4.1 Oct 29, 2018 • Apache Avro support • Apache Kafka support • Micrometer support • Performance improvements • Java 14 records support • GraalVM support • Kafka support refinement • Performance improvements • Deprecations • Builders for readers • Builders for writers • Java 8 • Spring Framework 5 v4.3 Oct XX, 2020 v4.2 Oct 02, 2019 v4.0 Dec 1, 2017 v5.0 XXX XX, 20XX • Spring Framework 6 • Java XX • TBD
  • 9. What’s new in v4.3? (currently in M2)
  • 11. Java 14 records support 11 • Use records as items in chunk-oriented steps • Leverage Spring Framework support for records id,name 1,foo 2,bar persons.csv FlatFileItemReader<Person> reader = new FlatFileItemReaderBuilder<Person>() .name("personItemReader") .resource(new FileSystemResource("persons.csv")) .delimited() .names("id", "name") .targetType(Person.class) .build(); public class Person { private int id; Private String name; // constructors // getters and setters // equals and hashcode // toString } public record Person(int id, String name) {}
  • 12. GraalVM support 12 • Leverage Spring Framework support for GraalVM • Spring Batch jobs run correctly on GraalVM • Reflection • Proxies • etc Faster startup time + Better memory usage
  • 13. Kafka support refinement 13 • Ability to start reading from a custom offset in a given partition • Ability to start reading from the offset stored in Kafka Image source: http://kafka.apache.org/intro v4.3: read from custom offsetv4.2: read from the beginning
  • 14. Support for annotation-based job execution listeners 14 class MyListener implements JobExecutionListener { @Override public void beforeJob(JobExecution jobExecution) { // do something before job execution } @Override public void afterJob(JobExecution jobExecution) { // do something after job execution } } class MyListener { @BeforeJob public void beforeJob(JobExecution jobExecution) { // do something before job execution } @AfterJob public void afterJob(JobExecution jobExecution) { // do something after job execution } } v4.2: interface-based listeners v4.3: interface-based + annotation-based listeners
  • 15. Add SynchronizedItemStreamWriter 15 @Bean public StaxEventItemWriter<Person> itemWriter() { Jaxb2Marshaller marchaller = new Jaxb2Marshaller(); marchaller.setClassesToBeBound(Person.class); return new StaxEventItemWriterBuilder<Person>() .name("personItemWriter") .resource(new FileSystemResource("persons.xml")) .marshaller(marchaller) .rootTagName("persons") .build(); } Expected output • Some item writers are not safe to use in a multi-threaded step (StaxEventItemWriter, JsonItemWriter, etc) <persons> <person> <id>1</id> <name>foo</name> </person> <person> <id>2</id> <name>foo</name> </person> </persons> Actual output <persons> <name>foo</name> <person> <id>1</id> </person> <id>2<person> <name>foo</name> </id> </person> </persons> Item writer bean definition
  • 16. Add SynchronizedItemStreamWriter 16 @Bean public SynchronizedItemStreamWriter<Person> itemWriter() { Jaxb2Marshaller marchaller = new Jaxb2Marshaller(); marchaller.setClassesToBeBound(Person.class); StaxEventItemWriter<Person> personWriter = new StaxEventItemWriterBuilder<Person>() .name("personItemWriter") .resource(new FileSystemResource("persons.xml")) .marshaller(marchaller) .rootTagName("persons") .build(); SynchronizedItemStreamWriter<Person> synchronizedPersonWriter = new SynchronizedItemStreamWriter<>(); synchronizedPersonWriter.setDelegate(personWriter); return synchronizedPersonWriter; } • Some item writers are not safe to use in a multi-threaded step (StaxEventItemWriter, JsonItemWriter, etc) => SynchronizedItemStreamWriter to the rescue!
  • 17. Other new features 17 • Add JpaNamedQueryProvider • Add encoding parameter in StaxEventItemReader • Micrometer support improvements • Add DataFieldMaxValueJobParametersIncrementer • etc https://spring.io/blog/2020/08/13/spring-batch-4-3-0-m2-is-out https://spring.io/blog/2020/06/26/spring-batch-4-3-0-m1-is-released-now
  • 19. for(item in chunk) { mongoTemplate.save(item); } v4.2 (pseudo code) BulkOperations bulkOperations = mongoTemplate.bulkOps(); for(item in chunk) { bulkOperation.add(item); } bulkOperations.execute(); v4.3 (pseudo code) Use bulk operations in MongoItemWriter 19 https://github.com/benas/spring-batch-lab/tree/master/issues/gh3713
  • 20. for(item in chunk) { repository.save(item); } v4.2 (pseudo code) repository.saveAll(items); v4.3 (pseudo code) Use bulk operations in RepositoryItemWriter 20 https://github.com/benas/spring-batch-lab/tree/master/issues/gh3720
  • 21. int getStepExecutionCount(JobInstance jobInstance, String stepName) { int count = 0; List<JobExecution> jobExecutions = findJobExecutions(jobInstance); for (JobExecution jobExecution : jobExecutions) { List<StepExecution> stepExecutions = findStepExecutions(jobExecution); count += countStepExecutions(stepExecutions, stepName); } return count; } v4.2 (pseudo code) v4.3 (pseudo code) int getStepExecutionCount(JobInstance jobInstance, String stepName) { String query = “select count(id) from ... where ...”; return jdbcTemplate.queryForObject( query, new Object[] {jobInstance, stepName}, Integer.class); } Job/Step start time improvement 21 https://github.com/benas/spring-batch-lab/tree/master/issues/gh3657
  • 23. Dependencies updates 23 • Spring Framework 5.3 • Spring Integration 5.4 • Spring Data 2020.0 • Spring AMQP 2.3.0 • Spring for Apache Kafka 2.6.0 • Micrometer 1.5.3
  • 25. Deprecations and technical debt 25 • API deprecation in preparation for v5 • Improve build process • Improve test infrastructure • Docker-based tests with testcontainers • Junit 5 • Improve test coverage • etc
  • 27. Release plan for 2020+ 27 • Spring Batch 4.3.0-RC1 (Sep 16, 2020) and 4.3.0 (Oct, 2020) • Bug fix releases for Spring Batch v4.2.x (Same EOL as Spring Boot v2.3) • Bug fix releases for Spring Batch v4.3.x (Same EOL as Spring Boot v2.4) • Spring Batch v5 (Spring Framework v6)