handle add task
add lifecycle callbacks for task entity
handle list tasks