Step by Step Guide - VS Code for Spring Boot Java Development

Поделиться
HTML-код
  • Опубликовано: 24 дек 2020
  • This video is a step by step guide to setup and develop Spring Boot applications using Visual Studio Code. I will be building a simple Spring Boot service from scratch using VS Code. I'll show you what extensions to install and how to use the VS Code features to develop and iterate on your Spring Boot application
    #javabrains #springboot

Комментарии • 328

  • @shubhamdubey1996
    @shubhamdubey1996 Год назад +18

    We need an updated version of this video, In two years lots of this has been improved. Please try this out in 2023.
    Like this to let Java Brains know.

  • @TheAnffer
    @TheAnffer 3 года назад +32

    1:09 "none of us remember how to compile java code using the command line" heheheh you made my day!

    • @svevo
      @svevo 3 года назад

      of course I do: "mvn clean compile" ^_^

  • @sridharshyam
    @sridharshyam 3 года назад +8

    Having worked in visual studio for so long, this makes my life easy to transfer seamlessly into Java programming with a similar setup.

  • @mdk1983
    @mdk1983 3 года назад +26

    Sir awesome. Really appreciate that you even thought of trying this out. It does make a ton of sense for full stack developers and for financially tight freelancers. Your thought process is younger and fresher than ever. Love you sir ❤️🙏

    • @Java.Brains
      @Java.Brains  3 года назад +3

      Thank you! Yes, it’s handy when working on web apps for sure!

  • @igormakarenko3170
    @igormakarenko3170 2 года назад +2

    Terrific! I follow your creative works for 8 years already. Every course or tutorial are so great explained! Your are the brilliant influencer! Thank you for your inestimable job!

  • @parthsalat
    @parthsalat 3 года назад +2

    Thanks a lot - from people who use vs code for springboot

    • @parthsalat
      @parthsalat Год назад +1

      Right now, I'm revising this to get a Job at *Thinkify Labs*

  • @heisenballs
    @heisenballs 2 года назад +1

    This is perfect, I work in Intellij but on my personal machine I wanted a lighter weight solution. There's even an extension to import intellj key binds! Beautiful. Thanks for the video man!

  • @klasp100
    @klasp100 2 года назад

    Finally a video that is not trash. No, seriously, all the other videos sound like an NPC is reading from a text file. Your video is very good and has helped me very much, thanks

  • @JannisAdmek
    @JannisAdmek 3 года назад +9

    I'll say it here, I love switching between two editors. If you work on say Java and Typescript, you need to switch syntax and for me switching editor helps me with that somehow, I am so used to seeing Java in IntelliJ and Typescript in VSCode.

  • @olaitanadesoji3719
    @olaitanadesoji3719 Год назад

    THIS WAS A BEAUTIFUL VIDEO FOR ME. As a salesforce developer , VSCode has been y GOTO place for all forms of development and i was hoping i wouldnt have to pay for intelliJ ultimate to learn Spring.
    Thank you so much for this.

  • @parthapal333
    @parthapal333 3 года назад +1

    being a javascript developer I often have to switch to eclipse for java during development. This tutorial is going to be very helpful for me. Thank you

  • @Keralite29
    @Keralite29 8 месяцев назад

    Great video. You are one of my favorite coding channels, because you explain things in a way that is both easy-to-follow and also informative. I think that using a split-screen layout, with your screen recording taking up most of the space and your live tutorial taking up the rest, is more effective at holding people's attention compared to just using a screen recording itself - it gives people a sense of face-to-face interaction which then helps them to remain focused on what is being instructed. So I think it's a very practical layout to continue using. Just my observation.

  • @ashishsadana1365
    @ashishsadana1365 3 года назад +2

    Havent you ever thought of opening a school and becoming full time teacher... I would love to join you .... you are too good...🙏🏻

    • @Java.Brains
      @Java.Brains  3 года назад +19

      In an alternative universe where teachers are paid well, and i can afford to quit my day job and still earn a decent living, perhaps!

    • @ashishsadana1365
      @ashishsadana1365 3 года назад +1

      @@Java.Brains Same here... waiting for that alternate universe to appear one day... 👍🏻👍🏻

    • @michal234486
      @michal234486 3 года назад +4

      He would be missing sharp and fresh real world experience then

    • @raghavanaliassaravananm1546
      @raghavanaliassaravananm1546 3 года назад

      @@ashishsadana1365 Same here too :)

  • @sourabhsharma6113
    @sourabhsharma6113 3 года назад +1

    This is just what I wanted. VS Code is quite flexible and powerful and I just love it. How to make the VS Code a go-to for a back-end developer. Thanks Koushik for making this great walkthrough from ground-up.

    • @TheSparfa300
      @TheSparfa300 2 года назад

      yeah my favorite thing about vs code is how modular it is

  • @Skullgnammer
    @Skullgnammer 3 года назад

    First comment at one of your videos (I wonder why because your tutorials saved me so many times I can't count them anymore). I'm a full stack dev and I use VScode for both frontend and backend. You just scratched the surface, there are so many more extensions you can use. Other AI autocomplete, autoformat on save, support for other platforms (quarkus and native builds anyone?) you name it.
    Regarding this one, there's a tab at the bottom left I didn't see you touching (or maybe you did and I missed it) "Spring boot Dashboard", it allows you to run and debug, usefoul also when you have a bunch of spring projects and you want to run them all at once. I use it when I want to debug a bundle of microservices related to each other.
    Thank you again for your awesome videos!

  • @albirtarsha5370
    @albirtarsha5370 3 года назад +24

    I don't understand how this line worked for you:
    if (responseCodeCategory != 2 || responseCodeCategory != 3)
    Shouldn't that be AND instead of OR?
    Isn't this condition always TRUE, because being 2 and 3 is mutually exclusive?

    • @Sonyemman97
      @Sonyemman97 3 года назад +2

      this error had be debugging for so long.. lol

    • @rimantasrozga577
      @rimantasrozga577 3 года назад +1

      Excellent! It wasn't working for me, but I just wasn't in the mood to think and just != reversed to == and subsequently reversed output :D

    • @benaya6
      @benaya6 3 года назад +3

      I think he did that on purpose... or just didn't want to fix during video haha...this bug took 10 minutes of my life..
      still great tutorial anyway

    • @nayansetty2926
      @nayansetty2926 3 года назад +2

      Yo man as it wasma first spring program was quite demotivated thanks mate for rectifying yu guys saved ma arshe

    • @charonme
      @charonme 2 года назад +3

      came here to say this

  • @awadijohan
    @awadijohan 2 года назад

    I want to tank you really about the excellent content about how to code for Spring Boot using VS Code and also you helped me to remember what I saw and learnt about Spring Boot so thanks again to save my time from wasting :)

  • @garymarshall7410
    @garymarshall7410 2 года назад +1

    This video is well over a year old however it still very much applies and was very helpful. Great job. Thank you for taking the time to do this.

  • @rebeckavogel6480
    @rebeckavogel6480 2 года назад

    Thank you for this Step-By_Step Video.
    Really saved me a lot of time figuring stuff out basically on my own.

  • @anonnymous6493
    @anonnymous6493 2 года назад +2

    I honestly do not understand why your if-else branching works. If the response code is 2, it is NOT 3 and if it is 3, it is NOT 2. So the code didn't work properly for me, I adjusted it accordingly.

  • @deekshithanand3094
    @deekshithanand3094 3 года назад +3

    For working on large projects, you gotta increase xmx and xms in jdt vmargs. Current configs are tuned for container environment. And regarding that auto complete replacing is a feature. You can turn it off in setting

  • @ori_geva
    @ori_geva 3 года назад +14

    22:22 pretty sure it removed String because you auto completed without spacing out the words, I think it's more of a preference thing because I can see myself using that

    • @MirekKrenc
      @MirekKrenc 3 года назад +2

      Yes, I also think so. The same behavior I faced sometimes in Idea Intellij.

    • @IvanRandomDude
      @IvanRandomDude 3 года назад +1

      True, Idea does the same thing if you don't have space.

    • @saamtech
      @saamtech 3 года назад

      True and not true, you have 2 behaviors in Intellij, you can hit "tab" or "enter". "tab" will replace the word that is attached to the word you're trying and "enter" puts the new suggested word and retains the existing word after auto complete. I bet VS code has the same (maybe opposite key mapping tho)!

  • @SmartIdiots
    @SmartIdiots 3 года назад +1

    Great Tutorials. I'm feeling the same as what I felt while learning from my college professor. Thanks a lot !!

  • @OguzSarigul
    @OguzSarigul 3 года назад +35

    You should have tested debugging feature as well...

  • @itcloudguy
    @itcloudguy Год назад

    You`re awesome! Very good and useful guide! Thank you very much for this share!

  • @TwinFeats
    @TwinFeats 2 года назад

    First of your videos I've ever watched, and I have to say it is most excellent compared to so many others from other creators I've seen. Thanks so much for doing this!

  • @bluesdog88
    @bluesdog88 3 года назад +3

    Thanks so much!! Been learning python on VS Code and i absolutely love it, now i have to learn java, thanks for running through the basics, most appreciated!

  • @genuine.identity
    @genuine.identity 3 года назад

    Thank you.
    Created my first spring boot java project..

  • @ankit_khachane
    @ankit_khachane 3 года назад

    it's really good I have been using vs code for java for the last 3 months its really a good "Free Tool" 😎😁😉

  • @sumondutta1101
    @sumondutta1101 3 года назад +3

    I have a feeling that you would do the best System Design videos.

  • @milsp3716
    @milsp3716 3 года назад

    Excuse me men! You drop something. your cr0wn bcz you are a man of god for me. I was looking for this. and could not find any related videos. thankyou so much.

  • @taolv5748
    @taolv5748 2 года назад

    Thanks for this vs code java tutorial.

  • @MadhuSudhanpro
    @MadhuSudhanpro 3 года назад +12

    Microsoft has been kicking it out of the park with softwares from last few years revamping their legacy softwares like VS CODE Visual studio use to be that huge ide which single handedly hogged all the cpu resources but now it's light and everything is an add on plug in.. Kudos to team microsoft on this!!
    But my ♥️ will always be intellij with thier amazing IDE..
    Ps there is even a intellij keybind plug in for vs code if you don't want to learn vs code shortcuts 😅

    • @Java.Brains
      @Java.Brains  3 года назад +3

      Good call on the key binding! Yes, VS Code is a completely different app from Visual Studio, and is both light and capable at the same time. They’ve really nailed the experience overall

    • @ikazuchi-san5772
      @ikazuchi-san5772 2 года назад

      there is
      the extension name is IntelliJ IDEA Keybindings
      by Keisuke Kato

  • @BMontellano
    @BMontellano 2 года назад

    Bravo, Bravo! Absolutely wonderful tutorial. Thank you!

  • @be184
    @be184 3 года назад +3

    Hii, I watched your videos 3 years ago when I just started programming thanks for all the help and I use Vs code for Spring development and it works fine .
    Give a like to the coolest java teacher ever :)

  • @OmkarShetkar
    @OmkarShetkar 3 года назад +2

    Thanks for nice tutorial Koushik... Recently I spent some time exploring VSCode for Spring project development. In most cases, it seems to meet expectations except for few cases where tedious workarounds are involved. Such as finding the implemenations of an interface, integration with Sonar server, formatting the code etc. Seems these will get improved eventually. From Intellij CE side, I noticed a plugin "Spring Assistant" to generate spring project from IDE itself.

  • @joincoder
    @joincoder 2 года назад

    You are awesome programmer face so funny , when I watching your video , thank you for you sharing

  • @Abhikalsi
    @Abhikalsi 3 года назад

    I was a bit skeptical to use VS Code for Spring Boot App development. But after watching your video I can at least give it a try with all these extensions/plugins. Thank you and Merry Christmas!!

  • @yurireis3875
    @yurireis3875 3 года назад

    Thanks for your video! I was looking for this for a long long time, I'm coming from C# using VS and now I'll need to work with Java, so in my point of view and with your video overview I think it's possible to stay using C# for all my stack.

  • @guidoglielmi7992
    @guidoglielmi7992 2 года назад +3

    At 22:55 "String" is removed because it was concatenated with the Annotation. Just adding a whitespace in between should do fine. And in 33:20 the way to add something to the same package is doing the same procedure but right-clicking on the io.javabrains.isthesiteup folder, not on src/main/java

  • @KennetP
    @KennetP 3 года назад

    Great video and explanations! I've used everything except VSCode for Java and I must say I'm excited to reboot my old NetBeans/Swing apps with Spring Boot :D

  • @nayansetty2926
    @nayansetty2926 3 года назад +2

    i suppose it shdve been this one if (responseCodeCategory ==2 && responseCodeCategory == 3) anywayz thanks man was searching the shit about this found ur vid reallly useful

  • @PhongLe-yf3wp
    @PhongLe-yf3wp 2 года назад

    Thanks so much for the helpful practical instruction!

  • @harishkumarforever515
    @harishkumarforever515 3 года назад

    bro, love you, i learned JavaScript and angular and angular js from you , love from India

  • @gvatimyboy
    @gvatimyboy 2 года назад

    Great video! Thank you. Looking forward to code Java in VSCode :)

  • @gamingbycobraboy1007
    @gamingbycobraboy1007 3 года назад +2

    The JAVA PROJECTS tab sometimes just doesn't load, the loading progress bar just keeps on loading. Did anybody face this issue?

  • @vernon_4411
    @vernon_4411 Год назад

    Thanks for the video. I am also surprised by how well VS code works for Java/Spring development. I do have a critical issue with VS Code though. It demands a lot of resources, both CPU and memory. It locks up my PC a few times due to a lack of hardware resources on my Linux PC. Based on my experience, it requires at least 16 GB RAM to run smoothly.

  • @ori_geva
    @ori_geva 3 года назад +2

    What a mind reader, I've been working on getting to know and get used to vscode for spring boot, for the same reason where intellij is not free and eclipse feeling a bit dated

    • @ori_geva
      @ori_geva 3 года назад

      @@rarecase3666 Now where did you take that fact from? Could it be as dated as Eclipse is? Lmao I'm kidding but honestly I think VSCode is a game changer

  • @gtrent7744
    @gtrent7744 Год назад +1

    Hi. I have a Maven Spring Boot application which takes profile parameters and spring boot arguments to run. For the life of me I cannot debug in VsCode. This is a set of topics you did not included here so I think it would be helpful to cover this more complex setup. Also, I think debugging is the most important feature of an IDE so you really should cover that. Thanks.

  • @aravindp3971
    @aravindp3971 3 года назад

    resourceful Video. Will like to enjoy videos like this....Great Work....Thank you!!!

  • @subhajitbarh8435
    @subhajitbarh8435 3 года назад +5

    Hi Koushik, nice video. I always found vs-code lighter than IntelliJ(including vs-code extensions). About that removing String keyword thing, I think you needed to put a space before String so that vs-code won't remove it. Otherwise, vs-code thinks you are trying to correct the String keyword instead of adding another keyword.

    • @Java.Brains
      @Java.Brains  3 года назад +4

      Yup, that makes sense! I guess I wouldn’t be surprised if other editors /IDEs did something similar

  • @shadsluiter
    @shadsluiter 2 года назад

    I got here after running into problems with Thymeleaf plugins in Spring Boot Suite 4.8 +. VS Code actually works better with Thymeleaf editing.

  • @jmanuelbello
    @jmanuelbello 3 года назад

    Thanks a lot for share it, I tried with vscodium but additional configurations are needed, I'm currently use eclipse but after this video I'll give a try to vscode.
    Your videos are great!!!

  • @zo2600
    @zo2600 3 года назад

    VS code has been pretty awesome for me. I only started learning java this year and it's the one IDE I found both easy to use and download. Still getting a hang of the extensions though

  • @raghavanaliassaravananm1546
    @raghavanaliassaravananm1546 3 года назад

    You are amazing as always dear Kaushik :) You rock. Have a great, prosperous and beautiful 2021 :)

  • @amitsharma-alwar
    @amitsharma-alwar 3 года назад +3

    Sir please give one series on reactive programming in java. Love the way you teach.

  • @Kchandrashekaran
    @Kchandrashekaran 3 года назад

    I was already using, but I wasn't using it right. I did not have the right plugins lol. Thanks for great tutorial.
    It would be great if you can add a follow up video for this - "how to use maven in VS code"

  • @mrinalpramanick3053
    @mrinalpramanick3053 2 года назад

    Thank You sir, Appreciate your Work

  • @abhishekpardhan4521
    @abhishekpardhan4521 2 месяца назад

    Thank You sir , well detailed video

  • @WalcirAugustoWehrle
    @WalcirAugustoWehrle 2 года назад

    Great video, thanks!

  • @gokhun
    @gokhun 3 года назад

    I have been developing Spring Boot and Quarkus applications in Code Server (It is basically VS Code in browser) over a year. I found myself more productive compared to Eclipse. Also I run my Code Server in a more powerful server than my laptop so no fan noise.

  • @chethan93
    @chethan93 3 года назад +3

    Hey Koushik, I am really confused as to how this code worked for you...
    (responseCodeCategory != 2 || responseCodeCategory != 3) condition shouldn't work for SITE_IS_DOWN case. It should be set for SITE_IS_UP case. I did this code myself. I am not getting how it is working correctly in your video!!!!!!

  • @timstatler3214
    @timstatler3214 2 года назад

    This is such a good tutorial, thank you.

  • @ronheiney
    @ronheiney 2 года назад

    Thanks this video was great!

  • @TARUN871
    @TARUN871 3 года назад

    I use vc code to view files in formatted way on my mac but didn't realize it has java features as well using extension. I will try to use it for a week to see how do i adapt to it. Thanks for your video

  • @whatthehell3704
    @whatthehell3704 2 года назад

    Java code generators plugin will allow to generate code snippets like constructors setters getters tostring etc

  • @Papa-Dima77
    @Papa-Dima77 2 года назад

    Love this video, I'm VS code user for python and C# projects, so this is very helpful to learn that Javal/Spring also works like a charm, thanks so much for this video!

  • @rehansattar8990
    @rehansattar8990 3 года назад

    A really nice explanation! Thank you so much for the good content. 🙌

  • @talderson1
    @talderson1 2 года назад

    This is saaah-weet! Thanks for making me think this was possible. I'm about to try JakartaEE and I'm going to see if it works in vscode. Maybe, maybe not, but I didn't think spring boot would work this well either.

  • @mpumzskillz
    @mpumzskillz 2 года назад

    Very helpful, thank you.

  • @gameofnoobgon7199
    @gameofnoobgon7199 3 года назад +1

    its been almost more than 2 years im using vs code for java

  • @prateekmohanty4643
    @prateekmohanty4643 2 года назад

    Very informative video, huge thumbs up!!

  • @divyanshusingh6473
    @divyanshusingh6473 2 года назад

    It also has pretty nifty gui git conflict resolver. Better than what most offer.

  • @natnaelmulat9
    @natnaelmulat9 3 года назад

    Great work! Thank you for this.

  • @Raj-gd5zd
    @Raj-gd5zd 3 года назад

    Really helpful. I was thinking to buy the Intellij. Now changed my mind ;) Thank you!

  • @kalamani9175
    @kalamani9175 3 года назад

    Great video. At last started working on Java. I have to install javacodingpack also to make it work

  • @VincentBMathew
    @VincentBMathew 2 года назад

    Awesome content. Please keep making VS Code Java related videos

  • @sambit8011
    @sambit8011 3 года назад +20

    Second coz everyone is 1st

    • @Java.Brains
      @Java.Brains  3 года назад +10

      Funnily enough, you're actually first :)

  • @andremyszko
    @andremyszko 3 года назад

    thanks, i was using Eclipse, but... vscode looks so much better, i will try it!

  • @barbarossa11
    @barbarossa11 3 года назад +1

    The dragon drop actually works, but not under the "JAVA PROJECTS" representation. Switch to "IS-THE-SITE-UP" and you can move the files around as you want.

  • @amrhossam8058
    @amrhossam8058 2 года назад

    this is great bro, thank you

  • @chinoleung6467
    @chinoleung6467 Год назад +2

    Isn't line 27 should be responseCodeCategory !=2 && responseCodeCategory !=3 ?

  • @lokresainathrao8995
    @lokresainathrao8995 Год назад

    Really helpful tutorial. I think in #27 logical operator should be "&&" (AND) insted of "||" (OR)

  • @AgustinSosa15
    @AgustinSosa15 Год назад

    excellent video thank you very much! like and new subscriber

  • @vishnusuresh2650
    @vishnusuresh2650 3 года назад

    Using VSCode with flutter, javascript, typescript, java, python, Platformio.... It is a great text editor ...

  • @PradeepKumar-sx6ms
    @PradeepKumar-sx6ms 2 года назад

    I saw this video before it works, please show how to run multiple spring boot application simultaneously

  • @kamaleldindaar3890
    @kamaleldindaar3890 3 года назад

    Thanks Java Brains you are the Man

  • @luisluiscunha
    @luisluiscunha 3 года назад

    Thank you for being such a valuable content provider. Well done! After writing this, I went for the like button, and saw I am subscribed. Which is good! Let me use the chance to tell you that the way you say the truth you say at 12:32 made me LOL :D.

  • @rahul.jaswal
    @rahul.jaswal 3 года назад +1

    I have a worst experience with vsCode when it comes to java projects.
    I used it for my spring boot project and it worked perfectly fine initially, i mean test cases were running smoothly and had no problem with debug mode or setting up dependencies. In fact I loved full screen view and fonts.
    But after 2-3 days man-o-man intelliSense stopped working, no matter how hard I try it wil stop on loading and when I checked my cpu usage it was skyrocketed (a process from Java extension pack was culprit). I tried with same setup again but same problem.
    Soon I moved to intelliJ. 😅

  • @touchme7743
    @touchme7743 3 года назад +1

    Hi, thanks for the video. I am trying to run the same project only using groovy and when running it gives the error "Failed to run this project 'demo' because it does not contain any main class.". You don't know how to fix it?

  • @saurovk2008
    @saurovk2008 3 года назад +1

    This is good. Are you sure about ORing
    (responseCodeCategory != 2 || responseCodeCategory != 3)

  • @kashinathpatekar9870
    @kashinathpatekar9870 2 года назад

    An extension recommendation if you want the code quality suggestions: SonarLint. It even does the replacement of code for you, just like IntelliJ would

  • @vijayvarotariya3556
    @vijayvarotariya3556 2 года назад

    thank you so much...very helpfull

  • @Metruzanca
    @Metruzanca 3 года назад

    The command palette can also be opened with F1. Really good video.

  • @VinayKumarcs127
    @VinayKumarcs127 3 года назад

    Nice | Simple | Clear.
    Thank you sir 😃

  • @RaffaCaboFrio
    @RaffaCaboFrio 2 года назад

    Great video. Thanks.

  • @pramodjingade6581
    @pramodjingade6581 3 года назад

    Super. Really liked the practical approach. Could you also do a separate video on Testing feature (JUnit..etc.,) ?

  • @sanjeevpro
    @sanjeevpro 3 года назад

    Very nice presentation. Thanks for your time.

  • @rakeshrockb
    @rakeshrockb 3 года назад +8

    Great tutorial, thank you.
    I see "Site is down" all the time and this is due to line # 29. if (responseCode !=2 || responseCode!=3) always evaluates to true even when responseCode is 2.

    • @brolaf8515
      @brolaf8515 2 года назад +2

      If you change the if statement to && instad of || it will work, also changeing the statements from != to == will work but this will require flipping the up and down statements as well.

    • @upulieh
      @upulieh 2 года назад

      Yes!

    • @JackMayHoff12
      @JackMayHoff12 Год назад

      How the heck did it work for him?? I was getting same error changed to ==

  • @hussainbim
    @hussainbim Год назад

    Hi Koushik - wonderful effort. I was about to explore VS Code and I happened to see this. Will use it for a while. So far so good.
    Can I ask an unrelated question. What is your view on JHipster especially - JHipsterLight. Please share feedback if any. Thank you.