| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -38,17 +38,14 @@ | |||
| 38 | 38 | <dependency> | |
| 39 | 39 | <groupId>org.springframework.boot</groupId> | |
| 40 | 40 | <artifactId>spring-boot-starter-test</artifactId> | |
| 41 | - <scope>test</scope> | ||
| 42 | 41 | </dependency> | |
| 43 | 42 | <dependency> | |
| 44 | 43 | <groupId>org.springframework.boot</groupId> | |
| 45 | 44 | <artifactId>spring-boot-starter-data-mongodb</artifactId> | |
| 46 | 45 | </dependency> | |
| 47 | - | ||
| 48 | 46 | <dependency> | |
| 49 | 47 | <groupId>junit</groupId> | |
| 50 | 48 | <artifactId>junit</artifactId> | |
| 51 | - <scope>test</scope> | ||
| 52 | 49 | </dependency> | |
| 53 | 50 | <dependency> | |
| 54 | 51 | <groupId>mysql</groupId> | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -25,27 +25,6 @@ banner.location=config/banner-girl.txt | |||
| 25 | 25 | # \u591A\u73AF\u5883\u914D\u7F6E\u6587\u4EF6\u6FC0\u6D3B\u5C5E\u6027 | |
| 26 | 26 | spring.profiles.active=dev | |
| 27 | 27 | ||
| 28 | - | ||
| 29 | - # redis | ||
| 30 | - # Redis\u6570\u636E\u5E93\u7D22\u5F15\uFF08\u9ED8\u8BA4\u4E3A0\uFF09 | ||
| 31 | - spring.redis.database=0 | ||
| 32 | - # Redis\u670D\u52A1\u5668\u5730\u5740 | ||
| 33 | - spring.redis.host=localhost | ||
| 34 | - # Redis\u670D\u52A1\u5668\u8FDE\u63A5\u7AEF\u53E3 | ||
| 35 | - spring.redis.port=6379 | ||
| 36 | - # Redis\u670D\u52A1\u5668\u8FDE\u63A5\u5BC6\u7801\uFF08\u9ED8\u8BA4\u4E3A\u7A7A\uFF09 | ||
| 37 | - spring.redis.password= | ||
| 38 | - # \u8FDE\u63A5\u6C60\u6700\u5927\u8FDE\u63A5\u6570\uFF08\u4F7F\u7528\u8D1F\u503C\u8868\u793A\u6CA1\u6709\u9650\u5236\uFF09 | ||
| 39 | - spring.redis.pool.max-active=8 | ||
| 40 | - # \u8FDE\u63A5\u6C60\u6700\u5927\u963B\u585E\u7B49\u5F85\u65F6\u95F4\uFF08\u4F7F\u7528\u8D1F\u503C\u8868\u793A\u6CA1\u6709\u9650\u5236\uFF09 | ||
| 41 | - spring.redis.pool.max-wait=-1 | ||
| 42 | - # \u8FDE\u63A5\u6C60\u4E2D\u7684\u6700\u5927\u7A7A\u95F2\u8FDE\u63A5 | ||
| 43 | - spring.redis.pool.max-idle=8 | ||
| 44 | - # \u8FDE\u63A5\u6C60\u4E2D\u7684\u6700\u5C0F\u7A7A\u95F2\u8FDE\u63A5 | ||
| 45 | - spring.redis.pool.min-idle=0 | ||
| 46 | - # \u8FDE\u63A5\u8D85\u65F6\u65F6\u95F4\uFF08\u6BEB\u79D2\uFF09 | ||
| 47 | - spring.redis.timeout=0 | ||
| 48 | - | ||
| 49 | 28 | #\u90AE\u4EF6 | |
| 50 | 29 | spring.mail.host=smtp.qq.com | |
| 51 | 30 | spring.mail.username=83387856@qq.com | |
@@ -55,12 +34,6 @@ spring.mail.properties.mail.smtp.starttls.enable=true | |||
| 55 | 34 | spring.mail.properties.mail.smtp.starttls.required=true | |
| 56 | 35 | ||
| 57 | 36 | ||
| 58 | - # rabbitmq | ||
| 59 | - spring.application.name=rabbitmq-xiaomo | ||
| 60 | - spring.rabbitmq.host=115.29.137.34 | ||
| 61 | - spring.rabbitmq.port=5672 | ||
| 62 | - spring.rabbitmq.username=xiaomo | ||
| 63 | - spring.rabbitmq.password=123456 | ||
| 64 | 37 | ||
| 65 | 38 | # mongod | |
| 66 | 39 | spring.data.mongodb.uri=mongodb://xiaomo:xiaomo@115.29.137.34:27017/admin | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -12,6 +12,9 @@ | |||
| 12 | 12 | <module>website</module> | |
| 13 | 13 | <module>core</module> | |
| 14 | 14 | <module>chat</module> | |
| 15 | + <module>scheduled</module> | ||
| 16 | + <module>rabbitmq</module> | ||
| 17 | + <module>redis</module> | ||
| 15 | 18 | </modules> | |
| 16 | 19 | <packaging>pom</packaging> | |
| 17 | 20 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,21 @@ | |||
| 1 | + <?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | + <project xmlns="http://maven.apache.org/POM/4.0.0" | ||
| 3 | + xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" | ||
| 4 | + xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"> | ||
| 5 | + <parent> | ||
| 6 | + <artifactId>xiaomo</artifactId> | ||
| 7 | + <groupId>info.xiaomo</groupId> | ||
| 8 | + <version>1.0.0-SNAPSHOT</version> | ||
| 9 | + </parent> | ||
| 10 | + <modelVersion>4.0.0</modelVersion> | ||
| 11 | + | ||
| 12 | + <artifactId>rabbitmq</artifactId> | ||
| 13 | + | ||
| 14 | + <dependencies> | ||
| 15 | + <dependency> | ||
| 16 | + <groupId>info.xiaomo</groupId> | ||
| 17 | + <artifactId>core</artifactId> | ||
| 18 | + <version>1.0.0-SNAPSHOT</version> | ||
| 19 | + </dependency> | ||
| 20 | + </dependencies> | ||
| 21 | + </project> | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,38 @@ | |||
| 1 | + package info.xiaomo.rabbitmq; | ||
| 2 | + | ||
| 3 | + import org.springframework.amqp.core.Queue; | ||
| 4 | + import org.springframework.boot.SpringApplication; | ||
| 5 | + import org.springframework.boot.autoconfigure.EnableAutoConfiguration; | ||
| 6 | + import org.springframework.context.annotation.Bean; | ||
| 7 | + import org.springframework.context.annotation.ComponentScan; | ||
| 8 | + import org.springframework.context.annotation.Configuration; | ||
| 9 | + import org.springframework.scheduling.annotation.EnableScheduling; | ||
| 10 | + | ||
| 11 | + /** | ||
| 12 | + * 把今天最好的表现当作明天最新的起点..~ | ||
| 13 | + * いま 最高の表現 として 明日最新の始発..~ | ||
| 14 | + * Today the best performance as tomorrow newest starter! | ||
| 15 | + * Created by IntelliJ IDEA. | ||
| 16 | + * | ||
| 17 | + * @author: xiaomo | ||
| 18 | + * @github: https://github.com/qq83387856 | ||
| 19 | + * @email: hupengbest@163.com | ||
| 20 | + * @QQ_NO: 83387856 | ||
| 21 | + * @Date: 2016/4/1 15:38 | ||
| 22 | + * @Description: 后台管理启动器 | ||
| 23 | + * @Copyright(©) 2015 by xiaomo. | ||
| 24 | + **/ | ||
| 25 | + @Configuration | ||
| 26 | + @EnableAutoConfiguration | ||
| 27 | + @ComponentScan("info.xiaomo") | ||
| 28 | + @EnableScheduling | ||
| 29 | + public class RabbitMqMain { | ||
| 30 | + public static void main(String[] args) throws Exception { | ||
| 31 | + SpringApplication.run(RabbitMqMain.class, args); | ||
| 32 | + } | ||
| 33 | + @Bean | ||
| 34 | + public Queue helloQueue() { | ||
| 35 | + return new Queue("hello"); | ||
| 36 | + } | ||
| 37 | + | ||
| 38 | + } | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,4 +1,4 @@ | |||
| 1 | - package info.xiaomo.core.rabbit; | ||
| 1 | + package info.xiaomo.rabbitmq.config; | ||
| 2 | 2 | ||
| 3 | 3 | import org.springframework.amqp.rabbit.annotation.RabbitHandler; | |
| 4 | 4 | import org.springframework.amqp.rabbit.annotation.RabbitListener; | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -1,4 +1,4 @@ | |||
| 1 | - package info.xiaomo.core.rabbit; | ||
| 1 | + package info.xiaomo.rabbitmq.config; | ||
| 2 | 2 | ||
| 3 | 3 | import org.springframework.amqp.core.AmqpTemplate; | |
| 4 | 4 | import org.springframework.beans.factory.annotation.Autowired; | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,27 @@ | |||
| 1 | + logging.config=classpath:config/logback-dev.xml | ||
| 2 | + server.port=8080 | ||
| 3 | + server.session.timeout=1800 | ||
| 4 | + server.max-http-header-size=20971520 | ||
| 5 | + | ||
| 6 | + #datasource | ||
| 7 | + spring.datasource.url=jdbc:mysql://115.29.137.34/xiaomo | ||
| 8 | + # ?useUnicode=true&characterEncoding=UTF-8 | ||
| 9 | + spring.datasource.username=xiaomo | ||
| 10 | + spring.datasource.password=123456 | ||
| 11 | + spring.datasource.driver-class-name=com.mysql.jdbc.Driver | ||
| 12 | + # \u914D\u7F6E\u8FD9\u4E2A\u503C\u5C31\u53EF\u4EE5\u683C\u5F0F\u5316\u65F6\u95F4 | ||
| 13 | + spring.jackson.date-format=yyyy-MM-dd HH:mm:ss | ||
| 14 | + spring.jackson.time-zone=GMT+8 | ||
| 15 | + | ||
| 16 | + #jpa | ||
| 17 | + spring.jpa.database-platform=org.hibernate.dialect.MySQL5Dialect | ||
| 18 | + spring.jpa.hibernate.ddl-auto=update | ||
| 19 | + spring.jpa.show-sql=true | ||
| 20 | + | ||
| 21 | + | ||
| 22 | + # rabbitmq | ||
| 23 | + spring.application.name=rabbitmq-xiaomo | ||
| 24 | + spring.rabbitmq.host=115.29.137.34 | ||
| 25 | + spring.rabbitmq.port=5672 | ||
| 26 | + spring.rabbitmq.username=xiaomo | ||
| 27 | + spring.rabbitmq.password=123456 | ||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
@@ -0,0 +1,17 @@ | |||
| 1 | + <?xml version="1.0" encoding="UTF-8"?> | ||
| 2 | + | ||
| 3 | + <configuration scan="true"> | ||
| 4 | + | ||
| 5 | + <appender name="stdout" class="ch.qos.logback.core.ConsoleAppender"> | ||
| 6 | + <encoder charset="UTF-8"> | ||
| 7 | + <pattern>%d{HH:mm:ss.SSS} [%thread] %-5level - %msg%n</pattern> | ||
| 8 | + </encoder> | ||
| 9 | + </appender> | ||
| 10 | + | ||
| 11 | + <root level="INFO"> | ||
| 12 | + <appender-ref ref="stdout"/> | ||
| 13 | + </root> | ||
| 14 | + | ||
| 15 | + <logger name="info.xiaomo" level="DEBUG"/> | ||
| 16 | + | ||
| 17 | + </configuration> | ||
| Back | FazBrowse Home | New Git URL |
0 commit comments