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

   ### 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
   
   There is an issue with the encoding format when reading data from 
Elasticsearch . The root cause is that when reading data from Elasticsearch, 
the response header Content-Type does not include a charset encoding. SeaTunnel 
defaults to ISO-8859-1 encoding in the absence of a charset specification. 
However, StarRocks only supports UTF-8 encoding, leading to the observed 
garbled text. Need to adjust the encoding handling to ensure compatibility and 
data integrity. Open to discussion on potential solutions and improvements. I 
am considering submitting a pull request to address this issue.
   
   ### SeaTunnel Version
   
   2.3.3
   
   ### SeaTunnel Config
   
   ```conf
   env {
     parallelism = 2
     job.mode = "BATCH"
     checkpoint.interval = 10000
   }
   
   source {
       Elasticsearch {
           hosts = ["http://127.0.0.1:10014";]
           index = "sec_evt_info"
           username = "elastic"
           password = ""
           result_table_name = "src_es"
           schema = {
            fields {
               test_data = string
               }
           }
           query = {"range":{"recordTime":{"gte":"2024-07-01 00:00:00"}}}
   
           tls_verify_certificate = false
       }
   }
   
   
   
   
   sink {
     StarRocks {
       source_table_name = "src_es"
       nodeUrls = ["127.0.0.1:9030"]
       base-url = "jdbc:mysql://127.0.0.1:8030/"
       username = root
       password = "password"
       database = "db"
       table = "table_name"
       batch_max_rows = 1000
       starrocks.config = {
         format = "CSV"
       }
     }
   }
   ```
   
   
   ### Running Command
   
   ```shell
   ./bin/seatunnel.sh --config job/es2starrocks.config
   ```
   
   
   ### Error Exception
   
   ```log
   None
   ```
   
   
   ### Zeta or Flink or Spark Version
   
   _No response_
   
   ### Java or Scala Version
   
   _No response_
   
   ### Screenshots
   
   _No response_
   
   ### Are you willing to submit PR?
   
   - [X] 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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to