Annotations in Spring boot with Explanation| Spring boot Interview Questions and Answers Code Decode

Поділитися
Вставка
  • Опубліковано 10 тра 2022
  • In this video of code decode we have explained about Annotations in Spring boot. Annotations in spring boot is very important Interview in Spring boot interview questions and answers.
    Udemy Course of Code Decode on Microservice k8s AWS CICD link:
    openinapp.co/udemycourse
    Course Description Video :
    yt.openinapp.co/dmjvd
    Spring boot annotations
    Spring Boot is the most popular Java framework. Spring Boot built upon spring framework. It minimize the amount of configuration and boilerplate code you need to get started.
    The Java provided support for Annotations from Java 5.0.
    Prior to that, the behavior of the Spring Framework was largely controlled through XML configuration. Today, the use of annotations provide us tremendous capabilities in how we configure the Spring Framework.
    Spring Annotations are a form of metadata. Annotations are used to provide supplemental information about a program. It does not have a direct effect on the operation of the code they annotate. It does not change the action of the compiled program.
    @SpringBootApplication
    It is a combination of three annotations
    @EnableAutoConfiguration,
    @ComponentScan, and
    @Configuration.
    if you see at their parent packages:
    org.springframework.boot.autoconfigure.EnableAutoConfiguration
    org.springframework.context.annotation.Configuration
    org.springframework.context.annotation.ComponentScan
    So we can say this Spring boot annotations can’t exist on its own. It needs spring framework annotations to work.
    Annotations on annotations-@Target
    @Target tag is used to specify at which type, the annotation is used.
    The java.lang.annotation.ElementType enum declares many constants to specify the type of element where annotation is to be applied such as TYPE, METHOD, FIELD etc. Let's see the constants of ElementType enum:
    Element Types Where the annotation can be applied
    TYPE class, interface or enumeration
    FIELD fields
    METHOD methods
    CONSTRUCTOR constructors
    LOCAL_VARIABLE local variables
    ANNOTATION_TYPE annotation type
    PARAMETER parameter
    Annotations on annotations-@Retention
    @Retention annotation is used to specify to what level annotation will be available.
    RetentionPolicy.SOURCE - refers to the source code, discarded during compilation. It will not be available in the compiled class.
    RetentionPolicy.CLASS refers to the .class file, available to java compiler but not to JVM . It is included in the class file.
    RetentionPolicy.RUNTIME refers to the runtime, available to java compiler and JVM .
    Annotations on annotations-@Inherited @Documented
    By default, annotations are not inherited to subclasses. The @Inherited annotation marks the annotation to be inherited to subclasses.
    The @Documented Marks the annotation for inclusion in the documentation.
    @Configuration
    Tags the class as a source of bean definitions for the application context.
    Point to note-
    The main application class is also a bean, as it's annotated with @Configuration, which is a @Component.
    @EnableAutoConfiguration
    The @EnableAutoConfiguration annotation enables Spring Boot to auto-configure the application context. Therefore, it automatically creates and registers beans based on both the included jar files in the classpath and the beans defined by us, implicitly @EnableAutoConfiguration annotation, which makes Spring Boot create many beans automatically, relying on the dependencies in pom.xml file.
    For example, when we define the spring-boot-starter-web dependency in our classpath, Spring boot auto-configures Tomcat and Spring MVC.
    If you have added tomcat-embedded.jar then it tries to intellectually configure TomcatServletWebServerFactory if you do not have specified explicitly as ServletWebServerFactory bean. Hence, this auto-configuration has less precedence in case we define our own configurations.
    Most Asked Core Java Interview Questions and Answers : • Core Java frequently a...
    Advance Java Interview Questions and Answers : • Advance Java Interview...
    Java 8 Interview Questions and Answers : • Java 8 Interview Quest...
    Hibernate Interview Questions and Answers : • Hibernate Interview Qu...
    Spring Boot Interview Questions and Answers : • Advance Java Interview...
    Angular Playlist : • Angular Course Introdu...
    SQL Playlist : • SQL Interview Question...
    GIT : • GIT
    Subscriber and Follow Code Decode
    Subscriber Code Decode : ua-cam.com/users/CodeDecode?...
    LinkedIn : / codedecodeyoutube
    Instagram : / codedecode25
    #codedecode #Springbootannotations #springbootinterviewquestionsandanswers

