convert to new rails script
add filter parameter logging