Closed dmitry-sinina closed 3 years ago
Routing->Destination->ID
Feb 13 15:32:52 demo-yeti yeti-web[497]: [8caa2550-5ccf-4f05-9869-23a122bbb26f] [10.2.48.3] Started GET "/destinations/4201558" for 10.2.48.3 at 2021-02-13 15:32:52 +0000 Feb 13 15:32:52 demo-yeti yeti-web[497]: [8caa2550-5ccf-4f05-9869-23a122bbb26f] [10.2.48.3] Processing by DestinationsController#show as HTML Feb 13 15:32:52 demo-yeti yeti-web[497]: [8caa2550-5ccf-4f05-9869-23a122bbb26f] [10.2.48.3] Parameters: {"id"=>"4201558"} Feb 13 15:32:52 demo-yeti yeti-web[497]: [8caa2550-5ccf-4f05-9869-23a122bbb26f] [10.2.48.3] Rendering vendor/bundle/ruby/2.6.0/gems/activeadmin-2.7.0/app/views/active_admin/resource/show.html.arb Feb 13 15:32:52 demo-yeti yeti-web[497]: [8caa2550-5ccf-4f05-9869-23a122bbb26f] [10.2.48.3] [POLICY] invalid action truncate_long_time_stats? for policy Routing::DestinationPolicy Feb 13 15:32:52 demo-yeti yeti-web[497]: [8caa2550-5ccf-4f05-9869-23a122bbb26f] [10.2.48.3] [ActiveJob] Enqueued Worker::CaptureErrorJob (Job ID: 5c638c47-1728-49a1-9c02-550372382e61) to Async(capture_error) with arguments: {"environment"=>"prod", "event_id"=>"6293b3f7d3cc48d5828f6dfcbba40f8b", "extra"=>{"server"=>{"os"=>{"name"=>"Linux", "version"=>"#1 SMP Debian 4.19.171-2 (2021-01-30)", "build"=>"4.19.0-14-amd64", "kernel_version"=>"Linux demo-yeti 4.19.0-14-amd64 #1 SMP Debian 4.19.171-2 (2021-01-30) x86_64 GNU/Linux"}, "runtime"=>{"name"=>"ruby2.6", "version"=>"ruby 2.6.5p114 (2019-10-01 revision 67812) [x86_64-linux-gnu]"}}}, "level"=>"error", "logger"=>"ruby", "message"=>"Invalid action truncate_long_time_stats? for policy Routing::DestinationPolicy", "modules"=>{"rake"=>"13.0.3", "concurrent-ruby"=>"1.1.7", "i18n"=>"1.8.5", "minitest"=>"5.14.3", "thread_safe"=>"0.3.6", "tzinfo"=>"1.2.9", "activesupport"=>"5.2.4.5", "builder"=>"3.2.4", "erubi"=>"1.10.0", "mini_portile2"=>"2.5.0", "racc"=>"1.5.2", "nokogiri"=>"1.11.1", "rails-dom-testing"=>"2.0.3", "crass"=>"1.0.6", "loofah"=>"2.8.0", "rails-html-sanitizer"=>"1.0.4", "actionview"=>"5.2.4.5", "rack"=>"2.1.4", "rack-test"=>"1.1.0", "actionpack"=>"5.2.4.5", "nio4r"=>"2.5.4", "websocket-extensions"=>"0.1.5", "websocket-driver"=>"0.7.3", "actioncable"=>"5.2.4.5", "globalid"=>"0.4.2", "activejob"=>"5.2.4.5", "mini_mime"=>"1.0.2", "mail"=>"2.7.1", "actionmailer"=>"5.2.4.5", "active_admin_date_range_preset"=>"0.3.1", "arbre"=>"1.2.1", "formtastic"=>"3.1.5", "formtastic_i18n"=>"0.6.0", "has_scope"=>"0.7.2", "method_source"=>"1.0.0", "thor"=>"0.20.3", "railties"=>"5.2.4.5", "responders"=>"2.4.0", "inherited_resources"=>"1.11.0", "jquery-rails"=>"4.3.4", "kaminari-core"=>"1.2.1", "kaminari-actionview"=>"1.2.1", "activemodel"=>"5.2.4.5", "arel"=>"9.0.0", "activerecord"=>"5.2.4.5", "kaminari-activerecord"=>"1.2.1", "kaminari"=>"1.2.1", "ransack"=>"2.1.1", "ffi"=>"1.9.25", "sassc"=>"2.3.0", "sprockets"=>"3.7.2", "sprockets-rails"=>"3.2.2", "tilt"=>"2.0.9", "sassc-rails"=>"2.1.2", "activeadmin"=>"2.7.0", "coffee-script-source"=>"1.12.2", "execjs"=>"2.7.0", "coffee-script"=>"2.4.1", "coffee-rails"=>"4.2.2", "mimemagic"=>"0.3.5", "marcel"=>"0.3.3", "activestorage"=>"5.2.4.5", "bundler"=>"2.1.4", "rails"=>"5.2.4.5", "xdan-datetimepicker-rails"=>"2.5.4", "active_admin_datetimepicker"=>"0.7.4", "activerecord-import"=>"1.0.4", "rchardet"=>"1.8.0", "rubyzip"=>"1.3.0", "active_admin_import"=>"4.1.2", "active_admin_scoped_collection_actions"=>"0.3.5", "active_admin_sidebar"=>"1.1.0", "active_admin_theme"=>"1.1.2", "ar_outer_joins"=>"0.2.0", "pg"=>"1.0.0", "active_record_extended"=>"1.4.0", "locale"=>"2.1.2", "text"=>"1.3.1", "gettext"=>"3.2.9", "fast_gettext"=>"1.6.0", "gettext_i18n_rails"=>"1.8.0", "activeldap"=>"5.1.1", "activemodel-serializers-xml"=>"1.0.2", "rexml"=>"3.2.4", "kramdown"=>"2.3.0", "mustache"=>"1.0.5", "rspec-support"=>"3.7.1", "rspec-core"=>"3.7.1", "diff-lcs"=>"1.3", "rspec-expectations"=>"3.7.0", "rspec-mocks"=>"3.7.0", "rspec"=>"3.7.0", "rspec_api_documentation"=>"5.0.0", "apitome"=>"0.1.0", "bcrypt"=>"3.1.13", "msgpack"=>"1.2.6", "bootsnap"=>"1.3.2", "sass"=>"3.4.25", "sass-rails"=>"5.0.8", "chosen-rails"=>"1.5.2", "chunky_png"=>"1.3.10", "multi_json"=>"1.13.1", "compass-core"=>"1.0.3", "compass-import-once"=>"1.0.5", "rb-fsevent"=>"0.10.3", "rb-inotify"=>"0.9.10", "compass"=>"1.0.3", "compass-rails"=>"3.0.2", "d3-rails"=>"3.5.2", "daemons"=>"1.2.6", "delayed_job"=>"4.1.5", "delayed_job_active_record"=>"4.1.3", "orm_adapter"=>"0.5.0", "warden"=>"1.2.8", "devise"=>"4.7.1", "net-ldap"=>"0.16.1", "devise_ldap_authenticatable"=>"0.8.7", "request_store"=>"1.4.1", "draper"=>"3.0.1", "ruby-ole"=>"1.2.12.1", "spreadsheet"=>"1.1.7", "excelinator"=>"1.3.1", "multipart-post"=>"2.1.1", "faraday"=>"0.17.1", "font-awesome-rails"=>"4.7.0.4", "get_process_mem"=>"0.2.5", "jquery-tablesorter"=>"1.25.0", "jquery-ui-rails"=>"6.0.1", "net_tcp_client"=>"2.0.1", "netstring"=>"0.0.3", "oj"=>"2.18.5", "jrpc"=>"1.0.1", "jsonapi-resources"=>"0.9.1.beta1", "jwt"=>"1.5.6", "knock"=>"2.1.1", "libv8"=>"3.16.14.19", "novus-nvd3-rails"=>"1.7.1", "odf-report"=>"0.5.2", "paper_trail"=>"9.0.0", "parallel"=>"1.12.1", "pg_sql_caller"=>"0.1.0", "pg_advisory_lock"=>"0.2.0", "prometheus_exporter"=>"0.5.1", "pgq_prometheus"=>"0.2.2", "puma"=>"4.3.5", "puma_worker_killer"=>"0.1.1", "pundit"=>"1.1.0", "ref"=>"2.0.0", "sass-globbing"=>"1.1.5", "secondbase"=>"2.1.4", "sentry-raven"=>"2.12.3", "syslog-logger"=>"1.6.8", "therubyracer"=>"0.12.3", "timeliness"=>"0.4.4", "uglifier"=>"4.1.8", "validates_timeliness"=>"4.1.1", "yetis_node"=>"1.0.0", "zip-zip"=>"0.3"}, "platform"=>"ruby", "release"=>"1.11.0", "sdk"=>{"name"=>"raven-ruby", "version"=>"2.12.3"}, "server_name"=>"demo-yeti", "tags"=>{"rails_env"=>"production", "node_name"=>"demo.yeti-switch.org", "request_id"=>"8caa2550-5ccf-4f05-9869-23a122bbb26f", "controller_name"=>"destinations", "action_name"=>"show"}, "timestamp"=>"2021-02-13T15:32:52", "user"=>{"id"=>3, "username"=>"admin", "class"=>"AdminUser"}, "logentry"=>{"params"=>[], "message"=>"Invalid action truncate_long_time_stats? for policy Routing::DestinationPolicy"}, "request"=>{"headers"=>{"Version"=>"HTTP/1.0", "Host"=>"demo.yeti-switch.org", "X-Proxy-Port"=>"80", "X-Real-Ip"=>"10.2.48.3", "X-Forwarded-For"=>"10.2.48.3", "X-Forwarded-Proto"=>"https", "Connection"=>"close", "Upgrade-Insecure-Requests"=>"1", "User-Agent"=>"Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/83.0.4103.116 Safari/537.36", "Accept"=>"text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9", "Sec-Fetch-Site"=>"same-origin", "Sec-Fetch-Mode"=>"navigate", "Sec-Fetch-User"=>"?1", "Sec-Fetch-Dest"=>"document", "Referer"=>"https://demo.yeti-switch.org/destinations/4201558", "Accept-Encoding"=>"gzip, deflate, br", "Accept-Language"=>"en-US,en;q=0.9", "If-None-Match"=>"W/\"3eb66452672a6a70ac16c8e36b95738f\"", "Client-Ip"=>"10.2.48.3"}, "env"=>{"REMOTE_ADDR"=>"127.0.0.1", "SERVER_NAME"=>"demo.yeti-switch.org", "SERVER_PORT"=>"443"}, "cookies"=>{"_ga"=>"GA1.2.1219814866.1607860881", "_yeti_session"=>"yzFgYZvZ9ZK9A+LXjcmlFc9UaRjRZB5xylxk7ABqKRmWEmiSOGsCwgPiDHJNKwKk36CNVrA56pSR2bCPoelfDDHHAMwdh7+R9q6NQ++/fQmJAPi6NdIuW3+ioQ2+YFQviSLP6XdkGgfI9QWIDICBKb3qMXC6W8WgyjrATKfR5H8qjZ1m/KRD87MW7Mo6EKmf8tJ8uj70moYjQWZnGvcSgxbqEaKEV8pLBii9EZVOYjNL5C7CDAvXX/ttaRbP9aZCowVCDLjDBML1GpJ/vwNJQ4x4k6cuyH6mEOcnTdxqzPuPY/y0jBmRamZ/xb4Swgdk4DeyLVCvFqQJ0C85xjYgpxxs0Dpn17FqPqsabWF0jh3ZeQ==--X6V285LFscLTVS81--KpeIYXEKF3MQf8+JtN0ZxQ=="}, "url"=>"https://demo.yeti-switch.org/destinations/4201558", "method"=>"GET", "query_string"=>"", "data"=>nil}}
following line should be added to Routing::DestinationPolicy
Routing::DestinationPolicy
alias_rule :truncate_long_time_stats?, to: :perform? # DSL acts_as_stat
Routing->Destination->ID