Sha256: 7bd3824147f3d1849f12f4998c060c12ece18ab3513cd8c0b5d308174b4f59e9
Contents?: true
Size: 843 Bytes
Versions: 16
Compression:
Stored size: 843 Bytes
Contents
require 'determinator/retrieve/dynaconf' require 'active_support/cache' retrieval = Determinator::Retrieve::Dynaconf.new(base_url: 'http://localhost:2345', service_name: 'determinator-rails') feature_cache = Determinator::Cache::FetchWrapper.new( ActiveSupport::Cache::MemoryStore.new(expires_in: 1.minute) ) Determinator.configure(retrieval: retrieval, feature_cache: feature_cache) Determinator.on_error do |error| # NewRelic::Agent.notice_error(error) end Determinator.on_missing_feature do |feature_name| # STATSD.increment 'determinator.missing_feature', tags: ["feature:#{name}"] end Determinator.on_determination do |id, guid, feature, determination| if feature.experiment? && determination != false puts "TODO: Track that user #{id}/#{guid} saw the #{determination} variant of '#{feature.name}' for analysis" end end
Version data entries
16 entries across 16 versions & 1 rubygems