optimize touch_all_products performance

merge https://github.com/spree/spree/pull/4910 file change to 1 commit.