Skip to content
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

Configurable serialization for generate POJO #186

Closed

Conversation

rahulkavale
Copy link

Add configuration to make POJO not implement serializable.
The default value for the configuration is kept to true so that existing behaviour to make POJO serializable continues to behave as expected.

rahulkavale and others added 2 commits October 5, 2017 14:49
With POJOs being serilizable and having a serialVerionId field,
everytime code generation happens - while developing and iterating
on the spec, the diff include the unchanged files due to the serialVerionID change.
Hence the config.
@stojsavljevic
Copy link
Contributor

Hi @rahulkavale and thanks for the PR.

Can you just explain what kind of issues you had with POJOs that implement serializable interface?

@rahulkavale
Copy link
Author

@stojsavljevic One of the major issues was since the POJOs are marked as the serializable and have a serialVersionID field, every time code is generated, it produces a very large changeset as every POJO now has a new value for serialVersionID field. This is causing noise in the corresponding commit for the generated code. Hence the change.

@stojsavljevic
Copy link
Contributor

Generated code should not be version controlled.

In the future, can you please create an issue first.
So we discuss the issue and once we have a clear way forward you can consider working on a PR.

@rahulkavale
Copy link
Author

@stojsavljevic Cool, I had already made these changes for my usage and wanted to submit it back to community. Thanks for the feedback.

@tburny
Copy link

tburny commented Feb 7, 2019

Related #264

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