@Override
    public String getPersonAsJSON(Integer id) throws NotFoundException {
        EntityManager em = emf.createEntityManager();
         List<Person> persons = new ArrayList<>();
        Person person = em.find(Person.class, id);
        persons.add(person);
        if (person == null) {
            throw new NotFoundException("No person exists for the given id!");
        }
        return gson.toJson(persons);
    }