Skip to content

Address typo and improve publishErrorTypeMetricCounter function#6253

Merged
graytaylor0 merged 1 commit into
opensearch-project:mainfrom
vecheka:fix/fix-metric-name-typo
Nov 8, 2025
Merged

Address typo and improve publishErrorTypeMetricCounter function#6253
graytaylor0 merged 1 commit into
opensearch-project:mainfrom
vecheka:fix/fix-metric-name-typo

Conversation

@vecheka

@vecheka vecheka commented Nov 7, 2025

Copy link
Copy Markdown
Contributor

Description

Address typo and improve publishErrorTypeMetricCounter function.

  • Typo in REQEUEST_ERRORS -> REQUEST_ERRORS
  • Update publishErrorTypeMetricCounter to take exception directly and determine if metric should be emitted or not. Saves us one catch block in RestClient class.

Testing

./gradlew :data-prepper-plugins:saas-source-plugins:microsoft-office365-source:test \
--tests "org.opensearch.dataprepper.plugins.source.microsoft_office365.Office365CrawlerClientTest"

./gradlew :data-prepper-plugins:saas-source-plugins:microsoft-office365-source:test \
--tests "org.opensearch.dataprepper.plugins.source.microsoft_office365.Office365RestClientTest"

./gradlew :data-prepper-plugins:saas-source-plugins:microsoft-office365-source:checkstyleTest  

Issues Resolved

N/A

Check List

  • New functionality includes testing.
  • New functionality has a documentation issue. Please link to it in this PR.
    • New functionality has javadoc added
  • Commits are signed with a real name per the DCO

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

Signed-off-by: Vecheka Chhourn <vecheka@amazon.com>
@vecheka vecheka force-pushed the fix/fix-metric-name-typo branch from ad645cf to de3fa92 Compare November 7, 2025 23:05
@graytaylor0 graytaylor0 merged commit 68d99dd into opensearch-project:main Nov 8, 2025
48 of 54 checks passed
zeligsonbrett pushed a commit to zeligsonbrett/data-prepper that referenced this pull request Nov 10, 2025
zeligsonbrett pushed a commit to zeligsonbrett/data-prepper that referenced this pull request Nov 10, 2025
zeligsonbrett pushed a commit to zeligsonbrett/data-prepper that referenced this pull request Nov 10, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants