Implemented a custom JPA repository for the Person entity and refactored the REST controller accordingly.