Skip to content

Conversation

@eunseo9311
Copy link
Contributor

Title: Replace Collectors.toList() with Stream.toList()

Summary

Modernize stream collection operations by replacing Collectors.toList() with Stream.toList() introduced in Java 16.

Changes

  • 17 files updated across multiple modules
  • Removed unused Collectors import statements where applicable
  • Retained Collectors import where joining() or toCollection() is still used

Motivation

  • Conciseness: stream.toList() is shorter and more readable
  • Performance: Avoids creating an intermediate Collector object
  • Immutability: toList() returns an unmodifiable list
  • Modern Java: Aligns with Java 16+ idioms since the project requires Java 17

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Jan 23, 2026
@eunseo9311 eunseo9311 closed this Jan 23, 2026
@eunseo9311 eunseo9311 reopened this Jan 23, 2026
@eunseo9311 eunseo9311 force-pushed the refactor/replace-collectors-tolist branch from 095df0b to 08769cc Compare January 23, 2026 12:50
@mhalbritter
Copy link
Contributor

The build is currently failing. You can run it locally with ./mvnw verify.

@mhalbritter mhalbritter added the status: waiting-for-feedback We need additional information before we can continue label Jan 23, 2026
@eunseo9311 eunseo9311 force-pushed the refactor/replace-collectors-tolist branch from 08769cc to 6c4cb6e Compare January 27, 2026 15:57
Modernize stream collection operations by replacing Collectors.toList()
with Stream.toList() introduced in Java 16.

Changes:
- 17 files updated across multiple modules
- Removed unused Collectors import statements where applicable
- Retained Collectors import where joining() or toCollection() is used

Motivation:
- Conciseness: stream.toList() is shorter and more readable
- Performance: Avoids creating an intermediate Collector object
- Immutability: toList() returns an unmodifiable list
- Modern Java: Aligns with Java 16+ idioms since the project requires Java 17

Signed-off-by: Eunseo Song <[email protected]>
@eunseo9311 eunseo9311 force-pushed the refactor/replace-collectors-tolist branch from 6c4cb6e to 64081a3 Compare January 27, 2026 16:00
@eunseo9311
Copy link
Contributor Author

I've fixed the formatting issues and force-pushed. The build should pass now.

@spring-projects-issues spring-projects-issues added status: feedback-provided Feedback has been provided and removed status: waiting-for-feedback We need additional information before we can continue labels Jan 27, 2026
@mhalbritter mhalbritter added type: task and removed status: feedback-provided Feedback has been provided status: waiting-for-triage An issue we've not yet triaged labels Jan 28, 2026
@mhalbritter mhalbritter self-assigned this Jan 28, 2026
mhalbritter pushed a commit that referenced this pull request Jan 28, 2026
@mhalbritter
Copy link
Contributor

Thanks @eunseo9311 !

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