I have the same dilemma, as well, and was waiting for someone to comment on
it. The only reason for having the these different formats is that if you
are doing daily rolling, it looks a little ugly to have the h,m,s be
attached to the name. A case in point is log4j's [RollingFileAppender](
http://logging.apache.org/log4j/extras/apidocs/org/apache/log4j/rolling/RollingFileAppender.html).
They tie up the rolling interval with the file naming pattern - if the
pattern has hour in it, then the rolling is done every hour. If the pattern
has only day in it, then rolling is done every day.

If people are interested in accessing the rolling logs file directly for
their processing, its pretty easy to find all the files as all of the start
with `stdout` or `stderr` irrespective of the interval.




On Wed, Jun 4, 2014 at 5:26 PM, Patrick Wendell <notifications@github.com>
wrote:

> In core/src/main/scala/org/apache/spark/util/FileAppender.scala:
>
> > +}
> > +
> > +/**
> > + * Companion object to [[org.apache.spark.util.RollingFileAppender]]. Defines
> > + * names of configurations that configure rolling file appenders.
> > + */
> > +private[spark] object RollingFileAppender {
> > +  val ENABLE_PROPERTY = "spark.executor.rollingLogs.enabled"
> > +  val INTERVAL_PROPERTY = "spark.executor.rollingLogs.interval"
> > +  val SIZE_PROPERTY = "spark.executor.rollingLogs.size"
> > +  val KEEP_LAST_PROPERTY = "spark.executor.rollingLogs.keepLastN"
> > +
> > +}
> > +
> > +/** RollingFileAppender that rolls over every minute */
> > +private[spark] class MinutelyRollingFileAppender(
>
> Are these individual classes really necessary? The main thing here seems
> to be the string format... I'd actually prefer anyways to keep the string
> format the same for all of them and just use one that includes all the way
> down to seconds (d, m, y, h, m, s). That way if people switch back and
> fourth among log intervals, they don't have to change their tools that are
> reading logs.
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/apache/spark/pull/895/files#r13418926>.
>