Deprecate public APIs related to LobHandler

Resolves #4588
This commit is contained in:
Mahmoud Ben Hassine
2024-10-10 23:24:11 +02:00
parent 461ae65f9e
commit a293f3e29c
6 changed files with 16 additions and 4 deletions

View File

@@ -241,7 +241,9 @@ public @interface EnableBatchProcessing {
/**
* The large object handler to use in job repository and job explorer.
* @return the bean name of the lob handler to use. Defaults to {@literal lobHandler}.
* @deprecated Since 5.2 with no replacement. Scheduled for removal in v6
*/
@Deprecated(since = "5.2.0", forRemoval = true)
String lobHandlerRef() default "lobHandler";
/**

View File

@@ -392,8 +392,9 @@ public class DefaultBatchConfiguration implements ApplicationContextAware {
* A special handler for large objects. The default is usually fine, except for some
* (usually older) versions of Oracle.
* @return the {@link LobHandler} to use
*
* @deprecated Since 5.2 with no replacement. Scheduled for removal in v6
*/
@Deprecated(since = "5.2.0", forRemoval = true)
protected LobHandler getLobHandler() {
return new DefaultLobHandler();
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2023 the original author or authors.
* Copyright 2002-2024 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.
@@ -143,7 +143,9 @@ public class JobExplorerFactoryBean extends AbstractJobExplorerFactoryBean imple
* {@code null}, which works for most databases.
* @param lobHandler Large object handler for saving an
* {@link org.springframework.batch.item.ExecutionContext}.
* @deprecated Since 5.2 with no replacement. Scheduled for removal in v6
*/
@Deprecated(since = "5.2.0", forRemoval = true)
public void setLobHandler(LobHandler lobHandler) {
this.lobHandler = lobHandler;
}

View File

@@ -268,6 +268,11 @@ public class JdbcExecutionContextDao extends AbstractJdbcBatchMetadataDao implem
getJdbcTemplate().update(getQuery(DELETE_STEP_EXECUTION_CONTEXT), stepExecution.getId());
}
/**
* @deprecated Since 5.2 with no replacement. Scheduled for removal in v6
* @param lobHandler the lob handler to use
*/
@Deprecated(since = "5.2.0", forRemoval = true)
public void setLobHandler(LobHandler lobHandler) {
this.lobHandler = lobHandler;
}

View File

@@ -1,5 +1,5 @@
/*
* Copyright 2002-2023 the original author or authors.
* Copyright 2002-2024 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.
@@ -129,9 +129,10 @@ public class JobRepositoryFactoryBean extends AbstractJobRepositoryFactoryBean i
* (usually older) versions of Oracle. The default is determined from the data base
* type.
* @param lobHandler the {@link LobHandler} to set
*
* @deprecated Since 5.2 with no replacement. Scheduled for removal in v6
* @see LobHandler
*/
@Deprecated(since = "5.2.0", forRemoval = true)
public void setLobHandler(LobHandler lobHandler) {
this.lobHandler = lobHandler;
}

View File

@@ -270,6 +270,7 @@
<xsd:documentation><![CDATA[
A reference to the lob handler (optional). Only override if using Oracle and
the database type is not being detected for some reason.
This attribute is deprecated Since 5.2 with no replacement. Scheduled for removal in v6.
]]></xsd:documentation>
<xsd:appinfo>
<tool:annotation kind="ref">