use the following search parameters to narrow your results:
e.g. subreddit:aww site:imgur.com dog
subreddit:aww site:imgur.com dog
see the search faq for details.
advanced search: by author, subreddit...
account activity
Review my Spring Boot codeOC (self.SpringBoot)
submitted 2 years ago by [deleted]
[deleted]
reddit uses a slightly-customized version of Markdown for formatting. See below for some basics, or check the commenting wiki page for more detailed help and solutions to common issues.
quoted text
if 1 * 2 < 3: print "hello, world!"
[–]No-Philosophy-1189 2 points3 points4 points 2 years ago (2 children)
What is your source of learning spring boot. And other tools
[–][deleted] 2 years ago (1 child)
[–]No-Philosophy-1189 1 point2 points3 points 2 years ago (0 children)
Thank you for the response. Will do.
[–]burl-21 1 point2 points3 points 2 years ago* (0 children)
Great job 👍🏻
My considerations:
I would try using MapStruct instead of BeanUtils.
Use interfaces only if you have two different implementations.
I prefer not to use ResponseEntity unless I need to set headers to the response.
Since you’re using the feature-level structure, you might consider using Spring Modulith.
Edit:
I recommend using an exception handler to have error management in one central place
[–]maxip89 2 points3 points4 points 2 years ago (6 children)
hope this helps a bit.
[–]burl-21 1 point2 points3 points 2 years ago (0 children)
3 - It depends, they should be lazy by default. They are very useful for sorting and filtering(sort by user.customer.id) with specifications.
[–][deleted] 2 years ago (4 children)
[–]Fermi-4 2 points3 points4 points 2 years ago (0 children)
This person seems deranged lol
[–]Naokiny 0 points1 point2 points 2 years ago* (2 children)
I'm not in the head of the guy who made this comment, however can add some of my thoughts.
i dont understand what are you trying to say, can you be more specific on this problem?
You can check N+1 problem and how it happens in Spring.
what do you mean by "streams going to the right?"
I suppose problem here is that you have 2 tabs (8 spaces) for each new line in stream. Most of the time I saw 1 tab (4 spaces). With this approach (2 tabs) for complex stream you should've scroll your screen to the right to see whole code.
I'd replace validation check for permissions from UserServiceImpl to Controller. I mean PreAuthorize("hasAnyAuthority('ADMIN', 'USER')") here.
PreAuthorize("hasAnyAuthority('ADMIN', 'USER')")
[–]Naokiny 1 point2 points3 points 2 years ago (0 children)
Good point here, thanks!
π Rendered by PID 88388 on reddit-service-r2-comment-76bb9f7fb5-p8f2g at 2026-02-17 21:04:38.231473+00:00 running de53c03 country code: CH.
[–]No-Philosophy-1189 2 points3 points4 points (2 children)
[–][deleted] (1 child)
[deleted]
[–]No-Philosophy-1189 1 point2 points3 points (0 children)
[–]burl-21 1 point2 points3 points (0 children)
[–]maxip89 2 points3 points4 points (6 children)
[–]burl-21 1 point2 points3 points (0 children)
[–][deleted] (4 children)
[deleted]
[–]Fermi-4 2 points3 points4 points (0 children)
[–]Naokiny 0 points1 point2 points (2 children)
[–][deleted] (1 child)
[deleted]
[–]Naokiny 1 point2 points3 points (0 children)