Skip to content

This Spring Batch setup is designed to handle batch processing of data. It reads data from a CSV file, processes it by converting names to uppercase, and writes the processed data to a database table. It includes components like ItemReader, ItemProcessor, ItemWriter, and a Job definition.

Notifications You must be signed in to change notification settings

rebeccaorso/Spring_Batch

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 

Repository files navigation

Spring Batch Example

This repository contains a basic example of using Spring Batch for batch processing of data. The example reads data from a CSV file, processes it, and writes the processed data to a database table.

Components

  • ItemReader: Reads data from the CSV file.
  • ItemProcessor: Processes the data by converting names to uppercase.
  • ItemWriter: Writes the processed data to a database table.
  • Job: Defines the batch job, including the sequence of steps to be executed.
  • JobExecutionListener: Handles post-job execution tasks, such as logging job completion status and verifying results in the database.

Usage

To run the example, ensure you have Java and Maven installed on your system. Then, clone this repository and navigate to the project directory.

This will execute the Spring Boot application, which will read data from the CSV file, process it, and write it to the database.


Esempio di Spring Batch

Questa repository contiene un esempio di base sull'utilizzo di Spring Batch per l'elaborazione in batch dei dati. L'esempio legge i dati da un file CSV, li elabora e scrive i dati elaborati su una tabella del database.

Componenti

  • ItemReader: Legge i dati dal file CSV.
  • ItemProcessor: Elabora i dati convertendo i nomi in maiuscolo.
  • ItemWriter: Scrive i dati elaborati su una tabella del database.
  • Job: Definisce il job in batch, inclusa la sequenza di passaggi da eseguire.
  • JobExecutionListener: Gestisce le attività post-elaborazione del job, come il logging dello stato di completamento del job e la verifica dei risultati nel database.

Utilizzo

Per eseguire l'esempio, assicurarsi di avere Java e Maven installati sul proprio sistema. Quindi, clonare questa repository e navigare nella directory del progetto.

Questo eseguirà l'applicazione Spring Boot, che leggerà i dati dal file CSV, li elaborerà e li scriverà sul database.

About

This Spring Batch setup is designed to handle batch processing of data. It reads data from a CSV file, processes it by converting names to uppercase, and writes the processed data to a database table. It includes components like ItemReader, ItemProcessor, ItemWriter, and a Job definition.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages