You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed that using the new tally API for counters won't create a new diagnostic counter (if I understand the naming correctly) if the associated TypedPipe has 0 elements. I'd prefer if this made the counter and just put the result as 0.
The following repro works for me, assuming you have an input that contains data. I'm looking in our jobtracker (timberlake) to identify info about the counters. If you replace the false below with true, the counter name will indeed appear in our jobtracker.
def execution: Execution[unit] =
...
val output = TypedPipe.from(WritableSequenceFile[BytesWritable, BytesWritable](input))
.filter( _ => false )
.tallyAll("Counts", "testtesttest")
.writeExecution(WritableSequenceFile[BytesWritable, BytesWritable](nestedOutput))
Execution
.sequence(List(output)) // could likely be simplified
.unit
}
In the (currently non-existent) cleanup method, if we know all the possible counters that could be updated, we could increment them with 0. Maybe that would work.
The bigger issue is that currently, we allow totally dynamic counters, even though many users make them statically. I think we can pattern match to discover the static cases since we use a case class, I think, to make the TupleConverter.
I noticed that using the new
tally
API for counters won't create a newdiagnostic counter
(if I understand the naming correctly) if the associated TypedPipe has 0 elements. I'd prefer if this made the counter and just put the result as 0.The following repro works for me, assuming you have an
input
that contains data. I'm looking in our jobtracker (timberlake) to identify info about the counters. If you replace thefalse
below withtrue
, the counter name will indeed appear in our jobtracker.Also a small nit: The current docs (https://twitter.github.io/scalding/api/#com.twitter.scalding.typed.TypedPipe) don't seem to have any reference to the
tally
functionality, seems like it might need to be regenerated?The text was updated successfully, but these errors were encountered: