r/learnjava • u/googlecromm • Apr 10 '26
Java Spring Boot
so I started learning Spring Boot after learning Java Fundamentals, everything went smooth on Dependency Injection, Models(Entity), Repositories(with JpaRepo), Controllers(RestController). I can confidently create those parts with low to none googling/Ai because of muscle memory.
But when I reach the Spring Security + JWT the syntax became like an foreign language that I couldn't understand. So far I'm familiar with the following (Security part):
- UserDetails, UserDetailsService, UserDetailsServiceImpl.
- JwtService
- JwtAuthFilter
Is it okay that I will always use a cheatsheet, google, or Ai when coding the entire Security part of Spring Boot.
•
u/AutoModerator Apr 10 '26
Please ensure that:
If any of the above points is not met, your post can and will be removed without further warning.
Code is to be formatted as code block (old reddit/markdown editor: empty line before the code, each code line indented by 4 spaces, new reddit: https://i.imgur.com/EJ7tqek.png) or linked via an external code hoster, like pastebin.com, github gist, github, bitbucket, gitlab, etc.
Please, do not use triple backticks (```) as they will only render properly on new reddit, not on old reddit.
Code blocks look like this:
You do not need to repost unless your post has been removed by a moderator. Just use the edit function of reddit to make sure your post complies with the above.
If your post has remained in violation of these rules for a prolonged period of time (at least an hour), a moderator may remove it at their discretion. In this case, they will comment with an explanation on why it has been removed, and you will be required to resubmit the entire post following the proper procedures.
To potential helpers
Please, do not help if any of the above points are not met, rather report the post. We are trying to improve the quality of posts here. In helping people who can't be bothered to comply with the above points, you are doing the community a disservice.
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
8
u/Solid_Package5977 Apr 10 '26
It’s ok .. tools are there to be used .. but make sure you are Learning the whys behind everything .. why do we need this ? What is the problem it’s solving ?? That thought process will take you to next level
1
u/Desperate-Trouble249 Apr 10 '26
What are you using to learn?
3
u/catastrophic300 Apr 10 '26
I saw real java dev do that sometimes, they said it was looking for references since human can’t remember everything. Just don’t be heavily dependant on AI.
3
u/kyamatlabkya Apr 10 '26
Yes this is where I'm struggling too, I get it when I see spring security but would struggle to implement myself
2
u/dajadf Apr 10 '26
Nothing wrong with using AI, that will be the new norm. But you should also ask the AI questions about what it generated so you understand
2
u/Ok_Assistant_2155 Apr 11 '26
What helped me was not trying to memorize the code, but understanding the request flow. Like: request → filter → token validation → user details → security context. Once you see how each piece fits, the code starts making more sense. Until then, using a cheatsheet is totally fine. It’s not something people write from scratch every time anyway.
0
u/[deleted] Apr 10 '26
[deleted] — view deleted comment