more efficient handling of strings in logging statements