diff --git a/.idea/runConfigurations/CodeGet.xml b/.idea/runConfigurations/CodeGet.xml
deleted file mode 100644
index 3add11c..0000000
--- a/.idea/runConfigurations/CodeGet.xml
+++ /dev/null
@@ -1,15 +0,0 @@
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
\ No newline at end of file
diff --git a/.idea/ssyx.iml b/.idea/ssyx.iml
index d6ebd48..2e367e6 100644
--- a/.idea/ssyx.iml
+++ b/.idea/ssyx.iml
@@ -5,5 +5,6 @@
+
\ No newline at end of file
diff --git a/atguigu-tuan/pages/login/login.vue b/atguigu-tuan/pages/login/login.vue
index 8955d6e..fc3a214 100644
--- a/atguigu-tuan/pages/login/login.vue
+++ b/atguigu-tuan/pages/login/login.vue
@@ -17,7 +17,7 @@
登录代表同意
- 硅谷团购平台用户协议、隐私政策,
+ 硅谷平台用户协议、隐私政策,
并授权使用您的硅谷团购平台账号信息(如昵称、头像、收获地址)以便您统一管理
diff --git a/atguigu-tuan/unpackage/dist/dev/mp-weixin/pages/login/login.wxml b/atguigu-tuan/unpackage/dist/dev/mp-weixin/pages/login/login.wxml
index 2fce37a..6119a4d 100644
--- a/atguigu-tuan/unpackage/dist/dev/mp-weixin/pages/login/login.wxml
+++ b/atguigu-tuan/unpackage/dist/dev/mp-weixin/pages/login/login.wxml
@@ -1 +1 @@
-欢迎登陆硅谷团购平台登录代表同意硅谷团购平台用户协议、隐私政策,并授权使用您的硅谷团购平台账号信息(如昵称、头像、收获地址)以便您统一管理
\ No newline at end of file
+欢迎登陆硅谷团购平台登录代表同意硅谷平台用户协议、隐私政策,并授权使用您的硅谷团购平台账号信息(如昵称、头像、收获地址)以便您统一管理
\ No newline at end of file
diff --git a/guigu-ssyx-parent/pom.xml b/guigu-ssyx-parent/pom.xml
index 5664174..8ec6cc1 100644
--- a/guigu-ssyx-parent/pom.xml
+++ b/guigu-ssyx-parent/pom.xml
@@ -41,7 +41,6 @@
8
8
UTF-8
-
diff --git a/guigu-ssyx-parent/service-gateway/Dockerfile b/guigu-ssyx-parent/service-gateway/Dockerfile
index 1f8baec..be6151b 100644
--- a/guigu-ssyx-parent/service-gateway/Dockerfile
+++ b/guigu-ssyx-parent/service-gateway/Dockerfile
@@ -3,3 +3,4 @@ LABEL authors="yovinchen"
VOLUME /tmp
ADD ./target/service-gateway.jar service-gateway.jar
ENTRYPOINT ["java","-jar","/service-gateway.jar", "&"]
+
diff --git a/guigu-ssyx-parent/service-gateway/pom.xml b/guigu-ssyx-parent/service-gateway/pom.xml
index 64c6102..8f4abd9 100644
--- a/guigu-ssyx-parent/service-gateway/pom.xml
+++ b/guigu-ssyx-parent/service-gateway/pom.xml
@@ -22,6 +22,10 @@
com.alibaba.cloud
spring-cloud-starter-alibaba-nacos-discovery
+
+ com.alibaba.cloud
+ spring-cloud-starter-alibaba-nacos-config
+
org.springframework.cloud
spring-cloud-starter-gateway
diff --git a/guigu-ssyx-parent/service-gateway/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service-gateway/src/main/resources/application-dev.yml
deleted file mode 100644
index 333ce1e..0000000
--- a/guigu-ssyx-parent/service-gateway/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,59 +0,0 @@
-server:
- port: 8200
-
-spring:
- cloud:
- gateway:
- discovery:
- locator:
- enabled: true
- routes:
- - id: service-acl
- uri: lb://service-acl
- predicates:
- - Path=/*/acl/**
-
- - id: service-sys
- uri: lb://service-sys
- predicates:
- - Path=/*/sys/**
-
- - id: service-product
- uri: lb://service-product
- predicates:
- - Path=/*/product/**
-
- - id: service-activity
- uri: lb://service-activity
- predicates:
- - Path=/*/activity/**
-
- - id: service-order
- uri: lb://service-order
- predicates:
- - Path=/*/order/**
-
- - id: service-payment
- uri: lb://service-payment
- predicates:
- - Path=/*/payment/**
-
- - id: service-user
- uri: lb://service-user
- predicates:
- - Path=/*/user/**
-
- - id: service-search
- uri: lb://service-search
- predicates:
- - Path=/*/search/**
-
- - id: service-home
- uri: lb://service-home
- predicates:
- - Path=/*/home/**
-
- - id: service-cart
- uri: lb://service-cart
- predicates:
- - Path=/*/cart/**
diff --git a/guigu-ssyx-parent/service-gateway/src/main/resources/application.yml b/guigu-ssyx-parent/service-gateway/src/main/resources/application.yml
index ff78ad4..9597b0b 100644
--- a/guigu-ssyx-parent/service-gateway/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service-gateway/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8200
spring:
application:
name: service-gateway
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service-gateway/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service-gateway/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..fac6af2
--- /dev/null
+++ b/guigu-ssyx-parent/service-gateway/src/main/resources/bootstrap.yml
@@ -0,0 +1,11 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
diff --git a/guigu-ssyx-parent/service/pom.xml b/guigu-ssyx-parent/service/pom.xml
index 3b3e859..b0e5136 100644
--- a/guigu-ssyx-parent/service/pom.xml
+++ b/guigu-ssyx-parent/service/pom.xml
@@ -69,7 +69,11 @@
com.alibaba.cloud
spring-cloud-starter-alibaba-nacos-discovery
-
+
+
+ com.alibaba.cloud
+ spring-cloud-starter-alibaba-nacos-config
+
org.springframework.cloud
diff --git a/guigu-ssyx-parent/service/service-acl/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-acl/src/main/resources/application-dev.yml
deleted file mode 100644
index c4ffc96..0000000
--- a/guigu-ssyx-parent/service/service-acl/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,32 +0,0 @@
-server:
- port: 8201
-
-mybatis-plus:
- configuration:
- log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
-
-spring:
- datasource:
- type: com.zaxxer.hikari.HikariDataSource
- # driver-class-name: com.mysql.cj.jdbc.Driver
- # url: jdbc:mysql://82.157.68.223:3306/shequ-acl?characterEncoding=utf-8&useSSL=false
- driver-class-name: com.p6spy.engine.spy.P6SpyDriver
- url: jdbc:p6spy:mysql://82.157.68.223:3306/shequ-acl?characterEncoding=utf-8&useSSL=false
- username: shequ-acl
- password: shequ-acl
- redis:
- host: 82.157.68.223
- port: 6379
- database: 0
- timeout: 1800000
- password:
- lettuce:
- pool:
- max-active: 20 #最大连接数
- max-wait: -1 #最大阻塞等待时间(负数表示没限制)
- max-idle: 5 #最大空闲
- min-idle: 0 #最小空闲
-
- jackson:
- date-format: yyyy-MM-dd HH:mm:ss
- time-zone: GMT+8
diff --git a/guigu-ssyx-parent/service/service-acl/src/main/resources/application.yml b/guigu-ssyx-parent/service/service-acl/src/main/resources/application.yml
index e9aa979..6e6bbf5 100644
--- a/guigu-ssyx-parent/service/service-acl/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service/service-acl/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8201
spring:
application:
name: service-acl
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service/service-acl/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service/service-acl/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..eed9a13
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-acl/src/main/resources/bootstrap.yml
@@ -0,0 +1,18 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
+ extension-configs:
+ - data-id: common.yml
+ group: common
+ refresh: true
+ - data-id: service-redis.yml
+ group: common
+ refresh: true
diff --git a/guigu-ssyx-parent/service/service-activity/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-activity/src/main/resources/application-dev.yml
deleted file mode 100644
index 95bf3f1..0000000
--- a/guigu-ssyx-parent/service/service-activity/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,31 +0,0 @@
-server:
- port: 8205
-
-mybatis-plus:
- configuration:
- log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
- type-enums-package: com.atguigu.ssyx.enums
-
-spring:
- datasource:
- type: com.zaxxer.hikari.HikariDataSource
- driver-class-name: com.mysql.cj.jdbc.Driver
- url: jdbc:mysql://82.157.68.223:3306/shequ-activity?characterEncoding=utf-8&useSSL=false
- username: shequ-activity
- password: shequ-activity
- redis:
- host: 82.157.68.223
- port: 6379
- database: 0
- timeout: 1800000
- password:
- lettuce:
- pool:
- max-active: 20 #最大连接数
- max-wait: -1 #最大阻塞等待时间(负数表示没限制)
- max-idle: 5 #最大空闲
- min-idle: 0 #最小空闲
-
- jackson:
- date-format: yyyy-MM-dd HH:mm:ss
- time-zone: GMT+8
diff --git a/guigu-ssyx-parent/service/service-activity/src/main/resources/application.yml b/guigu-ssyx-parent/service/service-activity/src/main/resources/application.yml
index fdddbd1..c31e798 100644
--- a/guigu-ssyx-parent/service/service-activity/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service/service-activity/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8205
spring:
application:
name: service-activity
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service/service-activity/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service/service-activity/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..eed9a13
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-activity/src/main/resources/bootstrap.yml
@@ -0,0 +1,18 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
+ extension-configs:
+ - data-id: common.yml
+ group: common
+ refresh: true
+ - data-id: service-redis.yml
+ group: common
+ refresh: true
diff --git a/guigu-ssyx-parent/service/service-cart/Dockerfile b/guigu-ssyx-parent/service/service-cart/Dockerfile
index 9264976..ae01fcb 100644
--- a/guigu-ssyx-parent/service/service-cart/Dockerfile
+++ b/guigu-ssyx-parent/service/service-cart/Dockerfile
@@ -1,5 +1,5 @@
FROM openjdk:8-jdk-alpine
LABEL authors="yovinchen"
VOLUME /tmp
-ADD ./target/service-activity.jar service-cart.jar
+ADD ./target/service-cart.jar service-cart.jar
ENTRYPOINT ["java","-jar","/service-cart.jar", "&"]
diff --git a/guigu-ssyx-parent/service/service-cart/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-cart/src/main/resources/application-dev.yml
deleted file mode 100644
index bd43581..0000000
--- a/guigu-ssyx-parent/service/service-cart/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,34 +0,0 @@
-server:
- port: 8208
-
-feign:
- sentinel:
- enabled: true
- client:
- config:
- default: #配置全局的feign的调用超时时间 如果 有指定的服务配置 默认的配置不会生效
- connectTimeout: 30000 # 指定的是 消费者 连接服务提供者的连接超时时间 是否能连接 单位是毫秒
- readTimeout: 50000 # 指定的是调用服务提供者的 服务 的超时时间() 单位是毫秒
-spring:
- main:
- allow-bean-definition-overriding: true #当遇到同样名字的时候,是否允许覆盖注册
- rabbitmq:
- host: 43.143.164.194
- port: 5672
- username: guest
- password: guest
- redis:
- host: 82.157.68.223
- port: 6379
- database: 0
- timeout: 1800000
- password:
- lettuce:
- pool:
- max-active: 20 #最大连接数
- max-wait: -1 #最大阻塞等待时间(负数表示没限制)
- max-idle: 5 #最大空闲
- min-idle: 0 #最小空闲
- jackson:
- date-format: yyyy-MM-dd HH:mm:ss
- time-zone: GMT+8
diff --git a/guigu-ssyx-parent/service/service-cart/src/main/resources/application.yml b/guigu-ssyx-parent/service/service-cart/src/main/resources/application.yml
index 6321d93..22f4a1d 100644
--- a/guigu-ssyx-parent/service/service-cart/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service/service-cart/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8208
spring:
application:
name: service-cart
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service/service-cart/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service/service-cart/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..07666a8
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-cart/src/main/resources/bootstrap.yml
@@ -0,0 +1,24 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
+ extension-configs:
+ - data-id: common.yml
+ group: common
+ refresh: true
+ - data-id: service-redis.yml
+ group: common
+ refresh: true
+ - data-id: service-rabbitmq.yml
+ group: common
+ refresh: true
+ - data-id: service-openfeign.yml
+ group: common
+ refresh: true
diff --git a/guigu-ssyx-parent/service/service-home/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-home/src/main/resources/application-dev.yml
deleted file mode 100644
index 5534117..0000000
--- a/guigu-ssyx-parent/service/service-home/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,35 +0,0 @@
-server:
- port: 8207
-
-feign:
- sentinel:
- enabled: true
- client:
- config:
- default: #配置全局的feign的调用超时时间 如果 有指定的服务配置 默认的配置不会生效
- connectTimeout: 50000 # 指定的是 消费者 连接服务提供者的连接超时时间 是否能连接 单位是毫秒
- readTimeout: 50000 # 指定的是调用服务提供者的 服务 的超时时间() 单位是毫秒
-
-mybatis-plus:
- configuration:
- log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
- type-enums-package: com.atguigu.ssyx.enums
-
-spring:
- main:
- allow-bean-definition-overriding: true #当遇到同样名字的时候,是否允许覆盖注册
- jackson:
- date-format: yyyy-MM-dd HH:mm:ss
- time-zone: GMT+8
- redis:
- host: 82.157.68.223
- port: 6379
- database: 0
- timeout: 1800000
- password:
- lettuce:
- pool:
- max-active: 20 #最大连接数
- max-wait: -1 #最大阻塞等待时间(负数表示没限制)
- max-idle: 5 #最大空闲
- min-idle: 0 #最小空闲
diff --git a/guigu-ssyx-parent/service/service-home/src/main/resources/application.yml b/guigu-ssyx-parent/service/service-home/src/main/resources/application.yml
index 73bf414..49e3808 100644
--- a/guigu-ssyx-parent/service/service-home/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service/service-home/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8207
spring:
application:
name: service-home
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service/service-home/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service/service-home/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..596a1f1
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-home/src/main/resources/bootstrap.yml
@@ -0,0 +1,21 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
+ extension-configs:
+ - data-id: common.yml
+ group: common
+ refresh: true
+ - data-id: service-redis.yml
+ group: common
+ refresh: true
+ - data-id: service-openfeign.yml
+ group: common
+ refresh: true
diff --git a/guigu-ssyx-parent/service/service-order/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-order/src/main/resources/application-dev.yml
deleted file mode 100644
index ec3aa2a..0000000
--- a/guigu-ssyx-parent/service/service-order/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,52 +0,0 @@
-server:
- port: 8209
-mybatis-plus:
- type-enums-package: com.atguigu.ssyx.enums
- configuration:
- log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
- mapper-locations: classpath:mapper/*.xml
-feign:
- sentinel:
- enabled: true
- client:
- config:
- default: #配置全局的feign的调用超时时间 如果 有指定的服务配置 默认的配置不会生效
- connectTimeout: 30000 # 指定的是 消费者 连接服务提供者的连接超时时间 是否能连接 单位是毫秒
- readTimeout: 50000 # 指定的是调用服务提供者的 服务 的超时时间() 单位是毫秒
-spring:
- main:
- allow-bean-definition-overriding: true #当遇到同样名字的时候,是否允许覆盖注册
- rabbitmq:
- host: 43.143.164.194
- port: 5672
- username: guest
- password: guest
- redis:
- host: 82.157.68.223
- port: 6379
- database: 0
- timeout: 1800000
- password:
- lettuce:
- pool:
- max-active: 20 #最大连接数
- max-wait: -1 #最大阻塞等待时间(负数表示没限制)
- max-idle: 5 #最大空闲
- min-idle: 0 #最小空闲
- datasource:
- type: com.zaxxer.hikari.HikariDataSource
- driver-class-name: com.mysql.cj.jdbc.Driver
- url: jdbc:mysql://82.157.68.223:3306/shequ-order?characterEncoding=utf-8&useSSL=false
- username: shequ-order
- password: shequ-order
- hikari:
- connection-test-query: SELECT 1
- connection-timeout: 60000
- idle-timeout: 500000
- max-lifetime: 540000
- maximum-pool-size: 5
- minimum-idle: 3
- pool-name: GuliHikariPool
- jackson:
- date-format: yyyy-MM-dd HH:mm:ss
- time-zone: GMT+8
diff --git a/guigu-ssyx-parent/service/service-order/src/main/resources/application.yml b/guigu-ssyx-parent/service/service-order/src/main/resources/application.yml
index 46a4b81..a6b4fc2 100644
--- a/guigu-ssyx-parent/service/service-order/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service/service-order/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8209
spring:
application:
name: service-order
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service/service-order/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service/service-order/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..07666a8
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-order/src/main/resources/bootstrap.yml
@@ -0,0 +1,24 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
+ extension-configs:
+ - data-id: common.yml
+ group: common
+ refresh: true
+ - data-id: service-redis.yml
+ group: common
+ refresh: true
+ - data-id: service-rabbitmq.yml
+ group: common
+ refresh: true
+ - data-id: service-openfeign.yml
+ group: common
+ refresh: true
diff --git a/guigu-ssyx-parent/service/service-payment/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-payment/src/main/resources/application-dev.yml
deleted file mode 100644
index d91db2f..0000000
--- a/guigu-ssyx-parent/service/service-payment/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,60 +0,0 @@
-server:
- port: 8210
-mybatis-plus:
- type-enums-package: com.atguigu.ssyx.enums
- configuration:
- log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
- mapper-locations: classpath:mapper/*.xml
-feign:
- sentinel:
- enabled: true
- client:
- config:
- default: #配置全局的feign的调用超时时间 如果 有指定的服务配置 默认的配置不会生效
- connectTimeout: 30000 # 指定的是 消费者 连接服务提供者的连接超时时间 是否能连接 单位是毫秒
- readTimeout: 50000 # 指定的是调用服务提供者的 服务 的超时时间() 单位是毫秒
-spring:
- main:
- allow-bean-definition-overriding: true #当遇到同样名字的时候,是否允许覆盖注册
- rabbitmq:
- host: 43.143.164.194
- port: 5672
- username: guest
- password: guest
- redis:
- host: 82.157.68.223
- port: 6379
- database: 0
- timeout: 1800000
- password:
- lettuce:
- pool:
- max-active: 20 #最大连接数
- max-wait: -1 #最大阻塞等待时间(负数表示没限制)
- max-idle: 5 #最大空闲
- min-idle: 0 #最小空闲
- datasource:
- type: com.zaxxer.hikari.HikariDataSource
- driver-class-name: com.mysql.cj.jdbc.Driver
- url: jdbc:mysql://82.157.68.223:3306/shequ-order?characterEncoding=utf-8&useSSL=false
- username: shequ-order
- password: shequ-order
- hikari:
- connection-test-query: SELECT 1
- connection-timeout: 60000
- idle-timeout: 500000
- max-lifetime: 540000
- maximum-pool-size: 5
- minimum-idle: 3
- pool-name: GuliHikariPool
- jackson:
- date-format: yyyy-MM-dd HH:mm:ss
- time-zone: GMT+8
-# 微信
-weixin:
- #小程序微信公众平台appId
- appid: wxcc651fcbab275e33
- partner: 1481962542
- partnerkey: MXb72b9RfshXZD4FRGV5KLqmv5bx9LT9
- notifyurl: http://gmall-prod.atguigu.cn/api/payment/weixin/notify
- cert: /Users/yovinchen/project/Java/ssyx/guigu-ssyx-parent/service/service-payment/src/main/resources/cert/apiclient_cert.p12
diff --git a/guigu-ssyx-parent/service/service-payment/src/main/resources/application.yml b/guigu-ssyx-parent/service/service-payment/src/main/resources/application.yml
index ec33dce..f09300b 100644
--- a/guigu-ssyx-parent/service/service-payment/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service/service-payment/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8210
spring:
application:
name: service-payment
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service/service-payment/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service/service-payment/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..07666a8
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-payment/src/main/resources/bootstrap.yml
@@ -0,0 +1,24 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
+ extension-configs:
+ - data-id: common.yml
+ group: common
+ refresh: true
+ - data-id: service-redis.yml
+ group: common
+ refresh: true
+ - data-id: service-rabbitmq.yml
+ group: common
+ refresh: true
+ - data-id: service-openfeign.yml
+ group: common
+ refresh: true
diff --git a/guigu-ssyx-parent/service/service-product/pom.xml b/guigu-ssyx-parent/service/service-product/pom.xml
index 2d8c6c5..0abe12a 100644
--- a/guigu-ssyx-parent/service/service-product/pom.xml
+++ b/guigu-ssyx-parent/service/service-product/pom.xml
@@ -11,6 +11,24 @@
service-product
+
+
+
+ com.squareup.okhttp3
+ okhttp
+ 4.9.0
+
+
+ io.minio
+ minio
+ 8.5.6
+
+
+ okhttp
+ com.squareup.okhttp3
+
+
+
com.aliyun.oss
diff --git a/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/mapper/SkuInfoMapper.java b/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/mapper/SkuInfoMapper.java
index 4064870..ea91f18 100644
--- a/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/mapper/SkuInfoMapper.java
+++ b/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/mapper/SkuInfoMapper.java
@@ -40,7 +40,7 @@ public interface SkuInfoMapper extends BaseMapper {
*/
void unlockStock(@Param("skuId") Long skuId, @Param("skuNum") Integer skuNum);
- /**
+ /**z
* 减库存
*
* @param skuId
diff --git a/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/service/impl/FileUploadServiceImpl.java b/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/service/impl/FileUploadServiceImpl.java
index 0b980f9..f9112fe 100644
--- a/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/service/impl/FileUploadServiceImpl.java
+++ b/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/service/impl/FileUploadServiceImpl.java
@@ -1,8 +1,7 @@
package com.atguigu.ssyx.product.service.impl;
-import com.aliyun.oss.OSS;
-import com.aliyun.oss.OSSClientBuilder;
import com.atguigu.ssyx.product.service.FileUploadService;
+import io.minio.MinioClient;
import org.joda.time.DateTime;
import org.springframework.beans.factory.annotation.Value;
import org.springframework.stereotype.Service;
@@ -35,7 +34,12 @@ public class FileUploadServiceImpl implements FileUploadService {
public String fileUpload(MultipartFile file) throws Exception {
try {
// 创建OSSClient实例。
- OSS ossClient = new OSSClientBuilder().build(endPoint, accessKey, secreKey);
+// OSS ossClient = new OSSClientBuilder().build(endPoint, accessKey, secreKey);
+ MinioClient minioClient =
+ MinioClient.builder()
+ .endpoint("https://play.min.io")
+ .credentials("Q3AM3UQ867SPQQA43P2F", "zuf+tfteSlswRu7BJ86wekitnifILbZam1KYY3TG")
+ .build();
// 上传文件流。
InputStream inputStream = file.getInputStream();
String fileName = file.getOriginalFilename();
@@ -50,9 +54,9 @@ public class FileUploadServiceImpl implements FileUploadService {
String timeUrl = new DateTime().toString("yyyy/MM/dd");
fileName = timeUrl + "/" + fileName;
//调用方法实现上传
- ossClient.putObject(bucketName, fileName, inputStream);
+// ossClient.putObject(bucketName, fileName, inputStream);
// 关闭OSSClient。
- ossClient.shutdown();
+// ossClient.shutdown();
//上传之后文件路径
String url = "https://" + bucketName + "." + endPoint + "/" + fileName;
//返回
diff --git a/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/utils/FileUploader.java b/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/utils/FileUploader.java
new file mode 100644
index 0000000..a150257
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-product/src/main/java/com/atguigu/ssyx/product/utils/FileUploader.java
@@ -0,0 +1,45 @@
+package com.atguigu.ssyx.product.utils;
+
+import io.minio.BucketExistsArgs;
+import io.minio.MakeBucketArgs;
+import io.minio.MinioClient;
+import io.minio.UploadObjectArgs;
+import io.minio.errors.MinioException;
+
+import java.io.IOException;
+import java.security.InvalidKeyException;
+import java.security.NoSuchAlgorithmException;
+
+/**
+ * ClassName: FileUploader
+ * Package: com.atguigu.ssyx.product.utils
+ *
+ * @author yovinchen
+ * @Create 2023/10/13 17:55
+ */
+public class FileUploader {
+
+ public static void main(String[] args) throws IOException, NoSuchAlgorithmException, InvalidKeyException {
+ try {
+ // Create a minioClient with the MinIO server playground, its access key and secret key.
+ MinioClient minioClient = MinioClient.builder().endpoint("http://154.9.228.206:9000").credentials("IaZk6fqBYY66dcE03edv", "6zzVxP6wAuu74Tft22JJZDQGVfnaHtJ221XjAwQu").build();
+
+ // Make 'asiatrip' bucket if not exist.
+ boolean found = minioClient.bucketExists(BucketExistsArgs.builder().bucket("public").build());
+ if (!found) {
+ // Make a new bucket called 'asiatrip'.
+ minioClient.makeBucket(MakeBucketArgs.builder().bucket("public").build());
+ } else {
+ System.out.println("Bucket 'public' already exists.");
+ }
+
+ // Upload '/home/user/Photos/asiaphotos.zip' as object name 'asiaphotos-2015.zip' to bucket
+ // 'asiatrip'.
+ minioClient.uploadObject(UploadObjectArgs.builder().bucket("public").object("credentials.json").filename("C:/Users/lai.huanxiong/Downloads/credentials.json").build());
+ System.out.println("'C:/Users/lai.huanxiong/Downloads/credentials.json' is successfully uploaded as " + "object 'credentials.json' to bucket 'public'.");
+ } catch (MinioException e) {
+ System.out.println("Error occurred: " + e);
+ System.out.println("HTTP trace: " + e.httpTrace());
+ }
+ }
+}
diff --git a/guigu-ssyx-parent/service/service-product/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-product/src/main/resources/application-dev.yml
deleted file mode 100644
index eced426..0000000
--- a/guigu-ssyx-parent/service/service-product/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,48 +0,0 @@
-server:
- port: 8203
-
-mybatis-plus:
- configuration:
- log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
- type-enums-package: com.atguigu.ssyx.enums
-spring:
- datasource:
- type: com.zaxxer.hikari.HikariDataSource
- driver-class-name: com.mysql.cj.jdbc.Driver
- url: jdbc:mysql://82.157.68.223:3306/shequ-product?characterEncoding=utf-8&useSSL=false
- username: shequ-product
- password: shequ-product
- rabbitmq:
- host: 43.143.164.194
- port: 5672
- username: guest
- password: guest
- publisher-confirm-type: CORRELATED #发布确认模式,消息是否被成功发送到交换机
- publisher-returns: true
- listener:
- simple:
- prefetch: 1
- concurrency: 3
- acknowledge-mode: manual #消费端手动确认
- redis:
- host: 82.157.68.223
- port: 6379
- database: 0
- timeout: 1800000
- password:
- lettuce:
- pool:
- max-active: 20 #最大连接数
- max-wait: -1 #最大阻塞等待时间(负数表示没限制)
- max-idle: 5 #最大空闲
- min-idle: 0 #最小空闲
- jackson:
- date-format: yyyy-MM-dd HH:mm:ss
- time-zone: GMT+8
-
-aliyun:
- endpoint: oss-cn-beijing.aliyuncs.com
- keyid: LTAI5tHWGPq6o62dMMV1hn1i
- keysecret: FyUK59nlI0bf1MFHLuEvtBwXl2CJjA
- bucketname: ssyx-yovinchen
-
diff --git a/guigu-ssyx-parent/service/service-product/src/main/resources/application.yml b/guigu-ssyx-parent/service/service-product/src/main/resources/application.yml
index 21199d2..811dd96 100644
--- a/guigu-ssyx-parent/service/service-product/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service/service-product/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8203
spring:
application:
name: service-product
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service/service-product/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service/service-product/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..3383cdb
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-product/src/main/resources/bootstrap.yml
@@ -0,0 +1,31 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
+ extension-configs:
+ - data-id: common.yml
+ group: common
+ refresh: true
+ - data-id: service-redis.yml
+ group: common
+ refresh: true
+ - data-id: service-rabbitmq.yml
+ group: common
+ refresh: true
+ - data-id: config-rabbitmq.yml
+ group: config
+ refresh: true
+ - data-id: service-openfeign.yml
+ group: common
+ refresh: true
+ - data-id: oss-aliyun.yml
+ group: oss
+ refresh: true
+
diff --git a/guigu-ssyx-parent/service/service-search/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-search/src/main/resources/application-dev.yml
deleted file mode 100644
index 7811d78..0000000
--- a/guigu-ssyx-parent/service/service-search/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,41 +0,0 @@
-server:
- port: 8204
-feign:
- sentinel:
- enabled: true
- client:
- config:
- default: #配置全局的feign的调用超时时间 如果 有指定的服务配置 默认的配置不会生效
- connectTimeout: 30000 # 指定的是 消费者 连接服务提供者的连接超时时间 是否能连接 单位是毫秒
- readTimeout: 50000 # 指定的是调用服务提供者的 服务 的超时时间() 单位是毫秒
-spring:
- main:
- allow-bean-definition-overriding: true #当遇到同样名字的时候,是否允许覆盖注册
- elasticsearch:
- rest:
- uris: http://43.143.164.194:9200
- rabbitmq:
- host: 43.143.164.194
- port: 5672
- username: guest
- password: guest
- publisher-confirm-type: CORRELATED #发布确认模式,消息是否被成功发送到交换机
- publisher-returns: true
- listener:
- simple:
- prefetch: 1
- concurrency: 3
- acknowledge-mode: manual #消费端手动确认
-
- redis:
- host: 82.157.68.223
- port: 6379
- database: 0
- timeout: 1800000
- password:
- lettuce:
- pool:
- max-active: 20 #最大连接数
- max-wait: -1 #最大阻塞等待时间(负数表示没限制)
- max-idle: 5 #最大空闲
- min-idle: 0 #最小空闲
diff --git a/guigu-ssyx-parent/service/service-search/src/main/resources/application.yml b/guigu-ssyx-parent/service/service-search/src/main/resources/application.yml
index 14b72c5..5ab71bc 100644
--- a/guigu-ssyx-parent/service/service-search/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service/service-search/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8204
spring:
application:
name: service-search
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service/service-search/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service/service-search/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..10a63fb
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-search/src/main/resources/bootstrap.yml
@@ -0,0 +1,31 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
+ extension-configs:
+ - data-id: common.yml
+ group: common
+ refresh: true
+ - data-id: service-redis.yml
+ group: common
+ refresh: true
+ - data-id: service-rabbitmq.yml
+ group: common
+ refresh: true
+ - data-id: config-rabbitmq.yml
+ group: config
+ refresh: true
+ - data-id: service-openfeign.yml
+ group: common
+ refresh: true
+ - data-id: service-elasticsearch.yml
+ group: common
+ refresh: true
+
diff --git a/guigu-ssyx-parent/service/service-sys/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-sys/src/main/resources/application-dev.yml
deleted file mode 100644
index 817b6d1..0000000
--- a/guigu-ssyx-parent/service/service-sys/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,30 +0,0 @@
-server:
- port: 8202
-
-mybatis-plus:
- configuration:
- log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
-
-spring:
- datasource:
- type: com.zaxxer.hikari.HikariDataSource
- driver-class-name: com.mysql.cj.jdbc.Driver
- url: jdbc:mysql://82.157.68.223:3306/shequ-sys?characterEncoding=utf-8&useSSL=false
- username: shequ-sys
- password: shequ-sys
- redis:
- host: 82.157.68.223
- port: 6379
- database: 0
- timeout: 1800000
- password:
- lettuce:
- pool:
- max-active: 20 #最大连接数
- max-wait: -1 #最大阻塞等待时间(负数表示没限制)
- max-idle: 5 #最大空闲
- min-idle: 0 #最小空闲
- jackson:
- date-format: yyyy-MM-dd HH:mm:ss
- time-zone: GMT+8
-
diff --git a/guigu-ssyx-parent/service/service-sys/src/main/resources/application.yml b/guigu-ssyx-parent/service/service-sys/src/main/resources/application.yml
index 2bafd13..53b9d8b 100644
--- a/guigu-ssyx-parent/service/service-sys/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service/service-sys/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8202
spring:
application:
name: service-sys
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service/service-sys/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service/service-sys/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..eed9a13
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-sys/src/main/resources/bootstrap.yml
@@ -0,0 +1,18 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
+ extension-configs:
+ - data-id: common.yml
+ group: common
+ refresh: true
+ - data-id: service-redis.yml
+ group: common
+ refresh: true
diff --git a/guigu-ssyx-parent/service/service-user/src/main/resources/application-dev.yml b/guigu-ssyx-parent/service/service-user/src/main/resources/application-dev.yml
deleted file mode 100644
index 75452c5..0000000
--- a/guigu-ssyx-parent/service/service-user/src/main/resources/application-dev.yml
+++ /dev/null
@@ -1,36 +0,0 @@
-server:
- port: 8206
-
-mybatis-plus:
- configuration:
- log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
- type-enums-package: com.atguigu.ssyx.enums
-
-spring:
- datasource:
- type: com.zaxxer.hikari.HikariDataSource
- driver-class-name: com.mysql.cj.jdbc.Driver
- url: jdbc:mysql://82.157.68.223:3306/shequ-user?characterEncoding=utf-8&useSSL=false
- username: shequ-user
- password: shequ-user
- jackson:
- date-format: yyyy-MM-dd HH:mm:ss
- time-zone: GMT+8
- redis:
- host: 82.157.68.223
- port: 6379
- database: 0
- timeout: 1800000
- password:
- lettuce:
- pool:
- max-active: 20 #最大连接数
- max-wait: -1 #最大阻塞等待时间(负数表示没限制)
- max-idle: 5 #最大空闲
- min-idle: 0 #最小空闲
-wx:
- open:
- # 小程序微信公众平台appId
- app_id: wx2edefe049c6a37b9
- # 小程序微信公众平台api秘钥
- app_secret: 1cb2b7aec97a28f0cdf4b74defa1792a
diff --git a/guigu-ssyx-parent/service/service-user/src/main/resources/application.yml b/guigu-ssyx-parent/service/service-user/src/main/resources/application.yml
index f8cff58..5c949f4 100644
--- a/guigu-ssyx-parent/service/service-user/src/main/resources/application.yml
+++ b/guigu-ssyx-parent/service/service-user/src/main/resources/application.yml
@@ -1,8 +1,8 @@
+server:
+ port: 8206
spring:
application:
name: service-user
- profiles:
- active: dev
cloud:
nacos:
discovery:
diff --git a/guigu-ssyx-parent/service/service-user/src/main/resources/bootstrap.yml b/guigu-ssyx-parent/service/service-user/src/main/resources/bootstrap.yml
new file mode 100644
index 0000000..a619b2f
--- /dev/null
+++ b/guigu-ssyx-parent/service/service-user/src/main/resources/bootstrap.yml
@@ -0,0 +1,21 @@
+spring:
+ cloud:
+ nacos:
+ config:
+ namespace: dd5265c5-8290-45bc-9d07-395c14c977d3
+ server-addr: 82.157.68.223:8848
+ group: service
+ username: nacos
+ password: nacos
+ enabled: true
+ file-extension: yml
+ extension-configs:
+ - data-id: common.yml
+ group: common
+ refresh: true
+ - data-id: service-redis.yml
+ group: common
+ refresh: true
+ - data-id: config-wx.yml
+ group: config
+ refresh: true
diff --git a/ssyx-admin/src/views/login/index.vue b/ssyx-admin/src/views/login/index.vue
index f60a0ca..c9abe1f 100644
--- a/ssyx-admin/src/views/login/index.vue
+++ b/ssyx-admin/src/views/login/index.vue
@@ -10,7 +10,7 @@
>
-
尚上优选平台管理端
+ 购物商城管理端
@@ -66,7 +66,7 @@