add parent/child and add logging