Converted task_id and position to integers an extra layer of validation
Added Transactional decorator for business logic to keep this concern separate