parameterize logging