Book Image

Mastering Spring Application Development

By : Anjana Mankale
Book Image

Mastering Spring Application Development

By: Anjana Mankale

Overview of this book

Table of Contents (19 chapters)
Mastering Spring Application Development
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Architecture of a batch job


Let's depict the basic architecture of a batch processor; we can also see the components involved in the batch processing. From the following diagram you can figure out the main components of Spring Batch:

Let's now have a look at the components individually.

  • JobRepository: This container is where we need to register our jobs or processes.

  • JobOperator: This is the one that triggers the registered job. It also provides APIs for accessing the register. It is an interface.

  • Job: It is a process or task in the jobRepository. This consists of one more step.

  • Step: This actually contains the logic that needs to be executed. Each step consists of an ItemReader, ItemProcessor, and ItemWriter interface. First, the ItemReader interface reads one step at a time in a job and gives it to ItemProcessor which processes the job. For example, it might collect some data required. Then, the ItemWriter interface writes the data to the database or it might execute a transaction or log...