КОМЕНТАРІ • 132

  • @CodeDecode
    @CodeDecode  2 роки тому +32

    Hey Guys, In this video we have covered very important and very in-depth concepts of spring boot annotations. So please watch this video till very end as it will indirectly cover many interview questions of Spring boot annotations. Also please like share and subscribe and let us know in the comment sections if you want us to create second part of Spring boot annotations

    • @purushotham8546
      @purushotham8546 2 роки тому

      Thank you for all your efforts, your videos really helped me to gain confidence before going to the interview. Please create a continuation video for this video as well.

    • @sukunkusum1720
      @sukunkusum1720 Рік тому

      Thanks for ur efforts its really informative. please do such videos more. and please cover how to convert existed project to spring boot application. Thankful for what you are doing.

    • @bhavikjoshi1561
      @bhavikjoshi1561 Рік тому

      please create second part for this. thank you

    • @shwetaskatta8464
      @shwetaskatta8464 Рік тому

      Hi @codeDecode
      Can please make one video on full spring boot interview question with live example for experience people. As I saw you made video on annotation only.so try to make video on other parts also.
      Please make soon🙏🏻

    • @malleswarrao3887
      @malleswarrao3887 Рік тому

      Hi can you give me the video URL for spring cloud config server example

  • @tejasraje2672
    @tejasraje2672 2 роки тому +62

    I cracked 2 interviews within a week after watching your entire interview series. You're a savior for Java Developer Interviews. Thanks a lot and i urgue you to make more such video's on advanced java and spring boot concepts

    • @CodeDecode
      @CodeDecode  2 роки тому +7

      Many congratulations Tejas. Very well deserved 👏👏👏👏keep learning keep growing Man 🙂🙂👍👍

    • @tejasraje2672
      @tejasraje2672 Рік тому

      Hi@@poorvakatyal2477 . I've 1.5 years in java springboot

    • @santhoshPatels
      @santhoshPatels Рік тому

      @@tejasraje2672 which company teja

    • @rushikeshgodase8498
      @rushikeshgodase8498 Рік тому

      Could you please tell me which interview series you are talking about, there multiple series available on this channel?

    • @saphalvecham5539
      @saphalvecham5539 Рік тому

      @@rushikeshgodase8498 ua-cam.com/video/PwiuAebCruY/v-deo.html

  • @rajeevsai91
    @rajeevsai91 2 роки тому +6

    Thank you very much for this video. I have been seeing these basic annotations from sometime now, but never understood what each thing does. I got more clarity now. Please continue with this series. Thank you for helping all the confused developers like me.

    • @CodeDecode
      @CodeDecode  2 роки тому +2

      Been though the same situation. Hence decided to create a video to clarify many developers like us 🙂🙂. Thanks for supporting us and motivating us . Means a lot Rajeev 🙂👍

    • @rajeevsai91
      @rajeevsai91 2 роки тому

      @@CodeDecode thank you for your reply and assurance. 🙏🏻

  • @re5gow2
    @re5gow2 26 днів тому +1

    Thank you! This is very helpful. I learned so much more about spring boot with this video and this is just one spring boot annotation.

  • @sproutboot
    @sproutboot Рік тому +2

    Definitely I want you to cover more-! I love your explanation. Always your explanation is very clear. easy to understand. I like when you show us related demo

  • @MehulSamaiya
    @MehulSamaiya Рік тому +3

    To be very honest for annotations i searched for so many videos but was unable to understand it clearly and after going through your video its now crystal clear. Thanks a lot, u r doing a good work keep it up....toodles.

  • @ashwinvarma9349
    @ashwinvarma9349 Рік тому +2

    Really a big fan of the way you teach! Thanks a lot!

  • @hariomkumar163
    @hariomkumar163 2 роки тому +5

    Thanks mam! You are life saver with so many interview questions 🙌

    • @CodeDecode
      @CodeDecode  2 роки тому

      Thanks a lot Hariom. We are glad to be. We will keep posting such videos 🙂👍

  • @monikashukla5072
    @monikashukla5072 2 роки тому +3

    Yes please cover the rest of the questions, it will help!

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      Sure thanks Monika for showing us the way to proceed with. 🙂👍

  • @amanbagdi3425
    @amanbagdi3425 2 роки тому +6

    The internal working of annotations is explained very well, please continue on it and cover the other annotations as well like
    @Autowired n all. Thanks 😊.

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      Thanks a lot Aman. Sure we will do that🙂👍

  • @sachinvm1319
    @sachinvm1319 Рік тому +2

    One of the best video I have seen explaining how the spring boot application works internally with all these annotations. Please request u to cover the rest of the annotations, that would really help your subscribers. Thanks again

  • @dgcrush2000
    @dgcrush2000 2 роки тому +2

    Thanks a lot, it's a great help for learners, please continue with remaining annotations

    • @CodeDecode
      @CodeDecode  2 роки тому

      Thanks chandr. 🙂👍. Sure we will continue this series

  • @jonasjanaitis436
    @jonasjanaitis436 Рік тому +2

    I don't know, but for me, these lessons are pure gold.

  • @uddeshyajaiswal8574
    @uddeshyajaiswal8574 2 роки тому +1

    Thanks for this knowledgeful video. please continue more of this...

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      Thanks Uddeshya. Sure we will do that 🙂👍

  • @praveenpippala1383
    @praveenpippala1383 2 роки тому +1

    very useful content waiting for next video

    • @CodeDecode
      @CodeDecode  2 роки тому

      Thanks a lot praveen 🙂👍

  • @yatendrasingh6847
    @yatendrasingh6847 2 роки тому +1

    wonderful explaination , i got from your interview series pls make more videos on the subsequent topics, Today i found your channel and got subscribed in half of the video ,best content on you tube to the point with great depth of the topic.thanks

    • @CodeDecode
      @CodeDecode  2 роки тому

      Thanks a lot Yatendra 🙂means a lot to us👍🙂

  • @ravikanthgande8860
    @ravikanthgande8860 2 роки тому +1

    Awesome one, really appreciate your efforts

    • @CodeDecode
      @CodeDecode  2 роки тому

      Thanks a lot Ravi 🙂👍

  • @ah4303
    @ah4303 2 роки тому +1

    Thanks for your efforts. Please do continue this spring boot annotations series.

    • @CodeDecode
      @CodeDecode  2 роки тому

      Sure. Thanks a lot for helping us decide the priority. Means a lot, 🙂👍

  • @harshadaraut4096
    @harshadaraut4096 2 роки тому +1

    Thanks for this video ...please continue on this

  • @Vithal_Nivargi
    @Vithal_Nivargi 2 роки тому +2

    Thank you mam , which i was waiting for such videos.... 😊

  • @rachamallidorasrivignesh4499
    @rachamallidorasrivignesh4499 2 роки тому +1

    Superb explanation madam tq so much the way of explaining is easy to understand ur all vedeos are so helpful .

  • @ArjunSingh-is1bg
    @ArjunSingh-is1bg 2 роки тому +1

    This Video is really helpful, Currently i am working on spring i have one have diffculty is , I have to thought much more about the configuration in the Spring and then Spring Boot comes and make alll the automation and reduce the boiler plate code and make life of the Java Developer Easy.

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      So glad to hear that u are able to feel it on job. Apply and learn as much as you can Arjun. We can see you are perfectly on the right track. You will for sure land at your dream job with such worthy knowledge you are gaining day by day 🙂👍 keep learning keep growing Man. Glad to see this 👏👏👏👏

    • @ArjunSingh-is1bg
      @ArjunSingh-is1bg 2 роки тому

      @@CodeDecode Tq Mam, You Also So supportive in my journey of the Java Developer.🙂🙏

  • @bhuvanakuppusamy6933
    @bhuvanakuppusamy6933 2 роки тому +1

    Excellent ma.. detaily explained . Really appreciate it. . Pls do cover all other topics. . . . Thanks for your videos. .

    • @CodeDecode
      @CodeDecode  2 роки тому +2

      Thanks a lot Bhuvana 🙏🙏. Sure we will cover more annotations in next videos

  • @rocker31590
    @rocker31590 2 роки тому +1

    Great work. Thanks!

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      Thanks a lot Prabakar 🙂👍

  • @milanfaizal
    @milanfaizal Рік тому +2

    This is amazing. So deep

  • @rocker31590
    @rocker31590 2 роки тому +1

    Yes please post videos for the other upcoming topics as well

  • @arshpreetsingh2417
    @arshpreetsingh2417 2 роки тому +3

    most useful channel for interview preparations, cleared the interview of a very good product based company with the help of your videos. Thanks a lot mam for providing such useful content🙏🙏 Keep creating such useful videos👍

    • @CodeDecode
      @CodeDecode  2 роки тому

      Thanks for the nice words arshpreet

  • @shail1396
    @shail1396 2 роки тому

    Thanks for your efforts. Please do continue this series.
    Can u please share this document that can be really helpful for us.

  • @khushboobhalawat7196
    @khushboobhalawat7196 2 роки тому +1

    Please do create. Your videos are quite helpful. You elaborate in details.

  • @santoshkamat6132
    @santoshkamat6132 2 роки тому +1

    You doing a great job. Could you bring up a series on JMS , ActiveMq, RabbitMq, Kafka , etc in combo with Spring Boot. Would be very helpful. Not many videos on UA-cam of JMS in combo with spring boot

    • @priyanka0222
      @priyanka0222 2 роки тому

      What is com.sun.proxy.$proxy.i got this as runtime exception.what to resolve this exception.

  • @neerajmittal6060
    @neerajmittal6060 2 роки тому

    Thanks for the great videos Mam. Can you create a series on handling database transactions when a call go through multiple micro services? And each micro service has its own database.

  • @er.sahilmd
    @er.sahilmd 2 роки тому +1

    Yeah it's in right direction. Please cover other part also..

    • @CodeDecode
      @CodeDecode  2 роки тому

      sure we will cover it soon

  • @Prakash-gz6py
    @Prakash-gz6py 2 роки тому +2

    Yes, please cover the rest of the annotations.

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      Sure thanks Prakash 🙂👍

  • @rajashekar-bu8xd
    @rajashekar-bu8xd 2 роки тому +1

    Very useful video..

  • @akashsaha9366
    @akashsaha9366 2 роки тому +2

    Yes please cover the required beans or annotations of spring boot

  • @vidyab706
    @vidyab706 Рік тому +1

    Please mam,cover remaining part as well,it would be helpful,thank you so much for your wonderful content,thanks a ton😀😊

  • @ravi3743
    @ravi3743 2 роки тому +1

    Thank you it's really useful. Please do more videos on @annotations

  • @rishabhsharma7207
    @rishabhsharma7207 2 роки тому

    Big fan of you ma'am. Can you please share these slides as well for further revision.

  • @AshishSingh-rx4sq
    @AshishSingh-rx4sq 2 роки тому

    And thanks for making this.

  • @nabinghoshmaths6834
    @nabinghoshmaths6834 2 роки тому +1

    Please upload complete annotation interview questions of spring boot application. Thanks alot for making such good contents❤️

  • @shivakarthikeyan2131
    @shivakarthikeyan2131 2 роки тому

    500th Like Im Giving... 👍

  • @sourabhjinde8191
    @sourabhjinde8191 2 роки тому +1

    This is by far the best youtube channel for interview preparation. Thank you so much. Please create second part of this series.

    • @CodeDecode
      @CodeDecode  2 роки тому

      This means a lot to us sourabh. 🙂🙂🙂🙂. You made our day with such comments. It helps us to be motivated and post more such content 🙏🙏🙏🙏

  • @sachinjadhav8759
    @sachinjadhav8759 2 роки тому +1

    Awesome

  • @SarthakMandlik
    @SarthakMandlik 2 роки тому +2

    please make a video for how to retrieve value from hashmap having same index number.

  • @shubhamvishwakarma2198
    @shubhamvishwakarma2198 Рік тому

    Great explanation. Your voice sounded little hyper. Please stay calm while making videos.

  • @srinivassiddharth1017
    @srinivassiddharth1017 2 роки тому +1

    Waiting for part 2 of this video

    • @CodeDecode
      @CodeDecode  2 роки тому

      Sure we will upload it soon

  • @vazzdoin
    @vazzdoin 2 роки тому

    Wonderful explanation. Thanks for sharing the annotations tutorial, it cleared lot of doubts.
    I've one suggestion, your voice is very loud in all your videos, it feels like you are shouting. It seems you are a teacher and are habitual to speaking loud while teaching in the class but in the video it feels a bit screeching to the ears and hence not required. Please try to curb that habit if you are delivering for the video only.

  • @venkyvenky1747
    @venkyvenky1747 Рік тому +1

    Thanks ma

  • @abhi007rider
    @abhi007rider 2 роки тому +1

    Please more videos on microservices, design patterns

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      Sure we will upload soon

  • @hrithiksonu5836
    @hrithiksonu5836 Рік тому

    Mam Please make a video on how to explain a project based on springboot + mysql + java + with any frontend... As i dont have perfect idea on my entire project flow.

  • @amarthyaseshu683
    @amarthyaseshu683 2 роки тому +1

    @ThanksForSharing

  • @harishpasala5138
    @harishpasala5138 2 роки тому +1

    Hi Mam, Hope you’re well. I cracked many interviews because of u.
    Now i am confused to join between American Express and EY. Can you pls help me to decide which one is better.
    How is job security at Amex??

    • @CodeDecode
      @CodeDecode  2 роки тому +3

      Hey hi Harish. First of all many congratulations on clearing both. As far as our experience says, company never matters what really matters is the project. If project is good your life is smooth as butter . But if project is not as per the expectations your life will become hell. Avoid toxic it culture . Ask about the tech stack and client you will work with closely. If stack is good u will learn new things and will never feel stagnated . Go ahead and ask for the project and tech stack . All the best Harish . You will rock 🙂👍👍👍

  • @ruchigupta9811
    @ruchigupta9811 2 роки тому +1

    Can you please make a video on advance multithreading questions.

    • @CodeDecode
      @CodeDecode  2 роки тому

      Sure Ruchi. We will do that🙂👍

  • @prathappoojary8585
    @prathappoojary8585 2 роки тому +1

    Do the video of clients round interview 🙏

    • @CodeDecode
      @CodeDecode  2 роки тому

      That's a very nice topic we will surely cover it in coming future

  • @priyanka0222
    @priyanka0222 2 роки тому

    What is com.sun.proxy.$proxy. I got this as runtime exception.how to resolve this exception.

  • @suriyanarayanan2406
    @suriyanarayanan2406 2 роки тому +1

    Can you share some scenario based java interview questions

    • @CodeDecode
      @CodeDecode  2 роки тому

      Sure what kind of scenerios you need?

  • @harshadaraut4096
    @harshadaraut4096 2 роки тому

    Will you make video on SpringBoot application Deployment process

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      sure we will create it in future

  • @bharanitechsolutions
    @bharanitechsolutions 2 роки тому +1

    Please make a video on spring data jpa

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      Sure Mahi. We wll do that 🙂👍

  • @nishameeran6493
    @nishameeran6493 Рік тому +1

    Hi Mam. I am a house wife mother of 3. Now I got a opportunity to enter the software field as basic Java and spring boot developer. Can you help me what are the expected topics that I need to cover.? Do I have to do more practice on coding or just the concepts..?

    • @CodeDecode
      @CodeDecode  Рік тому

      Prepare well with all concepts thoroughly. Because with some gaps its very difficult to start again. We know thoughtworks is one who gives mothers with gaps to join back. Try that👍🙂

  • @mounikakoduri8041
    @mounikakoduri8041 Рік тому +1

    Do you give trainings as well?

    • @CodeDecode
      @CodeDecode  Рік тому

      Not yet Mounika. We all are full time developers at MNCs. Hardly get time to create videos even. Sorry. What do u need??❤❤.

  • @nabinghoshmaths6834
    @nabinghoshmaths6834 2 роки тому +1

    Please upload remaining annotations those filters annotations...🥺

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      Sure nabin we have uploaded one more video please check that out

  • @AshishSingh-rx4sq
    @AshishSingh-rx4sq 2 роки тому +1

    Please make a video on apache kafka tutorial.

  • @breddy5215
    @breddy5215 2 роки тому +1

    Hi, when can we expect the next part?

    • @CodeDecode
      @CodeDecode  2 роки тому +1

      we have uploaded it yesterday

  • @srinivasamovva2735
    @srinivasamovva2735 Рік тому +1

    You are so cute.. We all so greatful to you

  • @Khushi-xw6ie
    @Khushi-xw6ie 11 місяців тому

    Could you please share the slides used in the video?

  • @syedasheeba24
    @syedasheeba24 2 місяці тому +1

    Speaking too fast..

    • @CodeDecode
      @CodeDecode  2 місяці тому

      We will reduce the pace👍