You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
In our work with pluggable DID resolvers, I found that we needed the ability to configure the plugin at startup to set values relevant to the resolver plugin. However, as a plugin, we can't add command line arguments to the ACA-Py instance so we resorted to loading a separate yaml file specified by an environment variable. This worked fine but it got me thinking about easier to use solutions, especially when considering loading multiple resolvers (i.e. uniresolver + didcomm resolver + ...) and anticipating writing more plugins in the near future that will likewise require their own configuration.
So, to field an idea I had, what do we think of a --plugin-config plugin.yml command line argument that just loads the yaml into a map in settings and performs no further validation? Plugins would then subsequently look underneath their own namespace and perform validation if necessary for the options they define. In essence, I view this as analogous to setup.cfg/setup.ini/pyproject.toml tool configurations, allowing various plugins to retrieve configuration from a single source rather than having one configuration file and environment variable each. This also avoids having to do multiple passes of command line argument parsing to allow plugins to define their own. This multi-pass parsing is, of course, doable but doesn't feel as clean to me.
The text was updated successfully, but these errors were encountered:
In our work with pluggable DID resolvers, I found that we needed the ability to configure the plugin at startup to set values relevant to the resolver plugin. However, as a plugin, we can't add command line arguments to the ACA-Py instance so we resorted to loading a separate yaml file specified by an environment variable. This worked fine but it got me thinking about easier to use solutions, especially when considering loading multiple resolvers (i.e. uniresolver + didcomm resolver + ...) and anticipating writing more plugins in the near future that will likewise require their own configuration.
So, to field an idea I had, what do we think of a
--plugin-config plugin.yml
command line argument that just loads the yaml into a map in settings and performs no further validation? Plugins would then subsequently look underneath their own namespace and perform validation if necessary for the options they define. In essence, I view this as analogous tosetup.cfg
/setup.ini
/pyproject.toml
tool configurations, allowing various plugins to retrieve configuration from a single source rather than having one configuration file and environment variable each. This also avoids having to do multiple passes of command line argument parsing to allow plugins to define their own. This multi-pass parsing is, of course, doable but doesn't feel as clean to me.The text was updated successfully, but these errors were encountered: