I think products are associated with repositories through environment_products. Couldn't be the association added? My concern is that `map(&:product)` will generate query for each repo.