# Deprecated API

## Contents

- Deprecated Classes
- Deprecated Methods
- Deprecated Constructors

- Deprecated Classes
  Class and Description
  org.springframework.batch.test.AbstractJobTests (from 2.1) use `JobLauncherTestUtils` instead
  org.springframework.batch.core.configuration.support.ClassPathXmlApplicationContextFactory use `GenericApplicationContextFactory` instead
  org.springframework.batch.core.configuration.support.ClassPathXmlJobRegistry in version 2.1, please us `AutomaticJobRegistrar` instead
  org.springframework.batch.item.database.support.ListPreparedStatementSetter use `ArgumentPreparedStatementSetter` instead.
  org.springframework.batch.integration.chunk.RemoteChunkingMasterStepBuilder Use `RemoteChunkingManagerStepBuilder` instead.
  org.springframework.batch.integration.chunk.RemoteChunkingMasterStepBuilderFactory Use `RemoteChunkingManagerStepBuilderFactory` instead.
  org.springframework.batch.integration.partition.RemotePartitioningMasterStepBuilder Use `RemotePartitioningManagerStepBuilder` instead.
  org.springframework.batch.integration.partition.RemotePartitioningMasterStepBuilderFactory Use `RemotePartitioningManagerStepBuilderFactory` instead
  org.springframework.batch.core.repository.dao.XStreamExecutionContextStringSerializer Due to the incompatibilities between current Jettison versions and XStream versions, this serializer is deprecated in favor of `Jackson2ExecutionContextStringSerializer`

- Deprecated Methods
  Method and Description
  org.springframework.batch.item.database.HibernateItemWriter.doWrite(HibernateOperations, List<? extends T>) As of 2.2 in favor of using Hibernate's session management APIs directly
  org.springframework.batch.core.JobParameters.getDouble(String, double) Use `JobParameters.getDouble(java.lang.String, java.lang.Double)` instead. This method will be removed in a future release.
  org.springframework.batch.core.repository.support.AbstractJobRepositoryFactoryBean.getJobRepository() use `AbstractJobRepositoryFactoryBean.getObject()` instead
  org.springframework.batch.core.JobParameters.getLong(String, long) Use `JobParameters.getLong(java.lang.String, java.lang.Long)` instead. This method will be removed in a future release.
  org.springframework.batch.core.partition.support.SimpleStepExecutionSplitter.getStartable(StepExecution, ExecutionContext) This method is deprecated in favor of `SimpleStepExecutionSplitter.isStartable(org.springframework.batch.core.StepExecution, org.springframework.batch.item.ExecutionContext)` and will be removed in a future version.
  org.springframework.batch.integration.config.annotation.BatchIntegrationConfiguration.remoteChunkingMasterStepBuilderFactory()
  org.springframework.batch.integration.config.annotation.BatchIntegrationConfiguration.remotePartitioningMasterStepBuilderFactory()
  org.springframework.batch.item.database.support.ListPreparedStatementSetter.setParameters(List<?>) In favor of the constructor
  org.springframework.batch.item.util.FileUtils.setUpOutputFile(File, boolean, boolean) use the version with explicit append parameter instead. Here append=false is assumed.
  org.springframework.batch.item.database.builder.HibernatePagingItemReaderBuilder.useSatelessSession(boolean) This method is deprecated in favor of `HibernatePagingItemReaderBuilder.useStatelessSession(boolean)` and will be removed in a future version.

- Deprecated Constructors
  Constructor and Description
  org.springframework.batch.core.partition.support.SimpleStepExecutionSplitter(JobRepository, Step, Partitioner) use `SimpleStepExecutionSplitter.SimpleStepExecutionSplitter(JobRepository, boolean, String, Partitioner)` instead