Inspired by Keep a Changelog.
Note: this project adheres to Semantic Versioning.
- Changed ProcessSettings to directly use
safe_load_file
method.
- Fix ProcessSettings::Testing::Minitest::Helpers to prepend #teardown instead of overriding it.
- Fix ProcessSettings::Testing::Minitest::Helpers#teardown to call super after resetting the ProcessSettings instance.
- Allow
psych
major versions greater than 3.2.
- Add require for
active_support/core_ext
to support active_support >= 7.1 on Ruby 3.2.
0.19.1 - 2022-12-16
- Fixed a bug in
ProcessSettings::Watchdog
preventing it from raising out of sync errors
- Removed explicit support for Rails 4
0.19.0 - 2021-07-09
- Fixed a bug where accessing a setting that is a
Hash
defined across multiple file entries would return the last matching value instead of deep merging the full set of settings
0.18.0 - 2020-11-24
- Added
FileMonitor#start_watchdog_thread
andFileMonitor#start_watchdog_thread
to be used to start and stop the@watchdog_thread
. The watchdog will poll once a minute to double-check if any changes have been missed due to a bug in thelisten
gem or the supporting OS drivers likeinotify
.
0.17.0 - 2020-10-12
- Added
FileMonitor#restart_after_fork
to be used to restart the file monitoring after process forking occurs like withunicorn
0.16.0 - 2020-09-24
- Updated the AbstractMonitor to no longer log cache hits and misses
0.15.1 - 2020-09-23
- Fixed bug where if
make
output of combined_process_settings.yml was unchanged (ignoring version number), that version would be considered a no-op and discarded EVEN IF it was different from what is live in S3. Now, the make output is compared to current as well as what's live in S3; if either are different, the new version is committed and pushed live.
0.15.0 - 2020-09-08
- Added a
warn
when dynamic keys overlap with static ones and addedfull_context_cache
to avoid repetitive deep merges.
0.14.0 - 2020-08-13
- Separated
ProcessSettings::Testing::Minitest::Helpers
fromProcessSettings::Testing::RSpec::Helpers
since it is difficult to infer which is which. LeftProcessSettings::Testing::Helpers
as an alias forProcessSettings::Testing::RSpec::Helpers
for backward-compatibility.
0.13.3 - 2020-08-11
- Fixed
Testing::Helpers
forminitest
to define ateardown
method rather than call ateardown
helper.
0.13.2 - 2020-08-07
- Fixed typo in error message: "brew upgrade".
0.13.1 - 2020-08-06
- Removed explicit
: null
becauselibyaml
0.2.5 doesn't write the trailing space to key off. Instead, explicitly depend on thepsych
gem and check that libyaml is at least 0.2.5.
0.12.0 - 2020-08-06
bin/combine_process_settings
now uses an explicit: null
value for null (nil in Ruby) values, vs. the former implicit:
at end of line. This is important because the trailing space was sometimes deleted when committed and pushed, depending on editor settings and git(hub) hook configuration.
0.11.0 - 2020-06-16
ProcessSettings::Testing::Helpers
now automatically registers anafter
/teardown
block to setProcessSettings.instance
back to the default that was there before it was optionally overridden bystub_process_settings
.ProcessSettings::FileMonitor.initialize
now accepts an optional keyword argumentenvironment:
. This is an environment string like can be found inRails.env
for Rails applications. It is used to infer to disable the listen thread in the 'test' environment. If left to its default ofnil
, the environment is inferred by the first of these values that is present:Rails.env
(if available)ENV['RAILS_ENV']
ENV['SERVICE_ENV']
ProcessSettings::FileMonitor#listen_thread_running?
indicates whether the listen thread is running.
- Moved deprecation from
#initialize
up to.new
so that warning will point to caller. - Deprecated public
FileMonitor#start
method. This will becomeprivate
in v1.0. - Deprecated lazy
ProcessSettings#instance
explicitly so that warning will point to caller. - Cleaned up noisy spec output including deprecation warnings.
- Explicit contract enforcement:
raise ArgumentError
if logger: passed asnil
. - Allow 'true' ('1') or 'false' ('0') values for
ENV['DISABLE_LISTEN_CHANGE_MONITORING']
; default to 'false' whenRails.env || ENV['SERVICE_ENV']) == 'test'
.
- Fixed memoization of
Target.true_target
.
0.10.5 - 2020-05-27
- Fixed bug where setting a monitor instance at the
ProcessSettings
and theProcessSettings::Monitor
can cause unexpected errors due to two monitors being configured.
0.10.4 - 2020-05-21
- Added missing
require 'active_support/deprecation'
in case caller hasn't done that.
0.10.3 - 2020-05-20
- Added missing
require 'active_support'
in case caller hasn't done that.
0.10.2 - 2020-05-18
- Fixed bug where running
bin/diff_process_settings
multiple times would cause errors by switching the script to useTempdir
for generating temporary file name
0.10.1 - 2020-05-16
- Added missing
require_relative 'abstract_monitor'
.
0.10.0 - 2020-05-16
bin/diff_process_settings
now supports a--silent
option (likecmp --silent
) while still ignoring the meta-data in the file including the version number.
bin/combine_process_settings
now uses the above when deciding whether to overwritecombined_process_settings.yml
or leave it. Therefore if no settings change--just the version number--the output file will be left untouched.
0.9.0 - 2020-05-15
- Added a new
ProcessSettings::Testing::Monitor
class for testing with process settings - Added a new
ProcessSettings::Testing::Helpers
module for testing with process settings - Added support for rails 5 and 6.
- Added appraisal tests for all supported rails version: 4/5/6
- Renamed
ProcessSettings::Monitor
toProcessSettings:FileMonitor
, withMonitor
left as a (deprecated) alias.
- Deprecated the
ProcessSettings::Testing::MonitorStub
to be replaced by the newProcessSettings::Testing::Monitor
ProcessSettings::Monitor
will be replaced byProcessSettings::FileMonitor
0.8.2 - 2020-04-22
- Fixed bug where an
ArgumentError
would raise out ofTarget#with_static_context
when a target hash uses a nested key that doesn't exist in the static context
0.8.1 - 2020-04-21
- Fixed bug where
MonitorStub
was not responding to#[]
0.8.0 - 2020-04-07
Monitor
instance now implements#[]
andProcessSettings[]
delegates to it. This enables the preferred usage ofwhen_updated
, where thesettings
block argument is used to read the settings:ProcessSettings::Monitor.instance.when_updated do |settings| logger.level = settings['gem', 'listen', 'log_level'] end
0.7.1 - 2020-03-31
- Reverted
rescue
syntax that required Ruby 2.6 since that broke some gems still on Ruby 2.4.
0.7.0 - 2020-03-31
ProcessSettings::Monitor.when_updated
was added as a replacement toProcessSettings::Monitor.on_change
. This allows the user to not only register a block to execute when a change is detected, but also allows the initial execution of the block during setup. This allows for cleaner, dryer code.
- Don't check for file_path or logger config if
instance =
has already been called; it's not necessary.
ProcessSettings::Monitor.on_change
has been deprecated; it will be removed in version1.0.0
.ProcessSettings::Monitor.when_updated
should be used instead.