Story story = storyRepository.findByPersistanceId(persistanceId);
// if the story is not found, return a global error
if (story == null) {
Errors errors = AgilePlanningObjectFactory.getErrors();
errors.reject("story.doesntExistsInDatabase");
return errors;
}
// if the story is found, update the persistanceVersion for concurrency management
story.setPersistanceVersion(persistanceVersion);