[jira] [Commented] (KAFKA-1866) LogStartOffset gauge throws exceptions after log.delete()
[ https://issues.apache.org/jira/browse/KAFKA-1866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14340162#comment-14340162 ] Sriharsha Chintalapani commented on KAFKA-1866: --- [~nehanarkhede] I updated the patch can you please take a look. Thanks. > LogStartOffset gauge throws exceptions after log.delete() > - > > Key: KAFKA-1866 > URL: https://issues.apache.org/jira/browse/KAFKA-1866 > Project: Kafka > Issue Type: Bug >Reporter: Gian Merlino >Assignee: Sriharsha Chintalapani > Attachments: KAFKA-1866.patch, KAFKA-1866_2015-02-10_22:50:09.patch, > KAFKA-1866_2015-02-11_09:25:33.patch > > > The LogStartOffset gauge does "logSegments.head.baseOffset", which throws > NoSuchElementException on an empty list, which can occur after a delete() of > the log. This makes life harder for custom MetricsReporters, since they have > to deal with .value() possibly throwing an exception. > Locally we're dealing with this by having Log.delete() also call removeMetric > on all the gauges. That also has the benefit of not having a bunch of metrics > floating around for logs that the broker is not actually handling. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (KAFKA-1866) LogStartOffset gauge throws exceptions after log.delete()
[ https://issues.apache.org/jira/browse/KAFKA-1866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14324656#comment-14324656 ] Sriharsha Chintalapani commented on KAFKA-1866: --- [~nehanarkhede] pinging for a review. Thanks. > LogStartOffset gauge throws exceptions after log.delete() > - > > Key: KAFKA-1866 > URL: https://issues.apache.org/jira/browse/KAFKA-1866 > Project: Kafka > Issue Type: Bug >Reporter: Gian Merlino >Assignee: Sriharsha Chintalapani > Attachments: KAFKA-1866.patch, KAFKA-1866_2015-02-10_22:50:09.patch, > KAFKA-1866_2015-02-11_09:25:33.patch > > > The LogStartOffset gauge does "logSegments.head.baseOffset", which throws > NoSuchElementException on an empty list, which can occur after a delete() of > the log. This makes life harder for custom MetricsReporters, since they have > to deal with .value() possibly throwing an exception. > Locally we're dealing with this by having Log.delete() also call removeMetric > on all the gauges. That also has the benefit of not having a bunch of metrics > floating around for logs that the broker is not actually handling. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (KAFKA-1866) LogStartOffset gauge throws exceptions after log.delete()
[ https://issues.apache.org/jira/browse/KAFKA-1866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14316572#comment-14316572 ] Sriharsha Chintalapani commented on KAFKA-1866: --- Updated reviewboard https://reviews.apache.org/r/30084/diff/ against branch origin/trunk > LogStartOffset gauge throws exceptions after log.delete() > - > > Key: KAFKA-1866 > URL: https://issues.apache.org/jira/browse/KAFKA-1866 > Project: Kafka > Issue Type: Bug >Reporter: Gian Merlino >Assignee: Sriharsha Chintalapani > Attachments: KAFKA-1866.patch, KAFKA-1866_2015-02-10_22:50:09.patch, > KAFKA-1866_2015-02-11_09:25:33.patch > > > The LogStartOffset gauge does "logSegments.head.baseOffset", which throws > NoSuchElementException on an empty list, which can occur after a delete() of > the log. This makes life harder for custom MetricsReporters, since they have > to deal with .value() possibly throwing an exception. > Locally we're dealing with this by having Log.delete() also call removeMetric > on all the gauges. That also has the benefit of not having a bunch of metrics > floating around for logs that the broker is not actually handling. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (KAFKA-1866) LogStartOffset gauge throws exceptions after log.delete()
[ https://issues.apache.org/jira/browse/KAFKA-1866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14315682#comment-14315682 ] Sriharsha Chintalapani commented on KAFKA-1866: --- Updated reviewboard https://reviews.apache.org/r/30084/diff/ against branch origin/trunk > LogStartOffset gauge throws exceptions after log.delete() > - > > Key: KAFKA-1866 > URL: https://issues.apache.org/jira/browse/KAFKA-1866 > Project: Kafka > Issue Type: Bug >Reporter: Gian Merlino >Assignee: Sriharsha Chintalapani > Attachments: KAFKA-1866.patch, KAFKA-1866_2015-02-10_22:50:09.patch > > > The LogStartOffset gauge does "logSegments.head.baseOffset", which throws > NoSuchElementException on an empty list, which can occur after a delete() of > the log. This makes life harder for custom MetricsReporters, since they have > to deal with .value() possibly throwing an exception. > Locally we're dealing with this by having Log.delete() also call removeMetric > on all the gauges. That also has the benefit of not having a bunch of metrics > floating around for logs that the broker is not actually handling. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (KAFKA-1866) LogStartOffset gauge throws exceptions after log.delete()
[ https://issues.apache.org/jira/browse/KAFKA-1866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14284313#comment-14284313 ] Sriharsha Chintalapani commented on KAFKA-1866: --- The above patch tested by running a metrics reporter and deleting a topic. > LogStartOffset gauge throws exceptions after log.delete() > - > > Key: KAFKA-1866 > URL: https://issues.apache.org/jira/browse/KAFKA-1866 > Project: Kafka > Issue Type: Bug >Reporter: Gian Merlino >Assignee: Sriharsha Chintalapani > Attachments: KAFKA-1866.patch > > > The LogStartOffset gauge does "logSegments.head.baseOffset", which throws > NoSuchElementException on an empty list, which can occur after a delete() of > the log. This makes life harder for custom MetricsReporters, since they have > to deal with .value() possibly throwing an exception. > Locally we're dealing with this by having Log.delete() also call removeMetric > on all the gauges. That also has the benefit of not having a bunch of metrics > floating around for logs that the broker is not actually handling. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (KAFKA-1866) LogStartOffset gauge throws exceptions after log.delete()
[ https://issues.apache.org/jira/browse/KAFKA-1866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14284310#comment-14284310 ] Sriharsha Chintalapani commented on KAFKA-1866: --- Created reviewboard https://reviews.apache.org/r/30084/diff/ against branch origin/trunk > LogStartOffset gauge throws exceptions after log.delete() > - > > Key: KAFKA-1866 > URL: https://issues.apache.org/jira/browse/KAFKA-1866 > Project: Kafka > Issue Type: Bug >Reporter: Gian Merlino >Assignee: Sriharsha Chintalapani > Attachments: KAFKA-1866.patch > > > The LogStartOffset gauge does "logSegments.head.baseOffset", which throws > NoSuchElementException on an empty list, which can occur after a delete() of > the log. This makes life harder for custom MetricsReporters, since they have > to deal with .value() possibly throwing an exception. > Locally we're dealing with this by having Log.delete() also call removeMetric > on all the gauges. That also has the benefit of not having a bunch of metrics > floating around for logs that the broker is not actually handling. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (KAFKA-1866) LogStartOffset gauge throws exceptions after log.delete()
[ https://issues.apache.org/jira/browse/KAFKA-1866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14282056#comment-14282056 ] Jun Rao commented on KAFKA-1866: I think deleting a topic probably can reproduce the issue too. > LogStartOffset gauge throws exceptions after log.delete() > - > > Key: KAFKA-1866 > URL: https://issues.apache.org/jira/browse/KAFKA-1866 > Project: Kafka > Issue Type: Bug >Reporter: Gian Merlino >Assignee: Sriharsha Chintalapani > > The LogStartOffset gauge does "logSegments.head.baseOffset", which throws > NoSuchElementException on an empty list, which can occur after a delete() of > the log. This makes life harder for custom MetricsReporters, since they have > to deal with .value() possibly throwing an exception. > Locally we're dealing with this by having Log.delete() also call removeMetric > on all the gauges. That also has the benefit of not having a bunch of metrics > floating around for logs that the broker is not actually handling. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (KAFKA-1866) LogStartOffset gauge throws exceptions after log.delete()
[ https://issues.apache.org/jira/browse/KAFKA-1866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14279529#comment-14279529 ] Gian Merlino commented on KAFKA-1866: - Anything that calls log.delete() should do it. It looks like the replica-stopping code does this. In our case we started seeing these exceptions after reassigning some partitions between brokers-- perhaps a non-leading partition got moved and was delete()ed. > LogStartOffset gauge throws exceptions after log.delete() > - > > Key: KAFKA-1866 > URL: https://issues.apache.org/jira/browse/KAFKA-1866 > Project: Kafka > Issue Type: Bug >Reporter: Gian Merlino >Assignee: Sriharsha Chintalapani > > The LogStartOffset gauge does "logSegments.head.baseOffset", which throws > NoSuchElementException on an empty list, which can occur after a delete() of > the log. This makes life harder for custom MetricsReporters, since they have > to deal with .value() possibly throwing an exception. > Locally we're dealing with this by having Log.delete() also call removeMetric > on all the gauges. That also has the benefit of not having a bunch of metrics > floating around for logs that the broker is not actually handling. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (KAFKA-1866) LogStartOffset gauge throws exceptions after log.delete()
[ https://issues.apache.org/jira/browse/KAFKA-1866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14279473#comment-14279473 ] Sriharsha Chintalapani commented on KAFKA-1866: --- [~gian] any steps to reproduce this. Thanks. > LogStartOffset gauge throws exceptions after log.delete() > - > > Key: KAFKA-1866 > URL: https://issues.apache.org/jira/browse/KAFKA-1866 > Project: Kafka > Issue Type: Bug >Reporter: Gian Merlino > > The LogStartOffset gauge does "logSegments.head.baseOffset", which throws > NoSuchElementException on an empty list, which can occur after a delete() of > the log. This makes life harder for custom MetricsReporters, since they have > to deal with .value() possibly throwing an exception. > Locally we're dealing with this by having Log.delete() also call removeMetric > on all the gauges. That also has the benefit of not having a bunch of metrics > floating around for logs that the broker is not actually handling. -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (KAFKA-1866) LogStartOffset gauge throws exceptions after log.delete()
[ https://issues.apache.org/jira/browse/KAFKA-1866?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14279412#comment-14279412 ] Gian Merlino commented on KAFKA-1866: - At least, I think it has that benefit. I haven't actually tested it yet :) > LogStartOffset gauge throws exceptions after log.delete() > - > > Key: KAFKA-1866 > URL: https://issues.apache.org/jira/browse/KAFKA-1866 > Project: Kafka > Issue Type: Bug >Reporter: Gian Merlino > > The LogStartOffset gauge does "logSegments.head.baseOffset", which throws > NoSuchElementException on an empty list, which can occur after a delete() of > the log. This makes life harder for custom MetricsReporters, since they have > to deal with .value() possibly throwing an exception. > Locally we're dealing with this by having Log.delete() also call removeMetric > on all the gauges. That also has the benefit of not having a bunch of metrics > floating around for logs that the broker is not actually handling. -- This message was sent by Atlassian JIRA (v6.3.4#6332)