This is an automated email from the ASF dual-hosted git repository.
wanghailin pushed a commit to branch dev
in repository https://gitbox.apache.org/repos/asf/seatunnel.git
The following commit(s) were added to refs/heads/dev by this push:
new eb6d4cf8c8 [Improve] Mark `SeaTunnelPluginLifeCycle` as deprecated
(#5625)
eb6d4cf8c8 is described below
commit eb6d4cf8c89c267276ca29eeb2ee0c155583deb1
Author: Jia Fan <[email protected]>
AuthorDate: Mon Oct 16 20:10:48 2023 +0800
[Improve] Mark `SeaTunnelPluginLifeCycle` as deprecated (#5625)
---
.../apache/seatunnel/api/common/SeaTunnelPluginLifeCycle.java | 7 +++++++
.../main/java/org/apache/seatunnel/api/sink/SeaTunnelSink.java | 2 ++
.../org/apache/seatunnel/api/transform/SeaTunnelTransform.java | 10 +++++-----
3 files changed, 14 insertions(+), 5 deletions(-)
diff --git
a/seatunnel-api/src/main/java/org/apache/seatunnel/api/common/SeaTunnelPluginLifeCycle.java
b/seatunnel-api/src/main/java/org/apache/seatunnel/api/common/SeaTunnelPluginLifeCycle.java
index 731307f202..a36ecfb624 100644
---
a/seatunnel-api/src/main/java/org/apache/seatunnel/api/common/SeaTunnelPluginLifeCycle.java
+++
b/seatunnel-api/src/main/java/org/apache/seatunnel/api/common/SeaTunnelPluginLifeCycle.java
@@ -22,7 +22,11 @@ import org.apache.seatunnel.shade.com.typesafe.config.Config;
/**
* This interface is the life cycle of a plugin, after a plugin created, will
execute prepare method
* to do some initialize operation.
+ *
+ * @deprecated SeaTunnel will not invoke prepare when init plugin, instead by
{@link
+ * org.apache.seatunnel.api.table.factory.Factory}
*/
+@Deprecated
public interface SeaTunnelPluginLifeCycle {
/**
@@ -31,6 +35,9 @@ public interface SeaTunnelPluginLifeCycle {
* @param pluginConfig plugin config.
* @throws PrepareFailException if plugin prepare failed, the {@link
PrepareFailException} will
* throw.
+ * @deprecated SeaTunnel will not invoke prepare when init plugin, instead
by {@link
+ * org.apache.seatunnel.api.table.factory.Factory}
*/
+ @Deprecated
void prepare(Config pluginConfig) throws PrepareFailException;
}
diff --git
a/seatunnel-api/src/main/java/org/apache/seatunnel/api/sink/SeaTunnelSink.java
b/seatunnel-api/src/main/java/org/apache/seatunnel/api/sink/SeaTunnelSink.java
index 0ed1b1bf7f..352c2e9d48 100644
---
a/seatunnel-api/src/main/java/org/apache/seatunnel/api/sink/SeaTunnelSink.java
+++
b/seatunnel-api/src/main/java/org/apache/seatunnel/api/sink/SeaTunnelSink.java
@@ -53,8 +53,10 @@ public interface SeaTunnelSink<IN, StateT, CommitInfoT,
AggregatedCommitInfoT>
* Set the row type info of sink row data. This method will be
automatically called by
* translation.
*
+ * @deprecated instead by {@link
org.apache.seatunnel.api.table.factory.Factory}
* @param seaTunnelRowType The row type info of sink.
*/
+ @Deprecated
void setTypeInfo(SeaTunnelRowType seaTunnelRowType);
/**
diff --git
a/seatunnel-api/src/main/java/org/apache/seatunnel/api/transform/SeaTunnelTransform.java
b/seatunnel-api/src/main/java/org/apache/seatunnel/api/transform/SeaTunnelTransform.java
index 54b0e390a7..741670e9e6 100644
---
a/seatunnel-api/src/main/java/org/apache/seatunnel/api/transform/SeaTunnelTransform.java
+++
b/seatunnel-api/src/main/java/org/apache/seatunnel/api/transform/SeaTunnelTransform.java
@@ -37,22 +37,22 @@ public interface SeaTunnelTransform<T>
/**
* Set the data type info of input data.
*
+ * @deprecated instead by {@link
org.apache.seatunnel.api.table.factory.Factory}
* @param inputDataType The data type info of upstream input.
*/
+ @Deprecated
void setTypeInfo(SeaTunnelDataType<T> inputDataType);
/**
* Get the data type of the records produced by this transform.
*
+ * @deprecated Please use {@link #getProducedCatalogTable}
* @return Produced data type.
*/
+ @Deprecated
SeaTunnelDataType<T> getProducedType();
- /**
- * Get the catalog table output by this transform
- *
- * @return
- */
+ /** Get the catalog table output by this transform */
CatalogTable getProducedCatalogTable();
/**