See the approach in lib/composite_primary_keys/active_record_overides.rb