03 November 2020

#Spring_Boot

#Spring_Boot
What is the use of application.properties in spring boot?
What Is Devtools In Spring Boot?
What is username and password when starting Spring Boot with Tomcat?
What is ELK stack.
What is Spring Boot CLI? What are its benefits?
What are the Spring Boot starters and what are the available starters?
What are the steps to add a custom JS code with Spring Boot?
What do you understand by Spring Boot supports relaxed binding?
What is a shutdown in the actuator?
What are the various Advantages Of Using Spring Boot?
What do Dev Tools in Spring boot mean?
What does Spring Boot Starter Pom mean? Why Is It Useful?
What are esteem properties of Spring Boot?
What does Aspect-Oriented Programming (AOP) mean?
What is JavaConfig?
What is Swagger? Have you implemented it using Spring Boot?
What is Spring Batch? How do you implement it using Spring Boot?
What is FreeMarker Template? How do you implement it using Spring Boot?
What is caching? Have you used any caching framework with Spring Boot?
What is CSRF attack? How to enable CSRF protection against it?
What is AOP? How to use it with Spring Boot?
What are the major benefits of spring Externalized Configuration?
What is join point in Spring Boot?
What is Docker? How to deploy Spring Boot Applications to Docker?
What is ELK stack?How to use it with Spring Boot?
What is YAML?
What is Spring Profiles? How do you implement it using Spring Boot?
What is Apache Kafka? How to integrate it with Spring Boot?
What is JWT ? How to implement it using Spring Boot Security?
What is Hashicorp Valut? How to use it with microservices?
What are starter dependencies?
What are the actuator-provided endpoints used for monitoring the Spring boot application?
What are the advantages of using Spring Boot?
What Are the Basic Annotations that Spring Boot Offers?
What are the most common Spring Boot CLI commands?
What are the Spring Boot key components?
What is Auto Configuration?
What is Embedded server?
What is InMemory DB?
What is the use of @PatchMapping?
What is purpose of using @SpringBootApplication? How it internally works?
What is the use of @PutMapping?
What is Spring Actuator? What are its advantages?
What is Spring Boot auto-configuration?
What is Spring Boot CLI and how to execute the Spring Boot project using boot CLI?
What is Spring Boot dependency management?
What is Spring Boot starter POMs?
What is Spring boot?
What is Spring Initializer?
What is Starter POM?
What is the default port of tomcat in spring boot?
What is the starter dependency of the Spring boot module?
What is the use of Beans endpoint?
What is the use of Configprops endpoint?
What is the use of Health endpoint?
What is the use of Heapdump endpoint?
What is the use of Httptrace endpoint?
What is the use of Info endpoint?
What is the use of Mappings endpoint?
What is the use of Profiles in spring boot?
What is the use of Shutdown endpoint?
What is the use of Threaddump endpoint?
What is Version Management?
What is Application Properties?
What is Command-line properties?
What is Profile-specific properties?
What is Spring Boot DevTools?
What are the steps to deploy Spring Boot web applications as JAR and WAR files?
What do you think is the need for Profiles?
What is the way to use profiles to configure the environment-specific configuration with Spring Boot?
What is the name of the default H2 database configured by Spring Boot?
What is response entity in spring boot?
What is bootstrapping in spring boot?
What is Jhipster?
What is HTTP methods that can be implemented in spring boot rest service?
What is the main class in spring boot?
what is the rest controller in spring boot?
What is the use of @configuartion?
What is the use of @Bean?
What is the use of @component?
What is the use of @Controller?
What is the use of @service?
What is the use of @Repository?
What is the use of @EnableAutoConfiguaration?
What is the use of @SpringBootApplication?
What is the use of @RequestMapping?
What is the use of @GetMapping?
What is the use of @PostMapping?
Mention the possible sources of external configuration
Mention the steps to create a Spring Boot project using Spring Initializr
Mention the advantages of the YAML file than Properties file and the different ways to load YAML file in Spring boot.
List out benefits of using the JavaConfig method.
Is it possible to change the port of Embedded Tomcat server in Spring boot?
Is it possible to change the port of the embedded Tomcat server in Spring Boot?
How to perform the component scan for spring boot?
How do I use Spring Boot to serve static content located in Dropbox folder?
How to customise the Jackson JSON mapper implicitly used by Spring Boot?
How to enable HTTP response caching in Spring Boot
How to set base url for rest in spring boot?
How is Hibernate chosen as the default implementation for JPA without any configuration?
How to Write Integration Tests?
How to enable hot deployment and live reload on browser?
How Might You Implement Spring Security In Spring Boot Application?
How to implement JWT authentication for Spring Boot Application?
How to enable and disable Actuator endpoint security in Spring Boot?
How to implement Pagination and Sorting with Spring Boot?
How can we monitor all the Spring Boot Microservices?
How to reload my changes on Spring Boot without having to restart server?
How to deploy Spring Boot application as a WAR?
How to run Spring boot application to custom port?
How to implement security for Spring boot application?
How to implement Exception Handling using Spring Boot?
How did you perform database operations using Spring Boot?
How to develop a full stack application using Spring Boot and Angular?
How to upload a file using Spring?
How to implement interceptors with Spring Boot?
How to use Form Login Authentication using Spring Boot?
How to deploy Spring Boot Application to Pivotal Cloud Foundry(PCF)?
How to deploy Spring Boot + MySQL Application to Pivotal Cloud Foundry(PCF)?
How to deploy Spring Boot + RabbitMQ Application to Pivotal Cloud Foundry(PCF)?
How to implement distributed logging for microservices?
How does a spring boot application get started?
How does Spring Boot works?
How to check the environment properties in your Spring boot application?
How to disable a specific auto-configuration class?
How to enable debugging log in the spring boot application?
How to get the list of all the beans in your Spring boot application?
How to connect Spring Boot application to a database using JDBC.
How can we create a custom endpoint in Spring Boot Actuator?
How to register a custom auto-configuration.
How to instruct an auto-configuration to back off when a bean exists?
How to save image in database using spring boot?
How to resolve whitelabel error page in spring boot application?
How to fetch data from database in spring boot?
How to use logger in spring boot?
How to handle exceptions in spring boot?
How to store image in MongoDB using spring boot?
How to configure hibernate in spring boot?
How to call servlet in spring boot?
How to debug spring boot application in eclipse?
How to insert data in mysql using spring boot?
How to create a login page in spring boot?
How to use crud repository in spring boot?
How to run spring-boot jar from the command line?
How to ignore null values in JSON response spring boot?
How to handle 404 error in spring boot?
How to do pagination in spring boot? PagingAndSortingRepository?
Have you integrated Spring Boot and ActiveMQ?
Have you written Test cases using Spring Boot?
Have you integrated Spring Boot and Apache Kafka?
Have you exposed a SOAP webservice endpoint using Spring Boot?
Have you used any Spring Cloud Components with Spring Boot?
Error while Handling 404 error for Spring Boot REST application
Enable HAL serialization in Spring Boot for custom controller method
Do you think, you can use jetty instead of tomcat in spring-boot-starter-web?
Can we change the port of the embedded Tomcat server in Spring boot?
Can you give an example for ReadOnly as true in Transaction management?
Can you explain how to deploy to a different server with Spring Boot?
Can you disable the default web server in the Spring Boot application?
Can we create a non-web application in Spring Boot?
Can we override or replace the Embedded tomcat server in Spring Boot?
Can you explain what happens in the background when a Spring Boot Application is ?Run as Java Application??
Difference - @ComponentScan and @EnableAutoConfiguration
Difference - Spring and Spring Boot?
Difference - RequestMapping and GetMapping
Difference - Embedded Container And A War
Difference - @SpringBootApplication and @EnableAutoConfiguration
Difference - WAR and embedded containers
Difference - @RestController and @Controller
Explain how to register a custom auto-configuration.
Explain thymeleaf in Spring Boot.
Explain CORS in Spring Boot?
Explain different types of dependency injection.
Explain - @EnableAutoConfiguration
Explain - @RestController?
Explain - @SpringBootApplication
Explain what is thyme leaf and how to use thymeleaf?
Why is Spring Data REST not recommended in real-world applications?
Why do we use ?Opinionated? in spring boot?
Why Spring Boot over Spring?
Why spring boot is used for microservices?
Which build tool have you used to develop Spring Boot Application?
Which all starter maven dependencies have you used?
Which is the ui web framework that is built to use spring boot?
Which is the spring boot latest version?
Where do we define properties in the Spring Boot application?
Where is the database connection information specified and how does it automatically connect to H2?
When will you use WebSockets? How tto implement it using Spring Boot?
Spring-Boot
  • Spring Boot Starter Template
  • Spring Boot Auto-Configuration
  • Embedded Servers - It provides embedded HTTP server Tomcat so that you can develop and test quickly.
  • It helps in resolving dependency conflict. It identifies required dependencies and imports
  • It has information of the compatible versions for all dependencies. It minimizes the runtime classloader issues
  • Dev Tools
