Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
A
amos-boot-biz
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
项目统一框架
amos-boot-biz
Commits
9b44cc39
Commit
9b44cc39
authored
Oct 14, 2022
by
chenzhao
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改代码
parent
149e6316
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
131 additions
and
47 deletions
+131
-47
GlobalResponseHandler.java
...manage/common/exception/handle/GlobalResponseHandler.java
+6
-0
application-dev.properties
...-system-fas/src/main/resources/application-dev.properties
+32
-10
application-single.properties
...stem-fas/src/main/resources/application-single.properties
+73
-0
jcs-1.0.0.0.xml
...ystem-jcs/src/main/resources/db/changelog/jcs-1.0.0.0.xml
+15
-0
application.properties
...em-latentdanger/src/main/resources/application.properties
+4
-0
dbTemplate_plan_task.xml
...rol/src/main/resources/db/mapper/dbTemplate_plan_task.xml
+1
-1
WebSecurityConfig.java
...java/com/yeejoin/amos/jpush/config/WebSecurityConfig.java
+0
-36
No files found.
amos-boot-module/amos-boot-module-api/amos-boot-module-equip-api/src/main/java/com/yeejoin/equipmanage/common/exception/handle/GlobalResponseHandler.java
View file @
9b44cc39
...
...
@@ -29,6 +29,9 @@ public class GlobalResponseHandler implements ResponseBodyAdvice<Object> {
final
static
String
SWAGGER_RESOURCES
=
"swagger"
;
final
static
String
CSRF
=
"csrf"
;
final
static
String
ERROR
=
"error"
;
final
static
String
ACTUATOR
=
"actuator"
;
final
static
String
INSTANCES
=
"instances"
;
static
LinkedList
<
String
>
filterUrl
=
new
LinkedList
<>();
...
...
@@ -36,6 +39,9 @@ public class GlobalResponseHandler implements ResponseBodyAdvice<Object> {
filterUrl
.
add
(
SWAGGER_URL
);
filterUrl
.
add
(
SWAGGER_RESOURCES
);
filterUrl
.
add
(
CSRF
);
filterUrl
.
add
(
ACTUATOR
);
filterUrl
.
add
(
INSTANCES
);
}
/**
...
...
amos-boot-system-fas/src/main/resources/application-dev.properties
View file @
9b44cc39
...
...
@@ -31,8 +31,6 @@ amos.system.user.product=AMOS_STUDIO_WEB
eureka.client.serviceUrl.defaultZone
=
http://172.16.10.72:10001/eureka/
eureka.client.registry-fetch-interval-seconds
=
5
eureka.instance.prefer-ip-address
=
true
management.endpoint.health.show-details
=
always
management.endpoints.web.exposure.include
=
*
eureka.instance.health-check-url-path
=
/actuator/health
eureka.instance.lease-expiration-duration-in-seconds
=
10
eureka.instance.lease-renewal-interval-in-seconds
=
5
...
...
@@ -42,15 +40,39 @@ eureka.instance.metadata-map.management.api-docs=http://localhost:${server.port}
#redis
#redis 基础配置
spring.redis.database
=
0
spring.redis.host
=
172.16.10.85
spring.redis.port
=
6379
spring.redis.password
=
amos2019Redis
spring.redis.jedis.pool.max-active
=
200
spring.redis.jedis.pool.max-wait
=
-1
spring.redis.jedis.pool.max-idle
=
10
spring.redis.jedis.pool.min-idle
=
0
spring.redis.timeout
=
1000
# 连接超时时长ms
spring.redis.timeout
=
10000
spring.redis.password
=
# 连接池最大连接数(使用负值表示没有限制)
spring.redis.lettuce.pool.max-active
=
3
# 连接池中的最小空闲连接
spring.redis.lettuce.pool.min-idle
=
2
# 连接池中的最大空闲连接
spring.redis.lettuce.pool.max-idle
=
3
# 连接池最大阻塞等待时间(使用负值表示没有限制)
spring.redis.lettuce.pool.max-wait
=
-1
#在关闭客户端连接之前等待任务处理完成的最长时间,在这之后,无论任务是否执行完成,都会被执行器关闭,默认100ms
spring.redis.lettuce.shutdown-timeout
=
100
#单机集群判断 cluster集群 single单机
spring.redis.mode
=
cluster
#redis 单机配置
#spring.redis.host=172.16.11.20
#spring.redis.port=6379
#集群配置
spring.redis.cluster.nodes
=
172.16.3.41:6381,172.16.3.41:6002
spring.redis.cluster.max-redirects
=
3
spring.redis.cluster.scan-interval
=
1000
spring.redis.cluster.read-mode
=
SLAVE
spring.redis.cluster.retry-attempts
=
3
spring.redis.cluster.failed-attempts
=
3
spring.redis.cluster.slave-connection-pool-size
=
64
spring.redis.cluster.master-connection-pool-size
=
64
spring.redis.cluster.retry-interval
=
1500
#picture upload
windows.img.path
=
C:
\\
linux.img.path
=
/
...
...
amos-boot-system-fas/src/main/resources/application-single.properties
0 → 100644
View file @
9b44cc39
#DB properties:
spring.datasource.url
=
jdbc:mysql://172.16.10.66:3306/safety-business-3.0.1?allowMultiQueries=true&serverTimezone=GMT%2B8&characterEncoding=utf8
spring.datasource.username
=
root
spring.datasource.password
=
root_123
spring.datasource.driver-class-name
=
com.mysql.cj.jdbc.Driver
spring.datasource.hikari.maxLifetime
=
1765000
spring.datasource.hikari.maximum-pool-size
=
10
spring.datasource.testWhileIdle
=
true
spring.datasource.validationQuery
=
SELECT 1
#系统服务账号,用户后端服务调用
#security.password=a1234560
#security.loginId=fas_autosys
#
##应用product appkey
#security.productWeb=STUDIO_APP_WEB
#security.appKey =studio_normalapp_2681691
#security.password=a1234560
#security.loginId=fas_autosys
##应用product appkey
#security.productWeb=STUDIO_APP_WEB
#security.appKey =studio_normalapp_2681691
amos.system.user.user-name
=
fas_autosys
amos.system.user.password
=
a1234560
amos.system.user.app-key
=
studio_normalapp_2681691
amos.system.user.product
=
AMOS_STUDIO_WEB
eureka.client.serviceUrl.defaultZone
=
http://172.16.10.72:10001/eureka/
eureka.client.registry-fetch-interval-seconds
=
5
eureka.instance.prefer-ip-address
=
true
eureka.instance.health-check-url-path
=
/actuator/health
eureka.instance.lease-expiration-duration-in-seconds
=
10
eureka.instance.lease-renewal-interval-in-seconds
=
5
eureka.instance.metadata-map.management.context-path
=
${server.servlet.context-path}/actuator
eureka.instance.status-page-url-path
=
/actuator/info
eureka.instance.metadata-map.management.api-docs
=
http://localhost:${server.port}${server.servlet.context-path}/doc.html
#redis
spring.redis.database
=
0
spring.redis.host
=
172.16.10.85
spring.redis.port
=
6379
spring.redis.password
=
amos2019Redis
spring.redis.jedis.pool.max-active
=
200
spring.redis.jedis.pool.max-wait
=
-1
spring.redis.jedis.pool.max-idle
=
10
spring.redis.jedis.pool.min-idle
=
0
spring.redis.timeout
=
1000
spring.redis.mode
=
single
#picture upload
windows.img.path
=
C:
\\
linux.img.path
=
/
file.uploadUrl
=
C:
\\
upload
\\
files
\\
#picture read
file.readUrl
=
http://172.16.11.33:8085/file/getFile?in=
#jpush 推送开关
params.isPush
=
false
## emqx
emqx.clean-session
=
true
emqx.client-id
=
${spring.application.name}-${random.int[1024,65536]}
emqx.broker
=
tcp://172.16.10.211:2883
emqx.client-user-name
=
super
emqx.client-password
=
a123456
emqx.max-inflight
=
1000
emqx.keep-alive-interval
=
10
#文件服务器地址
file.url
=
http://39.98.45.134:9000/
amos-boot-system-jcs/src/main/resources/db/changelog/jcs-1.0.0.0.xml
View file @
9b44cc39
...
...
@@ -3614,6 +3614,21 @@
</sql>
</changeSet>
<changeSet
author=
"cz"
id=
"2022-10-09-02"
>
<preConditions
onFail=
"MARK_RAN"
>
<tableExists
tableName=
"cb_data_dictionary"
/>
<not>
<primaryKeyExists
primaryKeyName=
"sequence_nbr"
tableName=
"cb_data_dictionary"
/>
</not>
</preConditions>
<comment>
add data cb_data_dictionary
</comment>
<sql>
ALTER TABLE `cb_fire_station`
MODIFY COLUMN `person_charge_name` varchar(60) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '负责人名称' AFTER `duty_room_telephone`
</sql>
</changeSet>
</databaseChangeLog>
...
...
amos-boot-system-latentdanger/src/main/resources/application.properties
View file @
9b44cc39
...
...
@@ -44,6 +44,8 @@ Push.fegin.name=APPMESSAGEPUSHSERVICE
amos.flowWork.topic
=
/STATE_GRID/hazardManagement
amosRefresh.danger.topic
=
patrolDangerInsertOrUpdate
amosRefresh.patrol.topic
=
patrolCheckInsert
#停止通过WEB公开所有端点
#management.endpoints.web.exposure.exclude=*
## redis失效时间
redis.cache.failure.time
=
10800
...
...
@@ -79,3 +81,4 @@ spring.boot.admin.client.username=admin
spring.boot.admin.client.password
=
a1234560
management.security.enabled
=
false
management.endpoints.web.exposure.include
=
*
personAgencyCode
=
STATE_GRID
\ No newline at end of file
amos-boot-system-patrol/src/main/resources/db/mapper/dbTemplate_plan_task.xml
View file @
9b44cc39
...
...
@@ -124,7 +124,7 @@
and (a.org_Code like concat (#{orgCode},"-%")or a.org_Code= #{orgCode})
</if>
</where>
order by b.id
order by b.id
DESC
<choose>
<when
test=
"pageSize==-1"
></when>
<when
test=
"pageSize!=-1"
>
limit #{offset},#{pageSize}
</when>
...
...
amos-boot-utils/amos-boot-utils-jpush/src/main/java/com/yeejoin/amos/jpush/config/WebSecurityConfig.java
deleted
100644 → 0
View file @
149e6316
package
com
.
yeejoin
.
amos
.
jpush
.
config
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
import
org.springframework.security.config.annotation.web.builders.HttpSecurity
;
import
org.springframework.security.config.annotation.web.configuration.EnableWebSecurity
;
import
org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter
;
import
org.springframework.security.web.firewall.DefaultHttpFirewall
;
import
org.springframework.security.web.firewall.HttpFirewall
;
@Configuration
@EnableWebSecurity
public
class
WebSecurityConfig
extends
WebSecurityConfigurerAdapter
{
// 授权
@Override
protected
void
configure
(
HttpSecurity
http
)
throws
Exception
{
http
.
csrf
().
disable
()
.
headers
()
.
frameOptions
()
.
disable
()
.
and
()
.
authorizeRequests
()
.
regexMatchers
(
"^(?!/actuator).*$"
).
permitAll
()
.
regexMatchers
(
"/actuator/health"
).
permitAll
()
.
regexMatchers
(
"/actuator/info"
).
permitAll
()
.
anyRequest
().
authenticated
().
and
()
.
formLogin
();
}
@Bean
public
HttpFirewall
httpFirewall
()
{
return
new
DefaultHttpFirewall
();
}
}
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment