Commit 60b04139 by mergen

fix problems

parent 1d2a57f0
...@@ -18,6 +18,10 @@ ...@@ -18,6 +18,10 @@
<druid.version>1.1.10</druid.version> <druid.version>1.1.10</druid.version>
<java.version>1.8</java.version> <java.version>1.8</java.version>
<fastjson.version>1.2.46</fastjson.version> <fastjson.version>1.2.46</fastjson.version>
<spring-cloud.version>Greenwich.SR2</spring-cloud.version>
</properties> </properties>
<dependencies> <dependencies>
...@@ -103,12 +107,6 @@ ...@@ -103,12 +107,6 @@
</dependency> </dependency>
<dependency> <dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-alibaba-nacos-discovery</artifactId>
<version>0.2.1.RELEASE</version>
</dependency>
<dependency>
<groupId>org.mapstruct</groupId> <groupId>org.mapstruct</groupId>
<artifactId>mapstruct-jdk8</artifactId> <artifactId>mapstruct-jdk8</artifactId>
<version>1.3.0.Final</version> <version>1.3.0.Final</version>
...@@ -120,8 +118,26 @@ ...@@ -120,8 +118,26 @@
<version>1.3.0.Final</version> <version>1.3.0.Final</version>
</dependency> </dependency>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-starter-netflix-eureka-client</artifactId>
</dependency>
</dependencies> </dependencies>
<dependencyManagement>
<dependencies>
<dependency>
<groupId>org.springframework.cloud</groupId>
<artifactId>spring-cloud-dependencies</artifactId>
<version>${spring-cloud.version}</version>
<type>pom</type>
<scope>import</scope>
</dependency>
</dependencies>
</dependencyManagement>
<build> <build>
<plugins> <plugins>
<plugin> <plugin>
......
...@@ -6,6 +6,7 @@ import org.springframework.boot.SpringApplication; ...@@ -6,6 +6,7 @@ import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.EnableAutoConfiguration; import org.springframework.boot.autoconfigure.EnableAutoConfiguration;
import org.springframework.boot.autoconfigure.SpringBootApplication; import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient; import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.netflix.eureka.EnableEurekaClient;
import org.springframework.context.annotation.Bean; import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.ComponentScan; import org.springframework.context.annotation.ComponentScan;
import org.springframework.transaction.annotation.EnableTransactionManagement; import org.springframework.transaction.annotation.EnableTransactionManagement;
...@@ -13,7 +14,7 @@ import org.springframework.transaction.annotation.EnableTransactionManagement; ...@@ -13,7 +14,7 @@ import org.springframework.transaction.annotation.EnableTransactionManagement;
@SpringBootApplication @SpringBootApplication
@ComponentScan({"com.alibaba.fastjson.support.spring", "com.orhon.smartcampus.material"}) @ComponentScan({"com.alibaba.fastjson.support.spring", "com.orhon.smartcampus.material"})
@EnableTransactionManagement @EnableTransactionManagement
@EnableDiscoveryClient @EnableEurekaClient
public class MaterialApplication { public class MaterialApplication {
public static void main(String[] args) { public static void main(String[] args) {
......
spring:
datasource:
driver-class-name: com.mysql.cj.jdbc.Driver
#url: jdbc:mysql://39.104.181.104:3311/smartcloud?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf-8&useSSL=true
url: jdbc:mysql://localhost:3306/material?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf-8&useSSL=true
username: root
password: weixuanhe2233
type: com.alibaba.druid.pool.DruidDataSource
#最大活跃数
maxActive: 20
#初始化数量
initialSize: 1
#最大连接等待超时时间
maxWait: 60000
#打开PSCache,并且指定每个连接PSCache的大小ull
poolPreparedStatements: true
maxPoolPreparedStatementPerConnectionSize: 20
#通过connectionProperties属性来打开mergeSql功能;慢SQL记录
#connectionProperties: druid.stat.mergeSql=true;druid.stat.slowSqlMillis=5000
minIdle: 1
timeBetweenEvictionRunsMillis: 60000
minEvictableIdleTimeMillis: 300000
validationQuery: select 1 from dual
testWhileIdle: true
testOnBorrow: false
testOnReturn: false
#配置监控统计拦截的filters,去掉后监控界面sql将无法统计,'wall'用于防火墙
filters: stat, wall, log4j
#日志
#logging:
# config: classpath:logback-boot.xml
# level:
# com.orhon.smartcampus.modules.*.mapper: DEBUG
eureka:
client:
service-url:
defaultZone: http://192.168.2.135:30016/eureka
spring:
datasource:
driver-class-name: com.mysql.cj.jdbc.Driver
url: jdbc:mysql://39.104.181.104:3308/smartcloud?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf-8&useSSL=true
#url: jdbc:mysql://localhost:3306/material?serverTimezone=Asia/Shanghai&useUnicode=true&characterEncoding=utf-8&useSSL=true
username: root
password: SmartCampusDB7893
type: com.alibaba.druid.pool.DruidDataSource
#最大活跃数
maxActive: 20
#初始化数量
initialSize: 1
#最大连接等待超时时间
maxWait: 60000
#打开PSCache,并且指定每个连接PSCache的大小ull
poolPreparedStatements: true
maxPoolPreparedStatementPerConnectionSize: 20
#通过connectionProperties属性来打开mergeSql功能;慢SQL记录
#connectionProperties: druid.stat.mergeSql=true;druid.stat.slowSqlMillis=5000
minIdle: 1
timeBetweenEvictionRunsMillis: 60000
minEvictableIdleTimeMillis: 300000
validationQuery: select 1 from dual
testWhileIdle: true
testOnBorrow: false
testOnReturn: false
#配置监控统计拦截的filters,去掉后监控界面sql将无法统计,'wall'用于防火墙
filters: stat, wall, log4j
#日志
#logging:
# config: classpath:logback-boot.xml
# level:
# com.orhon.smartcampus.modules.*.mapper: DEBUG
...@@ -5,18 +5,14 @@ server: ...@@ -5,18 +5,14 @@ server:
uri-encoding: UTF-8 uri-encoding: UTF-8
max-threads: 1000 max-threads: 1000
min-spare-threads: 30 min-spare-threads: 30
port: 8011 port: 8031
connection-timeout: 5000 connection-timeout: 5000
spring: spring:
application: application:
name: material-base name: smartcampus-material-112233
# cloud:
# nacos:
# discovery:
# server-addr: 39.104.181.104:8848
profiles: profiles:
active: dev active: testenv
jackson: jackson:
time-zone: GMT+8 time-zone: GMT+8
date-format: yyyy-MM-dd HH:mm:ss date-format: yyyy-MM-dd HH:mm:ss
...@@ -25,9 +21,6 @@ spring: ...@@ -25,9 +21,6 @@ spring:
max-file-size: 100MB max-file-size: 100MB
max-request-size: 100MB max-request-size: 100MB
enabled: true enabled: true
# mvc:
# throw-exception-if-no-handler-found: true
# static-path-pattern: /static/**
resources: resources:
add-mappings: false add-mappings: false
static-locations: /static/ static-locations: /static/
...@@ -36,36 +29,13 @@ spring: ...@@ -36,36 +29,13 @@ spring:
graphql: graphql:
servlet: servlet:
mapping: /graphql mapping: /material-gql
enabled: true enabled: true
corsEnabled: true corsEnabled: true
exception-handlers-enabled: true exception-handlers-enabled: true
contextSetting: PER_REQUEST_WITH_INSTRUMENTATION contextSetting: PER_REQUEST_WITH_INSTRUMENTATION
maxQueryDepth: 13 maxQueryDepth: 13
graphiql:
mapping: /graphiql
endpoint:
graphql: /graphql
subscriptions: /subscriptions
static:
basePath: /
enabled: true
pageTitle: GraphiQL
cdn:
enabled: false
version: 0.11.11
props:
resources:
query: testquery.query
defaultQuery: testquery.query
variables:
editorTheme: "solarized light"
headers:
token: "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzY2hvb2xfaWQiOjEsImV4cCI6MTU2OTM0OTQyOSwidXNlcmlkIjoxLCJ1c2VybmFtZSI6InRlYWNoZXIifQ.zewl-qR-i-pz5VnqUE2SXsoijV4JdUk5f6GbyRuawCk"
altair: altair:
mapping: /altair mapping: /altair
endpoint: endpoint:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment