-
Notifications
You must be signed in to change notification settings - Fork 429
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Service config in maps #3624
Service config in maps #3624
Conversation
This comment was marked as outdated.
This comment was marked as outdated.
Codecov Report
@@ Coverage Diff @@
## master #3624 +/- ##
==========================================
- Coverage 81.01% 81.00% -0.01%
==========================================
Files 427 427
Lines 32135 32126 -9
==========================================
- Hits 26033 26025 -8
+ Misses 6102 6101 -1
Continue to review full report at Codecov.
|
Also: simplify defaults - The CI-specific report intervals had no effect because the default ones were set explicitly in the TOML file anyway
This comment was marked as outdated.
This comment was marked as outdated.
Follow the logic from mongoose_modules.
The tests are very similar to the ones for replace_modules, but it seems that there are enough differences to keep them separate.
Follow the logic from dynamic_modules. Code resue does not seem to make much sense because pof the differences.
- Use maps with defaults - Do not skip tests if system_metrics are not running - Use dynamic_services
7799927
to
82658d2
Compare
This comment was marked as outdated.
This comment was marked as outdated.
- Provide the db pool explicitly to test defaults that are used when the service is not loaded, and thus the config is not available.
It was previously untested. It is added to the 'host_types' file test case as well.
This comment was marked as outdated.
This comment was marked as outdated.
d63948c
to
0ae1905
Compare
This comment was marked as outdated.
This comment was marked as outdated.
This way it is easier to restart it in tests.
- Use maps with defaults - Use dynamic_services - Provide the DB pool explicitly when the service is not loaded
0ae1905
to
cc1c119
Compare
riak_mnesia_24 / riak_mnesia / cc1c119 small_tests_24 / small_tests / cc1c119 small_tests_23 / small_tests / cc1c119 dynamic_domains_pgsql_mnesia_24 / pgsql_mnesia / cc1c119 bosh_SUITE:essential:accept_higher_hold_value{error,
{{assertEqual,
[{module,bosh_SUITE},
{line,251},
{expression,"get_bosh_sessions ( )"},
{expected,[]},
{value,
[{bosh_session,<<"4c361b8af5df4d5949dc7affef5dadd940ba1cdb">>,
<8633.6848.0>}]}]},
[{bosh_SUITE,accept_higher_hold_value,1,
[{file,"/home/circleci/project/big_tests/tests/bosh_SUITE.erl"},
{line,251}]},
{test_server,ts_tc,3,[{file,"test_server.erl"},{line,1783}]},
{test_server,run_test_case_eval1,6,
[{file,"test_server.erl"},{line,1292}]},
{test_server,run_test_case_eval,9,
[{file,"test_server.erl"},{line,1224}]}]}} dynamic_domains_mysql_redis_24 / mysql_redis / cc1c119 dynamic_domains_pgsql_mnesia_23 / pgsql_mnesia / cc1c119 ldap_mnesia_24 / ldap_mnesia / cc1c119 dynamic_domains_mssql_mnesia_24 / odbc_mssql_mnesia / cc1c119 ldap_mnesia_23 / ldap_mnesia / cc1c119 internal_mnesia_24 / internal_mnesia / cc1c119 pgsql_mnesia_23 / pgsql_mnesia / cc1c119 pgsql_mnesia_24 / pgsql_mnesia / cc1c119 mysql_redis_24 / mysql_redis / cc1c119 elasticsearch_and_cassandra_24 / elasticsearch_and_cassandra_mnesia / cc1c119 mssql_mnesia_24 / odbc_mssql_mnesia / cc1c119 dynamic_domains_pgsql_mnesia_24 / pgsql_mnesia / cc1c119 riak_mnesia_24 / riak_mnesia / cc1c119 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All looks great :) I left two minor suggestions.
Store service options in maps with defaults. Other changes for each service are listed below.
service_admin_extra
:service_domain_db
:service_mongoose_system_metrics
:Other changes:
dynamic_services
, which uses the newmongoose_service:replace_services/2
. This is very similar todynamic_modules
, which usesmongoose_modules:replace_modules/2
. There are differences between services and modules that make direct code reuse more difficult, so the code is just made to be consistent.