You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2021/10/01 06:32:55 UTC

[GitHub] [flink] jherico opened a new pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

jherico opened a new pull request #17401:
URL: https://github.com/apache/flink/pull/17401


   ## What is the purpose of the change
   
   * Fix the errors generated by the metrics code when reading from a Kafka topic that includes periods in the names. The filter for the metric tries to compare the topic name against the corresponding metric `topic` tag, but the metric tags execute a transform on the topic name that replaces any periods with underscores, so if you try to find the records-lag metric in via the changed function, it logs a WARN level log with an exception stack trace.
   
   ## Brief change log
   
     - Execute the required transformation in the `getRecordsLagMetric` function
   
   ## Verifying this change
   
   This change is a trivial rework / code cleanup without any test coverage.
   
   Unfortunately while some of the tests in `KafkaSourceReaderTest` cover this code and changing the topic name in that class to `"Kafka.Source.Reader.Test"` even causes the issue, it doesn't actually cause the tests to fail.  Further, the `KafkaSourceReaderMetricsTest` doesn't have any coverage of the `getRecordsLagMetric` function at all, which is disappointing. 
   
   ## Does this pull request potentially affect one of the following parts:
   
     - Dependencies (does it add or upgrade a dependency): no
     - The public API, i.e., is any changed class annotated with `@Public(Evolving)`: no
     - The serializers: no
     - The runtime per-record code paths (performance sensitive): no
     - Anything that affects deployment or recovery: no
     - The S3 file system connector: no
   
   ## Documentation
   
     - Does this pull request introduce a new feature? no
     - If yes, how is the feature documented? not applicable
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] AHeise commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
AHeise commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-937502238


   @PatrickRen could you PTAL? I think we should have a test case for record lag metric as well.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] MartijnVisser commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
MartijnVisser commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-965061669


   @jherico Do you think you could add the tests or do you need some more help? 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] jherico commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
jherico commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-971859106


   ok, it's a pretty small change I know, but I'm kind of irked that #17773 appears to include my _exact_ changes but without my actual commit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] AHeise commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
AHeise commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-966057682


   Does it make sense to re-assign the task to someone else?


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] jherico closed pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
jherico closed pull request #17401:
URL: https://github.com/apache/flink/pull/17401


   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] fapaul commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
fapaul commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-971910179


   @jherico sorry that was my fault :( I did not think about when copying your code instead of cherry-picking the commit.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] jherico commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
jherico commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-965683514


   I can most likely add some tests, I've just been very busy lately and it
   hasn't been a priority.  Will try to see if I can manage in the next week
   or so.
   
   On Wed, Nov 10, 2021 at 3:58 AM MartijnVisser ***@***.***>
   wrote:
   
   > @jherico <https://github.com/jherico> Do you think you could add the
   > tests or do you need some more help?
   >
   > —
   > You are receiving this because you were mentioned.
   > Reply to this email directly, view it on GitHub
   > <https://github.com/apache/flink/pull/17401#issuecomment-965061669>, or
   > unsubscribe
   > <https://github.com/notifications/unsubscribe-auth/AALWNSSFRJKQ5RYJ6WJPFUDULJM5PANCNFSM5FD6JTWQ>
   > .
   > Triage notifications on the go with GitHub Mobile for iOS
   > <https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
   > or Android
   > <https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
   >
   >
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] MartijnVisser commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
MartijnVisser commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-965686175


   That would be great. There are multiple contributors who would like to help out (it's a bug that we would like to resolve asap) so do let know in case you need any help. 


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-931955541


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "fd01adb87c54abe436ac04d4059a71784762cabd",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=24690",
       "triggerID" : "fd01adb87c54abe436ac04d4059a71784762cabd",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * fd01adb87c54abe436ac04d4059a71784762cabd Azure: [SUCCESS](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=24690) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-931955541


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "fd01adb87c54abe436ac04d4059a71784762cabd",
       "status" : "SUCCESS",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=24690",
       "triggerID" : "fd01adb87c54abe436ac04d4059a71784762cabd",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * fd01adb87c54abe436ac04d4059a71784762cabd Azure: [SUCCESS](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=24690) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
flinkbot commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-931955541


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "fd01adb87c54abe436ac04d4059a71784762cabd",
       "status" : "UNKNOWN",
       "url" : "TBD",
       "triggerID" : "fd01adb87c54abe436ac04d4059a71784762cabd",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * fd01adb87c54abe436ac04d4059a71784762cabd UNKNOWN
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] PatrickRen commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
PatrickRen commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-946442553


   Sorry for my late response! @jherico Here's my implementation of the test case that might be helpful. Feel free to cherry-pick it or implement your own. 
   
   https://github.com/PatrickRen/flink/commit/7e7f0d4e9e79e132965df517c7eae53bdf26ab9c
   
   Another choice is to use parameterized test in JUnit 5 for testing `pendingRecords` with different topic names including with special characters, but first you need to migrate `KafkaPartitionSplitReaderTest` to JUnit 5 style. Here's my implementation: 
   
   https://github.com/PatrickRen/flink/commit/e17ac779ae7b228681ba1aae2944e13a287469ae


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot edited a comment on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
flinkbot edited a comment on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-931955541


   <!--
   Meta data
   {
     "version" : 1,
     "metaDataEntries" : [ {
       "hash" : "fd01adb87c54abe436ac04d4059a71784762cabd",
       "status" : "PENDING",
       "url" : "https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=24690",
       "triggerID" : "fd01adb87c54abe436ac04d4059a71784762cabd",
       "triggerType" : "PUSH"
     } ]
   }-->
   ## CI report:
   
   * fd01adb87c54abe436ac04d4059a71784762cabd Azure: [PENDING](https://dev.azure.com/apache-flink/98463496-1af2-4620-8eab-a2ecc1a2e6fe/_build/results?buildId=24690) 
   
   <details>
   <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot run travis` re-run the last Travis build
    - `@flinkbot run azure` re-run the last Azure build
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] flinkbot commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
flinkbot commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-931950142


   Thanks a lot for your contribution to the Apache Flink project. I'm the @flinkbot. I help the community
   to review your pull request. We will use this comment to track the progress of the review.
   
   
   ## Automated Checks
   Last check on commit fd01adb87c54abe436ac04d4059a71784762cabd (Fri Oct 01 06:35:44 UTC 2021)
   
   **Warnings:**
    * No documentation files were touched! Remember to keep the Flink docs up to date!
    * **This pull request references an unassigned [Jira ticket](https://issues.apache.org/jira/browse/FLINK-24409).** According to the [code contribution guide](https://flink.apache.org/contributing/contribute-code.html), tickets need to be assigned before starting with the implementation work.
   
   
   <sub>Mention the bot in a comment to re-run the automated checks.</sub>
   ## Review Progress
   
   * ❓ 1. The [description] looks good.
   * ❓ 2. There is [consensus] that the contribution should go into to Flink.
   * ❓ 3. Needs [attention] from.
   * ❓ 4. The change fits into the overall [architecture].
   * ❓ 5. Overall code [quality] is good.
   
   Please see the [Pull Request Review Guide](https://flink.apache.org/contributing/reviewing-prs.html) for a full explanation of the review process.<details>
    The Bot is tracking the review progress through labels. Labels are applied according to the order of the review items. For consensus, approval by a Flink committer of PMC member is required <summary>Bot commands</summary>
     The @flinkbot bot supports the following commands:
   
    - `@flinkbot approve description` to approve one or more aspects (aspects: `description`, `consensus`, `architecture` and `quality`)
    - `@flinkbot approve all` to approve all aspects
    - `@flinkbot approve-until architecture` to approve everything until `architecture`
    - `@flinkbot attention @username1 [@username2 ..]` to require somebody's attention
    - `@flinkbot disapprove architecture` to remove an approval you gave earlier
   </details>


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org



[GitHub] [flink] AHeise commented on pull request #17401: [FLINK-24409][connectors] Fix metrics errors with topics names with periods

Posted by GitBox <gi...@apache.org>.
AHeise commented on pull request #17401:
URL: https://github.com/apache/flink/pull/17401#issuecomment-937502238


   @PatrickRen could you PTAL? I think we should have a test case for record lag metric as well.


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscribe@flink.apache.org

For queries about this service, please contact Infrastructure at:
users@infra.apache.org