TeslaCN commented on issue #1744: URL: https://github.com/apache/shardingsphere-elasticjob/issues/1744#issuecomment-741785693
I have worked on this issue for sereral days and I found some problems. For example, `TracingConfiguration` is an implementation of `JobExtraConfiguration`, its constructor requires an instance of `DataSource`. If we want to persist `JobExtraConfiguration` to registry center, we have to marshal / unmarshal the instance of `DataSource`. I have implemented a `Represent` and `Construct` to marshal / unmarshal instance of `HikariDataSource`. I found that `HikariDataSource` starts connection pool in constructor, which means every time I unmarshal the instance of `HikariDataSource`, a new connection pool will be started. So we CANNOT unmarshal instance of `DataSource` directly. I have some idea about changing the API of `TracingConfiguration`. Maybe it's better to put a configuration of `DataSource` into `TracingConfiguration` rather than offering an instance of `DataSource` into `TracingConfiguration`. ---------------------------------------------------------------- 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]