Profiles
  • A profile is a segregation between different runtime environments
  • Which beans are loaded into the application context
  • Which application properties are applied
  • Default Profile - @Profile("default")
  • @Profile
    • Stereotype annotations such as @Component, @Service, @Repository, or @Controller.
    • @Configuration
    • @ConfigurationProperties
  • Activating multiple profiles can result in duplicate beans and runtime exceptions
  • Profile Groups - A profile group allows to group similar profiles together.
RestTemplate
  • getForObject() - retrieves a representation by doing a GET on the URL. The response (if any) is unmarshalled to the given class type and returned.
  • getForEntity() - retrieve a representation as ResponseEntity by doing a GET on the URL.
  • exchange() - execute the specified HttpEntity and return the response as ResponseEntity.
  • execute() - execute the HttpMethod to the given URI template, prepare the request with the RequestCallback, and read the response with a ResponseExtractor.
Filter
  • We must implement the javax.servlet.Filter interface to create filters that can be invoked for either the request to a resource, the response or both.
  • Type of filters
    • AbstractRequestLoggingFilter: to perform logging operations before and after a request is processed.
    • CharacterEncodingFilter: to specify a character encoding for requests.
    • CorsFilter: to handle CORS pre-flight requests and to update the response.
    • OncePerRequestFilter: to guarantee a single execution per request dispatch, on any servlet container.
  • @WebFilter
  • Filter with URL Patterns
  • Disabling a Filter
