Code review comment for lp:~thumper/juju-core/fix-backlog-limits

Revision history for this message
Roger Peppe (rogpeppe) wrote :

As far as I can see, this makes a nice Tailer API into
a not-so-nice one because you've made a stateful
filter function and you want it to be called in just
the way you expect.

I don't think the filter function should be stateful.

I can see a couple of solutions that might be better:

1) (my preferred option) ditch the server-side maxLines
functionality completely. It could be implemented client-side by
simply closing the connection when the right number
of lines is received, but we've always got head(1),
so I'd suggest just losing it entirely.
2) add maxLines functionality to the Tailer itself.

1) might use a little extra bandwidth,
but I can't see that that would be great problem
in practice. If it is, the second option could
be implemented later.

https://codereview.appspot.com/85570045/

« Back to merge proposal