becketqin opened a new pull request #14143:
URL: https://github.com/apache/flink/pull/14143


   …nator executor thread should use the user class loader.
   
   ## What is the purpose of the change
   This patch fixes two class loader related problems:
   
   1. Currently the `RecreateOnResetOperatorCoordinator` does not use the user 
class loader when creating the internal coordinator or calling start. 
`ClassNotFoundException` could be thrown due to this. The patch fixes this 
issue by creating and starting the internal operator coordinator using the user 
class loader.
   2. The SourceCoordinator executor thread does not run with user class loader 
at this point. Because that thread is going to interact with the custom 
implementation of `SplitEnumerator`, it should run with user class loader as 
well.
   
   
   ## Brief change log
   - Fix `RecreateOnResetOperatorCoordinator` to create and start internal 
coordinators in user class loader.
   - Fix the SourceCoordinator executor thread to run with user class loader.
   
   ## Verifying this change
   Unit tests have been added / modified to test the change.
   - `RecreateOnResetOperatorCoordinatorTest`.
   - `SourceCoordinatorProviderTest.testUserClassLoaderInCoordinatorExecutor()`
   
   ## Does this pull request potentially affect one of the following parts:
   
     - Dependencies (does it add or upgrade a dependency): (no)
     - The public API, i.e., is any changed class annotated with 
`@Public(Evolving)`: (no)
     - The serializers: (no)
     - The runtime per-record code paths (performance sensitive): (no)
     - Anything that affects deployment or recovery: JobManager (and its 
components), Checkpointing, Kubernetes/Yarn/Mesos, ZooKeeper: (no)
     - The S3 file system connector: (no)
   
   ## Documentation
   
     - Does this pull request introduce a new feature? (no)
     - If yes, how is the feature documented? (not applicable)
   


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

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


Reply via email to