X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/c235da62cb5425e3906f58f398e84e70fec9ae87..0596129229750c593066e414d9315f643585bc3e:/services/api/lib/tasks/delete_old_container_logs.rake diff --git a/services/api/lib/tasks/delete_old_container_logs.rake b/services/api/lib/tasks/delete_old_container_logs.rake index 7a0ab3826a..db1b3667cc 100644 --- a/services/api/lib/tasks/delete_old_container_logs.rake +++ b/services/api/lib/tasks/delete_old_container_logs.rake @@ -8,11 +8,9 @@ # from the logs table. namespace :db do - desc "Remove old container log entries from the logs table" + desc "deprecated / no-op" task delete_old_container_logs: :environment do - delete_sql = "DELETE FROM logs WHERE id in (SELECT logs.id FROM logs JOIN containers ON logs.object_uuid = containers.uuid WHERE event_type IN ('stdout', 'stderr', 'arv-mount', 'crunch-run', 'crunchstat') AND containers.log IS NOT NULL AND now() - containers.finished_at > interval '#{Rails.configuration.Containers.Logging.MaxAge.to_i} seconds')" - - ActiveRecord::Base.connection.execute(delete_sql) + Rails.logger.info "this db:delete_old_container_logs rake task is no longer used" end end