You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@seatunnel.apache.org by "lalapalooza (via GitHub)" <gi...@apache.org> on 2026/01/30 06:14:28 UTC

[I] [Bug] [transforms-v2] The type retrieved via ReadonlyConfig does not match the actual type. [seatunnel]

lalapalooza opened a new issue, #10421:
URL: https://github.com/apache/seatunnel/issues/10421

   ### Search before asking
   
   - [x] I had searched in the [issues](https://github.com/apache/seatunnel/issues?q=is%3Aissue+label%3A%22bug%22) and found no similar issues.
   
   
   ### What happened
   
   In the Transform module, for Map<String,Integer> types defined in the ReadonlyConfig configuration file, the final retrieved configuration type is Map<String,String>, resulting in column attribute mismatch and eventual data insertion failure.
   
   ### SeaTunnel Version
   
   2.3.12
   
   ### SeaTunnel Config
   
   ```conf
   transform {
     DeleteRowKindExtractor {
       custom_field_name = "isdeleted"
       custom_field_value = {"DELETE":11,"INSERT":10,"UPDATE_AFTER":20,"UPDATE_BEFORE":30}
       plugin_output = "trans_result"
     }
   }
   ```
   
   ### Running Command
   
   ```shell
   running in SeaTunnelEngineLocalExample
   ```
   
   ### Error Exception
   
   ```log
   Caused by: org.apache.seatunnel.connectors.seatunnel.jdbc.exception.JdbcConnectorException: ErrorCode:[JDBC-10], ErrorDescription:[Data type cast failed] - error field:isdeleted
   	at org.apache.seatunnel.connectors.seatunnel.jdbc.internal.converter.AbstractJdbcRowConverter.toExternal(AbstractJdbcRowConverter.java:225)
   	at org.apache.seatunnel.connectors.seatunnel.jdbc.internal.executor.SimpleBatchStatementExecutor.addToBatch(SimpleBatchStatementExecutor.java:48)
   	at org.apache.seatunnel.connectors.seatunnel.jdbc.internal.executor.SimpleBatchStatementExecutor.addToBatch(SimpleBatchStatementExecutor.java:33)
   	at org.apache.seatunnel.connectors.seatunnel.jdbc.internal.executor.BufferReducedBatchStatementExecutor.executeBatch(BufferReducedBatchStatementExecutor.java:77)
   	at org.apache.seatunnel.connectors.seatunnel.jdbc.internal.JdbcOutputFormat.attemptFlush(JdbcOutputFormat.java:172)
   	at org.apache.seatunnel.connectors.seatunnel.jdbc.internal.JdbcOutputFormat.flush(JdbcOutputFormat.java:136)
   	at org.apache.seatunnel.connectors.seatunnel.jdbc.sink.JdbcSinkWriter.prepareCommit(JdbcSinkWriter.java:147)
   	at org.apache.seatunnel.api.sink.SinkWriter.prepareCommit(SinkWriter.java:75)
   	at org.apache.seatunnel.api.sink.multitablesink.MultiTableSinkWriter.lambda$prepareCommit$4(MultiTableSinkWriter.java:259)
   	... 6 more
   Caused by: java.lang.ClassCastException: java.lang.String cannot be cast to java.lang.Integer
   	at org.apache.seatunnel.connectors.seatunnel.jdbc.internal.converter.AbstractJdbcRowConverter.setValueToStatementByDataType(AbstractJdbcRowConverter.java:253)
   	at org.apache.seatunnel.connectors.seatunnel.jdbc.internal.converter.AbstractJdbcRowConverter.toExternal(AbstractJdbcRowConverter.java:216)
   	... 14 more
   
   	at org.apache.seatunnel.core.starter.seatunnel.command.ClientExecuteCommand.execute(ClientExecuteCommand.java:220)
   	... 2 more
   ```
   
   ### Zeta or Flink or Spark Version
   
   _No response_
   
   ### Java or Scala Version
   
   java 1.8 
   
   ### Screenshots
   
   <img width="1859" height="661" alt="Image" src="https://github.com/user-attachments/assets/64c38772-cb8c-4057-b9a4-189abfbd0670" />
   
   ### Are you willing to submit PR?
   
   - [ ] Yes I am willing to submit a PR!
   
   ### Code of Conduct
   
   - [x] I agree to follow this project's [Code of Conduct](https://www.apache.org/foundation/policies/conduct)
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [transforms-v2] The type retrieved via ReadonlyConfig does not match the actual type. [seatunnel]

Posted by "LiJie20190102 (via GitHub)" <gi...@apache.org>.
LiJie20190102 commented on issue #10421:
URL: https://github.com/apache/seatunnel/issues/10421#issuecomment-3833784104

   Hi @lalapalooza ,sorry for the slow reply. Could you please share the customized DeleteRowKindExtractor code
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [transforms-v2] The type retrieved via ReadonlyConfig does not match the actual type. [seatunnel]

Posted by "lalapalooza (via GitHub)" <gi...@apache.org>.
lalapalooza commented on issue #10421:
URL: https://github.com/apache/seatunnel/issues/10421#issuecomment-3975966620

   This is a conversion plugin that I have defined myself. It is based on the existing "rowkind transform" in seatunnel and is used to perform logical deletion of the deleted data from the source end at the sink end.
   
   <img width="997" height="366" alt="Image" src="https://github.com/user-attachments/assets/87658f93-8e42-4877-ba10-fe8a9672309e" />
   
   <img width="1059" height="691" alt="Image" src="https://github.com/user-attachments/assets/61d0259a-2268-4f02-8b74-90b6e35ff7c9" />
   
   <img width="1072" height="918" alt="Image" src="https://github.com/user-attachments/assets/08842e74-6ba3-43bc-844e-1ef16b0b8716" />


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org


Re: [I] [Bug] [transforms-v2] The type retrieved via ReadonlyConfig does not match the actual type. [seatunnel]

Posted by "DanielCarter-stack (via GitHub)" <gi...@apache.org>.
DanielCarter-stack commented on issue #10421:
URL: https://github.com/apache/seatunnel/issues/10421#issuecomment-3831147489

   <!-- code-pr-reviewer -->
   Thank you for the report. Based on the current dev branch codebase, I cannot locate a transform named `DeleteRowKindExtractor`. 
   
   The existing `RowKindExtractorTransform` (seatunnel-transforms-v2/src/main/java/org/apache/seatunnel/transform/rowkind/) only outputs STRING type and does not have a `custom_field_value` configuration option.
   
   Additionally, the SeaTunnel Options API (seatunnel-api/src/main/java/org/apache/seatunnel/api/configuration/Options.java) supports `Map<String, String>` and `Map<String, Object>`, but not `Map<String, Integer>`.
   
   Could you please clarify:
   1. Is `DeleteRowKindExtractor` a custom transform?
   2. Which SeaTunnel version are you using?
   3. Could you share the complete transform configuration?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: commits-unsubscribe@seatunnel.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org