Skip to content

Spark: Use JavaSparkContext.fromSparkContext instead of constructor#2812

Merged
aokolnychyi merged 1 commit intoapache:masterfrom
aokolnychyi:java-ctx
Jul 13, 2021
Merged

Spark: Use JavaSparkContext.fromSparkContext instead of constructor#2812
aokolnychyi merged 1 commit intoapache:masterfrom
aokolnychyi:java-ctx

Conversation

@aokolnychyi
Copy link
Contributor

As @RussellSpitzer pointed out during reviews, it is better avoid calling new to construct JavaSparkContext not to mislead people as we are not actually creating a new context. Instead, we create a wrapper.

This PR updates places that were committed before that.

@aokolnychyi aokolnychyi changed the title Spark: Use JavaSparkContext.fromSparkContext instead the constructor Spark: Use JavaSparkContext.fromSparkContext instead of constructor Jul 12, 2021
@aokolnychyi
Copy link
Contributor Author

@RussellSpitzer, could you review this one?

Copy link
Member

@RussellSpitzer RussellSpitzer left a comment

Choose a reason for hiding this comment

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

Much clearer! Thanks

Copy link
Contributor

@kbendick kbendick left a comment

Choose a reason for hiding this comment

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

This greatly enhances readability. Thanks Anton.

@aokolnychyi aokolnychyi merged commit 118efb6 into apache:master Jul 13, 2021
@aokolnychyi
Copy link
Contributor Author

Thanks, @kbendick @RussellSpitzer!

minchowang pushed a commit to minchowang/iceberg that referenced this pull request Aug 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants