Entity: change primary_keys to instance variable