Clenup env, cli-options and deprecations of cache settings
What does this MR do?
Fix for mess and regression implemented with !968 (merged).
Why was this MR needed?
With !968 (merged) we've refactored cache mechanism and added support for GCS. Unfortunately:
- GCS
AccessID
andPrivateKey
options are not exposed to command line. - CLI-options and ENV variables related to cache configuration were not fully cleaned. Since we're deprecating old configuration options and plan to remove them with %12.0, we should ensure that current state is clean and in the shape that it should be.
- Currently some of options are duplicated (e.g.
--cache-s3-insecure
which is the same for new and for deprecated setting) which causes any usage of commands using these settings to panic withduplicated option
.
This MR adds the cleanup that should be done with !968 (merged) and removes the regression introduced with it.
Are there points in the code the reviewer needs to double check?
Deprecated fields received a getter method that looks for deprecated ENV value. This was required because without a long
or short
specification command option is not registered by application and ENV is not supported. At the same time old name couldn't be used because this ends with a duplicated option
error. And we still need to have these fields to properly handle deprecated values in config.toml
field. Therefore set of getter methods was added by me - it will be removed with %12.0 (tracked with #3473 (closed)).
Does this MR meet the acceptance criteria?
-
Documentation created/updated -
Added tests for this feature/bug -
In case of conflicts with master
- branch was rebased
What are the relevant issue numbers?
Closes #3573 (closed)