Skip to content

Add saveDiagnostics application property#841

Merged
kevinwallimann merged 4 commits intodevelopfrom
feature/840-diagnostics-switch
Mar 8, 2024
Merged

Add saveDiagnostics application property#841
kevinwallimann merged 4 commits intodevelopfrom
feature/840-diagnostics-switch

Conversation

@kevinwallimann
Copy link
Collaborator

@kevinwallimann kevinwallimann commented Mar 6, 2024

Closes #840

Tested locally with sparkYarnSink.saveDiagnostics set to true, false, and without setting the property at all.

New Application property

  • sparkYarnSink.saveDiagnostics. Valid values: true, false. Default value: false

case "" => None
case _ => Some(app.diagnostics)
case "" => None
case _ if !sparkConfig.saveDiagnostics => None
Copy link
Collaborator

@jozefbakus jozefbakus Mar 6, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would formulate that positively.
And "default" case left with None - always fallback to None.

val diagnostics = app.diagnostics match { case "" => None case _ if sparkConfig.saveDiagnostics => Some(app.diagnostics) case _ => None }

@sonarqubecloud
Copy link

sonarqubecloud bot commented Mar 6, 2024

Quality Gate Passed Quality Gate passed

Issues
0 New issues
0 Accepted issues

Measures
0 Security Hotspots
No data about Coverage
0.0% Duplication on New Code

See analysis details on SonarCloud

@kevinwallimann kevinwallimann merged commit f71e4af into develop Mar 8, 2024
@kevinwallimann kevinwallimann deleted the feature/840-diagnostics-switch branch March 8, 2024 12:43
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.

Add application property to switch on storage of error messages

2 participants