JNSimba opened a new pull request, #62700:
URL: https://github.com/apache/doris/pull/62700

   ### What problem does this PR solve?
   
   Issue Number: close #xxx
   
   Related PR: #60988
   
   Problem Summary:
   
   The MySQL CDC streaming source currently lacks several configuration knobs 
that the PostgreSQL path already supports (PG SSL shipped in #60988 and 
follow-ups for `target_table` / `exclude_columns`). This PR brings MySQL up to 
parity.
   
   1. **SSL encryption with CA verification** — `ssl_mode` and `ssl_rootcert` 
properties are now wired from job config into Debezium's 
`database.ssl.{mode,truststore,truststore.password}`. Because MySQL JDBC does 
not accept raw PEM, `SmallFileMgr` gains a `getPkcs12TruststorePath()` helper 
that converts the uploaded PEM CA cert into a PKCS12 truststore on first use, 
reusing the same content-addressed md5 cache as the PG path. The truststore 
password is a fixed `changeit` placeholder (public-CA-only truststore; the 
password is not a security boundary, just a JCA API requirement).
   2. **MySQL docker test environment** — `mysql-5.7.yaml.tpl` now mounts the 
same root CA / server cert / key as PG and starts `mysqld` with 
`--ssl-ca/cert/key`. `require_secure_transport` is intentionally NOT set so 
existing `useSSL=false` tests keep working.
   3. **Regression tests** — mirror PG's suites for MySQL: 
`test_streaming_mysql_job_ssl`, `test_streaming_mysql_job_table_mapping`, 
`test_streaming_mysql_job_col_filter`.
   4. **Unit tests** — \`SmallFileMgrTest\` covers the new PEM → PKCS12 
conversion: single cert, chain alias safety (so \`ca0/ca1\` don't overwrite 
each other), memory cache hit, invalid PEM rejection.
   
   ### Release note
   
   Support SSL (\`ssl_mode\`, \`ssl_rootcert\`) for MySQL CDC streaming insert 
jobs.
   
   ### Check List (For Author)
   
   - Test
       - [x] Regression test
       - [x] Unit Test
       - [ ] Manual test (add detailed scripts or steps below)
       - [ ] No need to test or manual test. Explain why:
           - [ ] This is a refactor/code format and no logic has been changed.
           - [ ] Previous test can cover this change.
           - [ ] No code files have been changed.
           - [ ] Other reason
   
   - Behavior changed:
       - [ ] No.
       - [x] Yes. MySQL CDC streaming jobs now accept \`ssl_mode\` and 
\`ssl_rootcert\` properties. Existing jobs without these properties are 
unaffected.
   
   - Does this need documentation?
       - [ ] No.
       - [x] Yes.
   
   ### Check List (For Reviewer who merge this PR)
   
   - [ ] Confirm the release note
   - [ ] Confirm test cases
   - [ ] Confirm document
   - [ ] Add branch pick label


-- 
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]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to