Add support for logging severity

please review @r0mant @jeremyschlatter @anton-efimenko 
borowed -> borrowed