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

Add default methods in interfaces #3924

Closed
fmbenhassine opened this issue May 31, 2021 · 2 comments
Closed

Add default methods in interfaces #3924

fmbenhassine opened this issue May 31, 2021 · 2 comments

Comments

@fmbenhassine
Copy link
Contributor

Several core interfaces could benefit from using Java 8's default methods in interfaces feature. This has a couple of advantages:

  • It makes client code more readable as it does not require it to implement all methods of a given interface.
  • It reduces the code on the framework side since support classes (like JobExecutionListenerSupport, StepExecutionListenerSupport, ChunkListenerSupport, etc) become obsolete in favour of default methods.

This feature is similar to what has been done in other projects (Here is an example from Spring Framework) and the goal is to make sure the Spring (Batch) developer has a consistent experience across the portfolio.

@parikshitdutta
Copy link
Contributor

Hi @benas, I am on it, Please assign this one and it's dependent #3925 to me.

Thank you.

@parikshitdutta
Copy link
Contributor

Hi @benas, please review PR #3934. I will look forward to your feedback.

Thank you.

@fmbenhassine fmbenhassine modified the milestones: 5.0.0, 5.0.0-M1 Sep 10, 2021
fmbenhassine added a commit that referenced this issue Sep 10, 2021
* Add default methods in all listener interfaces
* Remove usage of newly deprecated support classes

Issue #3924
fmbenhassine added a commit that referenced this issue May 9, 2022
Default values are consistent with AbstractJob
and AbstractStep.

Issue #3924
fmbenhassine added a commit to fmbenhassine/spring-batch that referenced this issue May 9, 2022
Default values are consistent with AbstractJob
and AbstractStep.

Issue spring-projects#3924
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants