Nitin Agrawal
Contact -
  • Home
  • Interviews
    • Secret Receipe
    • InterviewFacts
    • Resume Thoughts
    • Daily Coding Problems
    • BigShyft
    • Companies
    • Interviews Theory
  • Programming Languages
    • Java Script >
      • Tutorials
      • Code Snippets
    • Reactive Programming >
      • Code Snippets
    • R
    • DataStructures >
      • LeetCode Problems >
        • Problem10
        • Problem300
      • AnagramsSet
    • Core Java >
      • Codility
      • Program Arguments OR VM arguments & Environment variables
      • Java Releases >
        • Java8 >
          • Performance
          • NasHorn
          • WordCount
          • Thoughts
        • Java9 >
          • ServiceLoaders
          • Lambdas
          • List Of Objects
          • Code Snippets
        • Java14 >
          • Teeing
          • Pattern
          • Semaphores
        • Java17 >
          • Switches
          • FunctionalStreams
          • Predicate
          • Consumer_Supplier
          • Collectors in Java
        • Java21 >
          • Un-named Class
          • Virtual Threads
          • Structured Concurrency
      • Threading >
        • ThreadsOrder
        • ProducerConsumer
        • Finalizer
        • RaceCondition
        • Executors
        • Future Or CompletableFuture
      • Important Points
      • Immutability
      • Dictionary
      • Sample Code Part 1 >
        • PatternLength
        • Serialization >
          • Kryo2
          • JAXB/XSD
          • XStream
        • MongoDB
        • Strings >
          • Reverse the String
          • Reverse the String in n/2 complexity
          • StringEditor
          • Reversing String
          • String Puzzle
          • Knuth Morris Pratt
          • Unique characters
          • Top N most occurring characters
          • Longest Common Subsequence
          • Longest Common Substring
        • New methods in Collections
        • MethodReferences
        • Complex Objects Comparator >
          • Performance
        • NIO >
          • NIO 2nd Sample
        • Date Converter
        • Minimum cost path
        • Find File
      • URL Validator
    • Julia
    • Python >
      • Decorators
      • String Formatting
      • Generators_Threads
      • JustLikeThat
    • Go >
      • Tutorial
      • CodeSnippet
      • Go Routine_Channel
      • Suggestions
    • Methodologies & Design Patterns >
      • Design Principles
      • Design Patterns >
        • TemplatePattern
        • Adapter Design Pattern
        • Proxy
        • Lazy Initialization
        • CombinatorPattern
        • Singleton >
          • Singletons
        • Strategy
  • Frameworks
    • Apache Velocity
    • React Library >
      • Tutorial
    • Spring >
      • Spring Boot >
        • CustomProperties
        • ExceptionHandling
        • Custom Beans
        • Issues
      • Quick View
    • Rest WebServices >
      • Interviews
      • Swagger
    • Cloudera BigData >
      • Ques_Ans
      • Hive
      • Apache Spark >
        • ApacheSpark Installation
        • SparkCode
        • Sample1
        • DataFrames
        • RDDs
        • SparkStreaming
        • SparkFiles
    • Integration >
      • Apache Camel
    • Testing Frameworks >
      • JUnit >
        • JUnit Runners
      • EasyMock
      • Mockito >
        • Page 2
      • TestNG
    • Blockchain >
      • Ethereum Smart Contract
      • Blockchain Java Example
    • Microservices >
      • Messaging Formats
      • Design Patterns
    • AWS >
      • Honeycode
    • Dockers >
      • GitBash
      • Issues
      • Kubernetes
  • Databases
    • MySql
    • Oracle >
      • Interview1
      • SQL Queries
    • Elastic Search
  • Random issues
    • TOAD issue
    • Architect's suggestions
    • Dynamic loading of agents
  • Your Views
Will keep on adding samples/examples as I come across...

​If you are getting error & your Spring Boot application is not starting due to some missing class or class definition.
​And you are sure that your POM file is correct & complete.
​Then before trying other solutions, just try to delete all the files from .m2 folder on your machine & let all the required files be downloaded again.
Or directly use SpringBoot version - 2.0.4 or 1.4.2.RELEASE
Below is the URL to see different properties which you can play with in application.properties file
docs.spring.io/spring-boot/docs/current/reference/html/common-application-properties.html​

​Good quick tutorial to build one running Spring Boot application -
https://www.callicoder.com/spring-boot-rest-api-tutorial-with-mysql-jpa-hibernate/

I will be posting the ​working project taken from the above blog & below attached pdf. And I had to make a few changes in that to make it working & did some refactoring.
​So will attach all the files here as .zip which you can use on your local.
​I have added few of my comments in the attached file which may help you while practising. I have studied 5 chapters only from this book & added my comments & highlighted important words or lines there.
spring_boot_in_action.pdf
File Size: 6693 kb
File Type: pdf
Download File

 A Quick sample for REST in SpringBoot

    
 Some suggested best practises while developing springboot services-
​Spring Boot Microservices Coding Style Guidelines and Best Practices | by Wenqi Glantz | CodeX | Medium

Switching from RestTemplate to WebClient: A Reactive Tale - Lowie Cuypers — Ordina JWorks Tech Blog (ordina-jworks.github.io)
 While developing any application, it is always good to handle the corner scenarios & handle the situations if something goes
out of the hand. In short it always good to handle the exceptions occuring in the application & try to wrap them under your
business specific exceptions which should be Runtime Exceptions & have meaningful messages to the client with relevant error codes.
 For this you will be defining your own Business specific exceptions & use them while returning any exception.
 Check a quick guide about this in your SpringBoot app : ​Dynamic Proxies in Java | Baeldung
 While writting SpringBoot application, you will also be writting the test classes & I agree with below pic, that many of your test classes can be written using some or all the given features.
 Below poc has been taken from : ​https://www.youtube.com/watch?v=Ekr4jxOIf4c
Picture
Overview of Spring Boot Dev Tools |Baeldung
Streaming Data with Spring Boot RESTful Web Service (technicalsand.com)

Powered by Create your own unique website with customizable templates.