inlong icon indicating copy to clipboard operation
inlong copied to clipboard

[INLONG-9867][Manager] Unified configuration process for standalone and sortflink

Open fuweng11 opened this issue 1 year ago • 0 comments

Prepare a Pull Request

  • Fixes #9867 9867

Motivation

Unified configuration process for standalone and sortflink. The current configuration process of standalone has the following issues:

  1. Configuration changes will be updated in real-time to the manager's cache. Once a configuration change occurs, sortstandalone will sense it and write data based on the new configuration. Once the configuration is modified incorrectly, it can lead to issues with the entire write.

  2. The configuration in the manager cache is to fully pull the content from the database and filter it. Each refresh requires a full database query and repeated filtering operations at the service layer.

  3. There is no management function for whether each configuration is functioning properly. Once the configuration is registered on the manager side, it defaults to the correct configuration. Failure to verify and issue each configuration results in unreliable configurations.

Modifications

The flowchart of standalone pull configuration is as follows: image

The getClusterConfigV2 interface has been set up, where the data comes from the sort_config table, which can only be obtained through workflow configuration operations. The interface protocol is consistent with the getClusterConfig interface.

  1. Incorporate the configuration process of sort standalone into the manager's configuration management system and add a configuration information table. The JSON format configuration information that sort standalone needs to pull will be saved in a field of this table. Only those that are successfully configured will be recorded in this table.

  2. Modify the configuration timer to be pulled to the cache and change it to actively trigger the configuration update cache. After successful configuration, the configuration information will be registered in this configuration information table, loaded into the cache, and the md5 value will be modified.

fuweng11 avatar Mar 23 '24 11:03 fuweng11