How terasoluna-batch/v5-sample works
Project type and purpose
• This is a Maven‐based blank archetype for building batch applications on top of Spring Batch, Spring Framework, and MyBatis (via the TERASOLUNA Batch Framework for Java 5.x).
• It provides two parallel configurations: Java‐based (config/javaconfig) and XML‐based (config/xmlconfig) to bootstrap a batch job (job01) that reads, processes, and writes Employee data.
File structure
• Top‐level “config” directory holds:
• config/javaconfig: Java @Configuration classes (AsyncBatchDaemonConfig, JobBaseContextConfig, LaunchContextConfig, TerasolunaBatchConfiguration, plus job‐specific Job01Config).
• config/xmlconfig: spring XMLs for daemon, base context, launch context, and job definitions (job01.xml).
• The sample application skeleton under terasoluna-batch-blankproject includes:
• src/main/java/.../projectName/job01: domain (Employee), processor, repository interfaces.
• src/main/resources/META‑INF/spring or resources/…/job01: XML bean definitions or MyBatis mapper XML (EmployeeRepository.xml).
• batch-application.properties, logback.xml, i18n messages for externalizing config.
• Build and run scripts invoked via CommandLineJobRunner (org.springframework.batch.core.launch.support.CommandLineJobRunner).
Key points from README
• It’s purely a batch job template; users generate their own groupId/artifactId and pick Java or XML style.
• Run by packaging via Maven, then launching CommandLineJobRunner with either the Java config class or the XML job file.
Final checklist
• All major Spring Batch elements (JobLauncher, JobRepository, Step, Chunk)
• Job definition beans (JavaConfig class or XML job file)
• Processor and Repository roles
• DataSource/Transaction Manager/MyBatis integration
• External Relational Database
• Properties and i18n message sources
• CLI/runner entry point