Read about spring boot microservices maven example, The latest news, videos, and discussion topics about spring boot microservices maven example from alibabacloud.com
Introducing the LOG4J2 Log framework
The log4j2 is not introduced. LOG4J2 official website
Configuration of the scheme in Official document 77.2 Configure log4j for Logging1. Maven Dependency Configurationpom.xmlRemove Logback and introduce log4j22. Configuration files2.1 Log4j2.xmlUsing an XML format configuration file eliminates the need to add additional dependent libraries.2.2 Log4j2.yaml/log4j2.ymlUse the YAML/YML format
' (
' id ' bigint not null auto_increment,
' name ' varchar (255) NULL,
' age ' int NULL,
PRIMARY KEY (' id ')
);
INSERT into info (name,age) VALUES (' Mick ', ' a ');
INSERT into info (name,age) VALUES (' Mick1 ', ' a ');
INSERT into info (name,age) VALUES (' Mickjoust1 ', ' + ');
INSERT into info (name,age) VALUES (' Joust ', ' 22 ');
Start
View Homepage: http://localhost:8080View database data: Http://localhost:8080/show Summary
This chapter has more space to configure, omit some of th
Idea: Maven supports the profile feature, when packaged with Maven profile, you can package the specified directory and specify the file, and you can modify the variables in the file. Spring boot also supports the profile feature, as long as you specify SPRING.PROFILES.ACTIVE=XXX in the application.properties file, whe
Every time eclipse uses the run as-a Maven install, it always runs JUnit test, some of which are associated with databases, and some are more dangerous. How do I skip the test skip testing?The Spring-boot-maven-plugin plugin has integrated the Maven-surefire-plugin plug-in t
After the configuration file is configured, you can write the first example!
@ Controller@ EnableAutoConfiguration ()Public class SampleController{Private Hello;@ AutowiredPublic SampleController (Hello hello){This. hello = hello;}@ RequestMapping ("/")@ ResponseBodyString home (String type){System. out. println ("login:" + hello );Return "Hello World ";}Public static void main (String [] args) throws Exception{SpringApplication app = new SpringApplic
Application is the boot module, the YML configuration file is configured in this moduleThe parent module does not configure the Packaging using the Package commandWhen the entire project is packaged as a jar,The submodule is packaged into a jar, and if you want to load the resource file in the code, you cannot use theresource.getFile(),应该使用resource.getInputStream().Spring
Build a Web development environment using IntelliJ IDEA and Maven Management (taking Spring MVC as an example)
I used MyEclipse all the time. After I changed my job, the new company used IDEA. I first got to know IDEA and found that wow, there are so many shortcut keys, but I think it is very useful all the way, especially with
Because it is recommended that you use MAVEN to download the associated spring jar package on the Spring official web site, review how to build Spring MVC with Maven, and learn about spring MVC by the way. (The installation of the
Tags: spring mybatis maven MySQL Lin Bingwen Evankaka original works. Reprint please specify the source Http://blog.csdn.net/evankakaAbstract: This article is mainly about how to use Maven to build the spring+mybatis+mysql of the building example, the article is written in d
Maven Sub-module Development Example Small project caseSpring+springmvc+hibernate ArchitectureUser management to do testing, sub-dao,sevices,web layer, sub-module development test! Because of time, only test the success of the query, the other preparation on the EXT to do a complete case, but the recent time is very tight,The advanced section did not test, such as the use of the other common plug-in testing
Example of integrated development of Spring Boot with Spark and Cassandra systems, sparkcassandra
This article demonstrates how to use Spark as the analysis engine and Cassandra as the data storage, and use Spring Boot to develop the driver.
1. Prerequisites
Install Spark
Spring boot aop record method execution time code example, springaop
This article focuses on the implementation code of spring boot aop recording method execution time, as follows.
In order to optimize the performance, we need to calculate the execution time of each method f
Spring boot thymeleaf Template engine simplest output exampleThe controller code is as follows:@GetMapping (value = "/test")Public String test (model model) { List Boy.add (New Boy ("XX", 11)); Boy.add (New boy ("yy", 22)); Boy.add (New Boy ("ZZ", 33)); Model.addattribute ("Boy", boy); return "hellohtml";}The template code is as follows:
configuration to [email protected] started 6 plugins.
Copy CodeOpen the browser and access: http://localhost:15672/, and use the default user guest login, the password is also guest. We can see the administration page as follows:, we can see some of the basic concepts mentioned in the previous chapters, such as Connections, Channels, exchanges, queue, and so on. The first use of the reader, can be opened to see what the content, familiar with the RABBITMQ Server service side.Click the
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.