Before going further lets talk about Log Forging or JVM Log Forging. Log ForgingAccording to OWASP , writing invalidated logs can allow attackers to forge log or inject malicious content in log file. Log forging is when attackers tries to add/modify the log content by exploring the security loopholes of...
Showing posts with label SpringBoot. Show all posts
Showing posts with label SpringBoot. Show all posts
undefined
201
What’s the difference between @Component, @Controller, @Repository & @Service annotations in Spring?
Pointcut:
Pointcut are expressions that is matched with join points to determine whether
advice needs to be executed or not. Pointcut uses different kinds of
expressions that are matched with the join points...
undefined
201
Spring
2.5 introduces further stereotype annotations: @Component, @Service, and @Controller. @Component is
a generic stereotype for any Spring-managed component. @Repository, @Service, and @Controller are
specializations of @Component for
more specific use cases,...
undefined
201
Partial Dependency
In Setter Injection, partial dependency is possible, means if we have 4 dependencies as mentioned below,
Then it is not necessary to inject all values if we are using setter injection.
But in Constructor Injection, partial dependency is not possible because we are calling the constructor of that...
undefined
201
We can set the timeout for RestTemplate by doing some custom configuration for RestTemplate.
First you need to create a class named as HttpClientConfig in this class we configure HttpClient because RestTemplate internally uses the HttpClient.
package com.codebyakram;
import org.apache.http.client.config.RequestConfig;
import...
undefined
201
How To deploy Spring Boot application on existing Tomcat?
Related Questions:- Deploy a Spring Boot WAR into a Tomcat Server, Spring Boot – Deploy WAR file to Tomcat
Spring boot is a framework that allow you to set up production ready setup of spring application and also Tomcat is one of the most popular...
undefined
201
How to disable Spring banner?
You can disable the spring boot banner by adding the below mentioned code in your main method.
app.setBannerMode(Banner.Mode.OFF);
Just add the above mentioned code in main method and spring banner will be disabled...
undefined
201
What is @SpringBootApplication in Spring Boot?
"Indicates a configuration class that declares one or more @Bean methods and also triggers auto-configuration and component scanning. This is a convenience annotation that is equivalent to declaring @Configuration, @EnableAutoConfiguration and @ComponentScan."
If...