-
Notifications
You must be signed in to change notification settings - Fork 122
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Provide a way to configure each plugin. (#993)
Motivation: Configuring user-defined plugins is currently difficult because there is no way to configure their properties via `dogma.json`. Modifications: - Added `PluginConfig` interface that represents a configuration of a plugin. - Added `pluginConfigs` to `CentralDogmaConfig` that accepts a list of `PluginConfig`. - Users can now configure each plugin using `PluginConfig`. - Moved mirroring plugin properties from `CentralDogmaConfig` to `MirroringServicePluginConfig`. - Compatibility was not maintained as few users are running the Central Dogma server, and they can be guided directly. Let me know if a different approach is preferred. Result: - Users can now specify plugin configurations in the `plugins` property. ```json { "dataDir": "./data", ... "pluginConfigs": [ { "type": "com.example.MyPlugin", "enabled": true, // enabled by default "myPluginTimeout": 10 }, // Other plugins ] } ``` - (Breaking changes) `mirroringEnabled`, `numMirroringThreads`, `maxNumFilesPerMirror`, and `maxNumBytesPerMirror` have been removed from `CentralDogmaBuilder` and `CentralDogmaConfig`. - These properties should now be specified in the plugins property: ```json { "dataDir": "./data", ... "pluginConfigs": [ { "type": "com.linecorp.centraldogma.server.mirror.MirroringServicePluginConfig", "enabled": true, "numMirroringThreads": 16, "maxNumFilesPerMirror": 8192 } ] } ```
- Loading branch information
Showing
29 changed files
with
687 additions
and
185 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.