Fix javadoc errors and warnings

Resolves #1624
This commit is contained in:
Mahmoud Ben Hassine
2023-07-05 15:25:51 +02:00
parent 060c96f01f
commit f82c16b825
151 changed files with 316 additions and 362 deletions

View File

@@ -39,7 +39,7 @@ public class Entity implements Serializable {
/**
* Default constructor for {@link Entity}.
*
* <p>
* The ID defaults to zero.
*/
public Entity() {

View File

@@ -23,7 +23,7 @@ import java.io.StringWriter;
/**
* Value object used to carry information about the status of a job or step execution.
*
* <p>
* {@code ExitStatus} is immutable and, therefore, thread-safe.
*
* @author Dave Syer

View File

@@ -305,7 +305,7 @@ public class JobExecution extends Entity {
/**
* Package-private method for re-constituting the step executions from existing
* instances.
* @param The {@code stepExecution} execution to be added.
* @param stepExecution The {@code stepExecution} execution to be added.
*/
void addStepExecution(StepExecution stepExecution) {
stepExecutions.add(stepExecution);

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2022 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -22,7 +22,7 @@ import org.springframework.util.Assert;
* Batch domain object representing a uniquely identifiable job run. {@code JobInstance}
* can be restarted multiple times in case of execution failure, and its lifecycle ends
* with first successful execution.
*
* <p>
* Trying to execute an existing {@code JobInstance} that has already completed
* successfully results in an error. An error is also raised for an attempt to restart a
* failed {@code JobInstance} if the {@code Job} is not restartable.

View File

@@ -40,7 +40,7 @@ import org.springframework.util.Assert;
* order to determine if one {@code JobParameters} object equals another. Furthermore,
* because these parameters need to be persisted, it is vital that the types added are
* restricted.
*
* <p>
* This class is immutable and, therefore, thread-safe.
*
* @author Lucas Ward

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2022 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -39,7 +39,7 @@ public interface StepExecutionListener extends StepListener {
* Give a listener a chance to modify the exit status from a step. The value returned
* is combined with the normal exit status by using
* {@link ExitStatus#and(ExitStatus)}.
*
* <p>
* Called after execution of the step's processing logic (whether successful or
* failed). Throwing an exception in this method has no effect, as it is only logged.
* @param stepExecution a {@link StepExecution} instance.

View File

@@ -74,7 +74,7 @@ import org.springframework.transaction.annotation.Isolation;
/**
* Base {@link Configuration} class that provides common JDBC-based infrastructure beans
* for enabling and using Spring Batch.
*
* <p>
* This configuration class configures and registers the following beans in the
* application context:
*
@@ -89,10 +89,8 @@ import org.springframework.transaction.annotation.Isolation;
* </ul>
*
* Customization is possible by extending the class and overriding getters.
*
* A typical usage of this class is as follows:
*
* <pre class="code">
* <p>
* A typical usage of this class is as follows: <pre class="code">
* &#064;Configuration
* public class MyJobConfiguration extends DefaultBatchConfiguration {
*

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2022 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -138,9 +138,6 @@ public class GenericApplicationContextFactory extends AbstractApplicationContext
private final ApplicationContextHelper helper;
/**
* @param parent
*/
public ResourceXmlApplicationContext(ConfigurableApplicationContext parent, Object... resources) {
class ResourceXmlApplicationContextHelper extends ApplicationContextHelper {

View File

@@ -265,7 +265,7 @@ public class ChunkElementParser {
/**
* Handle the adapter method attribute by using an
* {@link AbstractMethodInvokingDelegator}.
* {@link org.springframework.batch.item.adapter.AbstractMethodInvokingDelegator}.
*/
private void handleAdapterMethodAttribute(String propertyName, String adapterClassName,
MutablePropertyValues stepPvs, Element element) {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2021 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -60,8 +60,8 @@ public class CoreNamespacePostProcessor
/**
* Automatically inject job-repository from a job into its steps. Only inject if the
* step is an AbstractStep or StepParserStepFactoryBean.
* @param beanName
* @param beanFactory
* @param beanName the bean name
* @param beanFactory the bean factory
*/
private void injectJobRepositoryIntoSteps(String beanName, ConfigurableListableBeanFactory beanFactory) {
BeanDefinition bd = beanFactory.getBeanDefinition(beanName);
@@ -87,8 +87,8 @@ public class CoreNamespacePostProcessor
/**
* If any of the beans in the parent hierarchy is a &lt;step/&gt; with a
* &lt;tasklet/&gt;, then the bean class must be {@link StepParserStepFactoryBean}.
* @param beanName
* @param beanFactory
* @param beanName the bean name
* @param beanFactory the bean factory
*/
private void overrideStepClass(String beanName, ConfigurableListableBeanFactory beanFactory) {
BeanDefinition bd = beanFactory.getBeanDefinition(beanName);
@@ -111,8 +111,8 @@ public class CoreNamespacePostProcessor
* <li>Inject "transactionManager" into any {@link StepParserStepFactoryBean} without
* a transactionManager.
* </ul>
* @param bean
* @return
* @param bean the bean object
* @return the bean with default collaborators injected into it
*/
private Object injectDefaults(Object bean) {
if (bean instanceof JobParserJobFactoryBean) {

View File

@@ -103,7 +103,7 @@ public class CoreNamespaceUtils {
/**
* Register a {@link Comparator} to be used to sort {@link StateTransition} objects.
* @param parserContext
* @param parserContext the parser context
*/
private static void addStateTransitionComparator(ParserContext parserContext) {
BeanDefinitionRegistry registry = parserContext.getRegistry();
@@ -122,7 +122,7 @@ public class CoreNamespaceUtils {
/**
* Register a {@code RangePropertyEditor}, if one does not already exist.
* @param parserContext
* @param parserContext the parser context
*/
private static void addRangePropertyEditor(ParserContext parserContext) {
BeanDefinitionRegistry registry = parserContext.getRegistry();
@@ -164,7 +164,7 @@ public class CoreNamespaceUtils {
/**
* Add a core name postprocessor.
* @param parserContext
* @param parserContext the parser context
*/
private static void addCoreNamespacePostProcessor(ParserContext parserContext) {
BeanDefinitionRegistry registry = parserContext.getRegistry();

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2012-2022 the original author or authors.
* Copyright 2012-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -137,8 +137,8 @@ public class SimpleFlowFactoryBean implements FactoryBean<SimpleFlow>, Initializ
* Convenience method to get a state that proxies the input but with a different name,
* appropriate to this flow. If the state is a {@link StepState}, the step name is
* also changed.
* @param state
* @return
* @param state the state to proxy
* @return the proxy state
*/
private State getProxyState(State state) {
String oldName = state.getName();

View File

@@ -552,7 +552,7 @@ public class StepParserStepFactoryBean<I, O> implements FactoryBean<Step>, BeanN
* present).
* @param value The value of the other field.
* @param twoWayDependency Set to {@code true} if both depend on each other.
* @throws an IllegalArgumentException if either condition is violated
* @throws IllegalArgumentException if either condition is violated
*/
private void validateDependency(String dependentName, Object dependentValue, String name, Object value,
boolean twoWayDependency) {

View File

@@ -21,7 +21,7 @@ import org.springframework.core.convert.converter.Converter;
/**
* {@link Converter} implementation from {@link java.util.Date} to {@link String}.
*
* <p>
* This converter formats dates according to the
* {@link java.time.format.DateTimeFormatter#ISO_INSTANT} format.
*

View File

@@ -32,9 +32,9 @@ import org.springframework.util.StringUtils;
/**
* Converter for {@link JobParameters} instances that uses a simple naming convention for
* converting job parameters. The expected notation is the following:
*
* <p>
* key=value,type,identifying
*
* <p>
* where:
*
* <ul>
@@ -47,12 +47,12 @@ import org.springframework.util.StringUtils;
*
* For example, schedule.date=2022-12-12,java.time.LocalDate will be converted to an
* identifying job parameter of type {@link java.time.LocalDate} with value "2022-12-12".
*
* <p>
* The literal values are converted to the target type by using the default Spring
* conversion service, augmented if necessary by any custom converters. The conversion
* service should be configured with a converter to and from string literals to job
* parameter types.
*
* <p>
* By default, the Spring conversion service is augmented to support the conversion of the
* following types:
*

View File

@@ -24,10 +24,10 @@ import org.springframework.batch.core.JobParameters;
/**
* Converter for {@link JobParameters} instances that uses a JSON naming convention for
* converting job parameters. The expected notation is the following:
*
* <p>
* key='{"value": "parameterStringLiteralValue",
* "type":"fully.qualified.name.of.the.parameter.Type", "identifying": "booleanValue"}'
*
* <p>
* where:
*
* <ul>
@@ -41,12 +41,12 @@ import org.springframework.batch.core.JobParameters;
* For example, schedule.date={"value": "2022-12-12", "type":"java.time.LocalDate",
* "identifying": "false"} will be converted to a non identifying job parameter of type
* {@link java.time.LocalDate} with value "2022-12-12".
*
* <p>
* The literal values are converted to the correct type by using the default Spring
* conversion service, augmented if necessary by any custom converters. The conversion
* service should be configured with a converter to and from string literals to job
* parameter types.
*
* <p>
* By default, the Spring conversion service is augmented to support the conversion of the
* following types:
*

View File

@@ -22,7 +22,7 @@ import org.springframework.core.convert.converter.Converter;
/**
* {@link Converter} implementation from {@link LocalDateTime} to {@link String}.
*
* <p>
* This converter formats dates according to the
* {@link DateTimeFormatter#ISO_LOCAL_DATE_TIME} format.
*

View File

@@ -21,7 +21,7 @@ import org.springframework.core.convert.converter.Converter;
/**
* {@link Converter} implementation from {@link LocalDate} to {@link String}.
*
* <p>
* This converter formats dates according to the
* {@link java.time.format.DateTimeFormatter#ISO_LOCAL_DATE} format.
*

View File

@@ -22,7 +22,7 @@ import org.springframework.core.convert.converter.Converter;
/**
* {@link Converter} implementation from {@link LocalTime} to {@link String}.
*
* <p>
* This converter formats times according to the {@link DateTimeFormatter#ISO_LOCAL_TIME}
* format.
*

View File

@@ -22,7 +22,7 @@ import org.springframework.core.convert.converter.Converter;
/**
* {@link Converter} implementation from {@link String} to {@link java.util.Date}.
*
* <p>
* This converter expects strings in the
* {@link java.time.format.DateTimeFormatter#ISO_INSTANT} format.
*

View File

@@ -21,7 +21,7 @@ import org.springframework.core.convert.converter.Converter;
/**
* {@link Converter} implementation from {@link String} to {@link LocalDate}.
*
* <p>
* This converter expects strings in the
* {@link java.time.format.DateTimeFormatter#ISO_LOCAL_DATE} format.
*

View File

@@ -21,7 +21,7 @@ import org.springframework.core.convert.converter.Converter;
/**
* {@link Converter} implementation from {@link String} to {@link LocalDateTime}.
*
* <p>
* This converter expects strings in the
* {@link java.time.format.DateTimeFormatter#ISO_LOCAL_DATE_TIME} format.
*

View File

@@ -21,7 +21,7 @@ import org.springframework.core.convert.converter.Converter;
/**
* {@link Converter} implementation from {@link String} to {@link LocalTime}.
*
* <p>
* This converter expects strings in the
* {@link java.time.format.DateTimeFormatter#ISO_LOCAL_TIME} format.
*

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2022 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -113,7 +113,7 @@ public interface JobExplorer {
* depending on the implementation. In that case, use
* {@link #getStepExecution(Long, Long)} to hydrate them.
* @param jobInstance The {@link JobInstance} to query.
* @return the set of all executions for the specified {@link JobInstance}.
* @return the list of all executions for the specified {@link JobInstance}.
*/
List<JobExecution> getJobExecutions(JobInstance jobInstance);
@@ -145,7 +145,7 @@ public interface JobExplorer {
/**
* Query the repository for all unique {@link JobInstance} names (sorted
* alphabetically).
* @return the set of job names that have been executed.
* @return the list of job names that have been executed.
*/
List<String> getJobNames();

View File

@@ -98,7 +98,7 @@ public class JobExplorerFactoryBean extends AbstractJobExplorerFactoryBean imple
/**
* Sets the data source.
*
* <p>
* Public setter for the {@link DataSource}.
* @param dataSource A {@code DataSource}.
*/

View File

@@ -572,7 +572,7 @@ public class FlowBuilder<Q> {
*
* In this example, a flow consisting of <code>step1</code> will be executed in
* parallel with <code>flow</code>.
*
* <p>
* <em>Note:</em> Adding a split to a chain of states is not supported. For example,
* the following configuration is not supported. Instead, the configuration would need
* to create a flow3 that was the split flow and assemble them separately.

View File

@@ -88,10 +88,6 @@ public class FlowJob extends AbstractJob {
initialized = true;
}
/**
* @param flow
* @param map
*/
private void findSteps(Flow flow, Map<String, Step> map) {
for (State state : flow.getStates()) {

View File

@@ -385,7 +385,7 @@ public class CommandLineJobRunner {
/**
* @param jobIdentifier a job execution id or job name
* @param minStatus the highest status to exclude from the result
* @return
* @return the list of job executions with status greater than minStatus
*/
private List<JobExecution> getJobExecutionsWithStatusGreaterThan(String jobIdentifier, BatchStatus minStatus) {

View File

@@ -172,7 +172,7 @@ public class JobRegistryBackgroundJobRunner {
* and followed by the children. The parent must contain a {@link JobRegistry} and the
* child contexts are expected to contain {@link Job} definitions, each of which will
* be registered wit the registry.
*
* <p>
* Example usage:
*
* <pre>
@@ -182,7 +182,7 @@ public class JobRegistryBackgroundJobRunner {
* The child contexts are created only when needed though the {@link JobFactory}
* interface (but the XML is validated on startup by using it to create a
* {@link BeanFactory} which is then discarded).
*
* <p>
* The parent context is created in a separate thread, and the program will pause for
* input in an infinite loop until the user hits any key.
* @param args the context locations to use (first one is for parent)

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2022 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -51,7 +51,7 @@ import org.springframework.util.Assert;
* Care should be taken to ensure any users of this class understand fully whether or not
* the implementation of TaskExecutor used will start tasks synchronously or
* asynchronously. The default setting uses a synchronous task executor.
*
* <p>
* There is only one required dependency of this Launcher, a {@link JobRepository}. The
* JobRepository is used to obtain a valid JobExecution. The Repository must be used
* because the provided {@link Job} could be a restart of an existing {@link JobInstance},

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2022 the original author or authors.
* Copyright 2022-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -36,7 +36,7 @@ import org.springframework.core.task.TaskExecutor;
* of this class understand fully whether or not the implementation of TaskExecutor used
* will start tasks synchronously or asynchronously. The default setting uses a
* synchronous task executor.
*
* <p>
* There is only one required dependency of this Launcher, a {@link JobRepository}. The
* JobRepository is used to obtain a valid JobExecution. The Repository must be used
* because the provided {@link Job} could be a restart of an existing {@link JobInstance},

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2022 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -32,7 +32,7 @@ import org.springframework.util.ObjectUtils;
* {@link ExecutionContext} to the {@link Job} {@link ExecutionContext} at the end of a
* step. A list of keys should be provided that correspond to the items in the
* {@link Step} {@link ExecutionContext} that should be promoted.
*
* <p>
* Additionally, an optional list of statuses can be set to indicate for which exit status
* codes the promotion should occur. These statuses will be checked using the
* {@link PatternMatcher}, so wildcards are allowed. By default, promotion will only occur

View File

@@ -43,7 +43,7 @@ class OrderedComposite<S> {
/**
* Public setter for the listeners.
* @param items
* @param items to set
*/
public void setItems(List<? extends S> items) {
unordered.clear();
@@ -55,7 +55,7 @@ class OrderedComposite<S> {
/**
* Register additional item.
* @param item
* @param item to add
*/
public void add(S item) {
if (item instanceof Ordered) {

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2022 the original author or authors.
* Copyright 2002-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -46,6 +46,7 @@ import org.springframework.batch.core.annotation.OnSkipInWrite;
import org.springframework.batch.core.annotation.OnWriteError;
import org.springframework.batch.core.scope.context.ChunkContext;
import org.springframework.batch.item.Chunk;
import org.springframework.lang.Nullable;
/**
* Enumeration for {@link StepListener} meta data, which ties together the names of
@@ -140,6 +141,7 @@ public enum StepListenerMetaData implements ListenerMetaData {
* @param propertyName property name to retrieve data for.
* @return meta data with supplied property name, null if none exists.
*/
@Nullable
public static StepListenerMetaData fromPropertyName(String propertyName) {
return propertyMap.get(propertyName);
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2019-2022 the original author or authors.
* Copyright 2019-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -93,7 +93,7 @@ public final class BatchMetrics {
/**
* Create a new {@link Observation}. It's not started, you must explicitly call
* {@link Observation#start()} to start it.
*
* <p>
* Remember to register the {@link DefaultMeterObservationHandler} via the
* {@code Metrics.globalRegistry.withTimerObservationHandler()} in the user code.
* Otherwise you won't observe any metrics.
@@ -110,7 +110,7 @@ public final class BatchMetrics {
/**
* Create a new {@link Observation}. It's not started, you must explicitly call
* {@link Observation#start()} to start it.
*
* <p>
* Remember to register the {@link DefaultMeterObservationHandler} via the
* {@code Metrics.globalRegistry.withTimerObservationHandler()} in the user code.
* Otherwise you won't observe any metrics.

View File

@@ -137,7 +137,7 @@ public interface JobRepository {
/**
* Update the {@link JobExecution} (but not its {@link ExecutionContext}).
*
* <p>
* Preconditions: {@link JobExecution} must contain a valid {@link JobInstance} and be
* saved (have an id assigned).
* @param jobExecution {@link JobExecution} instance to be updated in the repo.
@@ -148,7 +148,7 @@ public interface JobRepository {
* Save the {@link StepExecution} and its {@link ExecutionContext}. ID will be
* assigned - it is not permitted that an ID be assigned before calling this method.
* Instead, it should be left blank, to be assigned by a {@link JobRepository}.
*
* <p>
* Preconditions: {@link StepExecution} must have a valid {@link Step}.
* @param stepExecution {@link StepExecution} instance to be added to the repo.
*/
@@ -159,7 +159,7 @@ public interface JobRepository {
* StepExecution ID will be assigned - it is not permitted that an ID be assigned
* before calling this method. Instead, it should be left blank, to be assigned by
* {@link JobRepository}.
*
* <p>
* Preconditions: {@link StepExecution} must have a valid {@link Step}.
* @param stepExecutions collection of {@link StepExecution} instances to be added to
* the repo.
@@ -168,7 +168,7 @@ public interface JobRepository {
/**
* Update the {@link StepExecution} (but not its {@link ExecutionContext}).
*
* <p>
* Preconditions: {@link StepExecution} must be saved (have an id assigned).
* @param stepExecution {@link StepExecution} instance to be updated in the repo.
*/

View File

@@ -45,7 +45,7 @@ import org.springframework.util.Assert;
/**
* JDBC DAO for {@link ExecutionContext}.
*
* <p>
* Stores execution context data related to both Step and Job using a different table for
* each.
*
@@ -269,8 +269,8 @@ public class JdbcExecutionContextDao extends AbstractJdbcBatchMetadataDao implem
}
/**
* @param executionId
* @param serializedContext
* @param executionId the job or step execution id
* @param serializedContext the serialized context to persist
* @param sql with parameters (shortContext, longContext, executionId)
*/
private void persistSerializedContext(final Long executionId, String serializedContext, String sql) {
@@ -301,7 +301,7 @@ public class JdbcExecutionContextDao extends AbstractJdbcBatchMetadataDao implem
}
/**
* @param serializedContexts
* @param serializedContexts the execution contexts to serialize
* @param sql with parameters (shortContext, longContext, executionId)
*/
private void persistSerializedContexts(final Map<Long, String> serializedContexts, String sql) {

View File

@@ -249,8 +249,8 @@ public class JdbcJobExecutionDao extends AbstractJdbcBatchMetadataDao implements
/**
* Validate JobExecution. At a minimum, JobId, Status, CreateTime cannot be null.
* @param jobExecution
* @throws IllegalArgumentException
* @param jobExecution the job execution to validate
* @throws IllegalArgumentException if the job execution is invalid
*/
private void validateJobExecution(JobExecution jobExecution) {

View File

@@ -233,7 +233,7 @@ public class JdbcStepExecutionDao extends AbstractJdbcBatchMetadataDao implement
/**
* Validate StepExecution. At a minimum, JobId, CreateTime, and Status cannot be null.
* EndTime can be null for an unfinished job.
* @throws IllegalArgumentException
* @throws IllegalArgumentException if the step execution is invalid
*/
private void validateStepExecution(StepExecution stepExecution) {
Assert.notNull(stepExecution, "stepExecution is required");

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2022 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -34,7 +34,7 @@ public interface JobExecutionDao {
/**
* Save a new JobExecution.
*
* <p>
* Preconditions: jobInstance the jobExecution belongs to must have a jobInstanceId.
* @param jobExecution {@link JobExecution} instance to be saved.
*/
@@ -42,7 +42,7 @@ public interface JobExecutionDao {
/**
* Update and existing JobExecution.
*
* <p>
* Preconditions: jobExecution must have an Id (which can be obtained by the save
* method) and a jobInstanceId.
* @param jobExecution {@link JobExecution} instance to be updated.

View File

@@ -37,9 +37,9 @@ public interface JobInstanceDao {
/**
* Create a JobInstance with given name and parameters.
*
* <p>
* PreConditions: JobInstance for given name and parameters must not already exist
*
* <p>
* PostConditions: A valid job instance will be returned which has been persisted and
* contains an unique Id.
* @param jobName {@link String} containing the name of the job.
@@ -80,7 +80,7 @@ public interface JobInstanceDao {
/**
* Fetch the last job instances with the provided name, sorted backwards by primary
* key.
*
* <p>
* if using the JdbcJobInstance, you can provide the jobName with a wildcard (e.g.
* *Job) to return 'like' job names. (e.g. *Job will return 'someJob' and 'otherJob')
* @param jobName the job name

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2022 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -27,9 +27,9 @@ public interface StepExecutionDao {
/**
* Save the given StepExecution.
*
* <p>
* Preconditions: Id must be null.
*
* <p>
* Postconditions: Id will be set to a unique Long.
* @param stepExecution {@link StepExecution} instance to be saved.
*/
@@ -37,9 +37,9 @@ public interface StepExecutionDao {
/**
* Save the given collection of StepExecution as a batch.
*
* <p>
* Preconditions: StepExecution Id must be null.
*
* <p>
* Postconditions: StepExecution Id will be set to a unique Long.
* @param stepExecutions a collection of {@link JobExecution} instances to be saved.
*/
@@ -47,7 +47,7 @@ public interface StepExecutionDao {
/**
* Update the given StepExecution
*
* <p>
* Preconditions: Id must not be null.
* @param stepExecution {@link StepExecution} instance to be updated.
*/

View File

@@ -283,7 +283,7 @@ public class SimpleJobRepository implements JobRepository {
* provided StepExecution has been interrupted. If, after synchronizing the status
* with the database, the status has been updated to STOPPING, then the job has been
* interrupted.
* @param stepExecution
* @param stepExecution the step execution
*/
private void checkForInterruption(StepExecution stepExecution) {
JobExecution jobExecution = stepExecution.getJobExecution();

View File

@@ -689,7 +689,7 @@ public class FaultTolerantStepBuilder<I, O> extends SimpleStepBuilder<I, O> {
/**
* ChunkListener that wraps exceptions thrown from the ChunkListener in
* {@link FatalStepExecutionException} to force termination of StepExecution
*
* <p>
* ChunkListeners shoulnd't throw exceptions and expect continued processing, they
* must be handled in the implementation or the step will terminate
*

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2022 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -38,7 +38,7 @@ import org.springframework.retry.policy.RetryContextCache;
* Factory bean for step that provides options for configuring skip behavior. User can set
* {@link #setSkipLimit(int)} to set how many exceptions of
* {@link #setSkippableExceptionClasses(Map)} types are tolerated.
*
* <p>
* Skippable exceptions on write will by default cause transaction rollback - to avoid
* rollback for specific exception class include it in the transaction attribute as "no
* rollback for".

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2022 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -51,7 +51,7 @@ import org.springframework.transaction.interceptor.TransactionAttribute;
/**
* Most common configuration options for simple steps should be found here. Use this
* factory bean instead of creating a {@link Step} implementation manually.
*
* <p>
* This factory does not support configuration of fault-tolerant behavior, use appropriate
* subclass of this factory bean to configure skip or retry.
*

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2006-2013 the original author or authors.
* Copyright 2006-2023 the original author or authors.
*
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
@@ -21,7 +21,7 @@ import org.springframework.batch.core.ExitStatus;
/**
* Simple {@link SystemProcessExitCodeMapper} implementation that performs following
* mapping:
*
* <p>
* 0 -&gt; ExitStatus.FINISHED else -&gt; ExitStatus.FAILED
*
* @author Robert Kasanicky

View File

@@ -41,18 +41,18 @@ import org.springframework.util.StringUtils;
/**
* {@link Tasklet} that executes a system command.
*
* <p>
* The system command is executed asynchronously using injected
* {@link #setTaskExecutor(TaskExecutor)} - timeout value is required to be set, so that
* the batch job does not hang forever if the external process hangs.
*
* <p>
* Tasklet periodically checks for termination status (i.e. {@link #setCommand(String...)}
* finished its execution or {@link #setTimeout(long)} expired or job was interrupted).
* The check interval is given by {@link #setTerminationCheckInterval(long)}.
*
* <p>
* When job interrupt is detected tasklet's execution is terminated immediately by
* throwing {@link JobInterruptedException}.
*
* <p>
* {@link #setInterruptOnCancel(boolean)} specifies whether the tasklet should attempt to
* interrupt the thread that executes the system command if it is still running when
* tasklet exits (abnormally).