@SuppressWarnings("deprecation")
    public String format(LogRecord r) {
        StringBuilder sbuf = new StringBuilder(300); // initial guess

        String levelName = LogLevel.getVespaLogLevel(r.getLevel()).toString().toLowerCase();

        String component = r.getLoggerName();

        // format the time
        sbuf.append(VespaFormat.formatTime(r.getInstant()));
        sbuf.append("\t");

        sbuf.append(hostname).append("\t")
            .append(processID).append("/")
            .append(r.getThreadID()).append("\t")
            .append(serviceName).append("\t");

        if (component == null && componentPrefix == null) {
            sbuf.append("-");
        } else if (component == null) {
            sbuf.append(componentPrefix);
        } else if (componentPrefix == null) {
            sbuf.append(".").append(component);
        } else {
            sbuf.append(componentPrefix).append(".").append(component);
        }

        sbuf.append("\t").append(levelName).append("\t");

        // for events, there is no ordinary message string;
        // instead we render a string represantion of the event object:
        if (r.getLevel() == LogLevel.EVENT) {
            Event event = (Event) r.getParameters()[0];
            sbuf.append(VespaFormat.escape(event.toString()));
        } else {
            // otherwise, run standard java text formatting on the message
            sbuf.append(VespaFormat.escape(formatMessage(r)));
        }
        appendException(r.getThrown(), sbuf);

        sbuf.append("\n");
        return sbuf.toString();
    }
Un-escapes previously escaped string.
note: look at com.yahoo.config.StringNode.unescapeQuotedString()

@param s String that might need un-escaping
@return Returns un-escaped string
vespalog/src/main/java/com/yahoo/log/VespaFormatter.java