Scheduling
  • @Scheduled annotation is used for task scheduling. The trigger information needs to be provided along with this annotation.
  • They should not return any values too.
  • fixedDelay vs fixedRate vs cron
    • fixedRate makes Spring run the task on periodic intervals even if the last invocation may be still running.
    • fixedDelay specifically controls the next execution time when the last execution finishes.
    • cron is a feature originating from Unix cron utility and has various options based on your requirements.
  • Execute a task at a fixed interval of time : @Scheduled(initialDelay = 1000, fixedRate = 10000)
  • Schedule task at fixed delay : @Scheduled(fixedDelay = 10000)
  • Cron job : @Scheduled(cron = "0 10 10 10 * ?")
Actuator
  • Spring Boot Actuator is a Spring Framework sub-project.
  • It allows us to monitor our application, get information about the project, gather metrics, or just check the state of our application/database.
  • The endpoint must be enabled.
  • By default, all endpoints except /shutdown are enabled
  • By default, only /health endpoint will be accessible from the browser, and other endpoints can be accessed using JMX.
  • There are the following inbuilt contributors for application information. We must enable them to include that information in /info response.
    • build: Exposes build information from META-INF/build-info.properties file. (management.info.build.enabled=true)
    • env: Exposes any property from the Environment whose name starts with info.(management.info.env.enabled=true)
    • git: Exposes git information from git.properties in the classpath. (management.info.git.enabled=true)
    • java: Exposes Java runtime information.(management.info.java.enabled=true)
    • os: Exposes Operating System information.(management.info.os.enabled=true)
  • We can customize even more by excluding unwanted build properties using the excludeProperty tag.
#SpringBoot #SpringFramework #Java #JavaDevelopment #SpringDeveloper #SpringBootApp #SpringBootProject #SpringBootMicroservices #Microservices #SpringBootTutorial #SpringBootLearning #SpringBootDeveloper #SpringBootMVC #SpringBootSecurity #SpringBootRest #SpringBootAPI #SpringBootTips #SpringBootTesting #SpringBootIntegration #SpringBootArchitecture #SpringBootStarter #SpringBootCloud #SpringCloud #SpringBootJPA #SpringBootHibernate #SpringBootKafka #SpringBootRabbitMQ #SpringBootActuator #SpringBootDeploy #SpringBootBestPractices #SpringBootConfiguration #SpringBootDevTools #SpringBootPerformance #SpringBootWeb #SpringBootWebFlux #SpringBootReactive #SpringBootDocker #SpringBootAWS #SpringBootAzure #SpringBootGCP #SpringBootAdmin #SpringBootCache #SpringBootGraphQL #SpringBootWebSockets #SpringBootKotlin #SpringBootMaven #SpringBootGradle #SpringBootDependencies #SpringBootExamples #SpringBootCommunity

No comments:

Post a Comment

Most views on this month