> Hi there,
>
> We're sending the uWSGI logs for a large number of vassals across a
> cluster of web servers to an rsyslog instance that splits them up by
> domain and logs them to appropriate files.  So that the rsyslog instance
> can work out which domain a particular message relates to, we're adding
> a prefix using logdate:
>
>     logdate = www.thedomainname.com %%F %%T
>
> This works perfectly, except when the domain name is very long. Looking
> at the uWSGI code, it seems that there's a 64-character limit on the
> prefix once the logdate strftime string has been expanded.
>
> Is there a better way of doing this?  We've seen that there's also a
> log-prefix config parameter, but it looks like this is just an alias for
> logdate (and log-date).
>
> If this is the right way to do it, could the 64-character limit be
> increased?
>
>
> All the best,
>
> Giles
>

Log encoders are more powerful:

log-encoder = format xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
${strftime:%%d/%%m} ${msgnl}

http://uwsgi-docs.readthedocs.org/en/latest/LogEncoders.html

technically you could change the strftime buffer of logdate/logprefix but
it is not worthy as we already have advanced formatting

-- 
Roberto De Ioris
http://unbit.it
_______________________________________________
uWSGI mailing list
[email protected]
http://lists.unbit.it/cgi-bin/mailman/listinfo/uwsgi

Reply via email to