Skip to content

SPARK-4567. Make SparkJobInfo and SparkStageInfo serializable #3426

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 1 commit into from

Conversation

sryza
Copy link
Contributor

@sryza sryza commented Nov 24, 2014

No description provided.

@SparkQA
Copy link

SparkQA commented Nov 24, 2014

Test build #23779 has started for PR 3426 at commit cb4b8d2.

  • This patch merges cleanly.

@SparkQA
Copy link

SparkQA commented Nov 24, 2014

Test build #23779 has finished for PR 3426 at commit cb4b8d2.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@AmplabJenkins
Copy link

Test PASSed.
Refer to this link for build results (access rights to CI server needed):
https://amplab.cs.berkeley.edu/jenkins//job/SparkPullRequestBuilder/23779/
Test PASSed.

@pwendell
Copy link
Contributor

pwendell commented Dec 8, 2014

LGTM

@JoshRosen
Copy link
Contributor

LGTM, too. I'm going to merge this into master and branch-1.2, since I can't imagine how this could cause 1.2.0 RC regressions and it might as well make it into 1.2.0 so that Hive on Spark can use this.

asfgit pushed a commit that referenced this pull request Dec 10, 2014
Author: Sandy Ryza <[email protected]>

Closes #3426 from sryza/sandy-spark-4567 and squashes the following commits:

cb4b8d2 [Sandy Ryza] SPARK-4567. Make SparkJobInfo and SparkStageInfo serializable

(cherry picked from commit 5e4c06f)
Signed-off-by: Josh Rosen <[email protected]>
@asfgit asfgit closed this in 5e4c06f Dec 10, 2014
@tigerquoll
Copy link
Contributor

Heh @JoshRosen @sryza , should this patch include a serialVersionUID attribute on the classes to be serialized to make sure compiler quirks don't cause different UIDs to be generated for the classes?

@JoshRosen
Copy link
Contributor

Aren't default serialVersionUIDs generated in a consistent way across all JVMs because the algorithm for generating them is part of the Java spec?

@JoshRosen
Copy link
Contributor

Err, across all compilers?

@tigerquoll
Copy link
Contributor

http://stackoverflow.com/questions/285793/what-is-a-serialversionuid-and-why-should-i-use-it seems to be a good summary of the pros and cons of this approach

@srowen
Copy link
Member

srowen commented Dec 27, 2014

The mapping from class structure to serialVersionUID is well defined. The mapping from source to class structure may not be 100% since the compiler can stick in synthetics and such.

That said adding serialVersionUID is the less conservative default. The failure mode of forgetting to detect and update serialized form changes is potentially silent corruption of data. The failure mode of not adding it is getting exceptions about incompatible changes when the two versions could be made compatible.

I advise doing this only if really necessary because it doesn't work otherwise. It is not something to add just because .

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.

7 participants