Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
spacetech-cloud
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
刘晓滨
spacetech-cloud
Commits
a9644e5d
Commit
a9644e5d
authored
Nov 18, 2020
by
曹志
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
依赖问题修复
parent
f41f41db
Hide whitespace changes
Inline
Side-by-side
Showing
12 changed files
with
184 additions
and
19 deletions
+184
-19
log.txt
log.txt
+0
-0
pom.xml
spacetech-common-util/pom.xml
+1
-0
pom.xml
spacetech-service-api/pom.xml
+13
-0
MemcacheConfig.java
...pi/src/main/java/com/spacetech/config/MemcacheConfig.java
+17
-3
MemcacheProperties.java
...ava/com/spacetech/config/property/MemcacheProperties.java
+115
-0
SystemContext.java
.../src/main/java/com/spacetech/framework/SystemContext.java
+9
-9
ApiHub.java
...rvice-api/src/main/java/com/spacetech/service/ApiHub.java
+2
-2
application.yml
spacetech-service-api/src/main/resources/application.yml
+13
-1
pom.xml
spacetech-service-growth/pom.xml
+6
-2
MemCacheForOnecardUtil.java
.../main/java/com/spacetech/util/MemCacheForOnecardUtil.java
+1
-1
bootstrap.yml
spacetech-service-growth/src/main/resources/bootstrap.yml
+1
-1
pom.xml
spacetech-service-interface/pom.xml
+6
-0
No files found.
log.txt
View file @
a9644e5d
This source diff could not be displayed because it is too large. You can
view the blob
instead.
spacetech-common-util/pom.xml
View file @
a9644e5d
...
...
@@ -174,6 +174,7 @@
<groupId>
ground
</groupId>
<artifactId>
sdk_release_gs1
</artifactId>
<version>
1.51.61
</version>
<optional>
true
</optional>
</dependency>
<!-- nacos-client -->
...
...
spacetech-service-api/pom.xml
View file @
a9644e5d
...
...
@@ -61,6 +61,11 @@
<artifactId>
resteasy-jaxrs
</artifactId>
<version>
3.13.0.Final
</version>
</dependency>
<dependency>
<groupId>
org.jboss.resteasy
</groupId>
<artifactId>
resteasy-client
</artifactId>
<version>
3.13.0.Final
</version>
</dependency>
<!-- tomcat-embed-core -->
<dependency>
<groupId>
org.apache.tomcat.embed
</groupId>
...
...
@@ -74,5 +79,12 @@
<artifactId>
fastjson-jaxrs-json-provider
</artifactId>
<version>
0.3.2
</version>
</dependency>
<!-- SpringBoot配置处理器 -->
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-configuration-processor
</artifactId>
</dependency>
</dependencies>
</project>
\ No newline at end of file
spacetech-service-api/src/main/java/com/spacetech/config/MemcacheConfig.java
View file @
a9644e5d
package
com
.
spacetech
.
config
;
import
com.spacetech.config.property.MemcacheProperties
;
import
com.spacetech.framework.SystemContext
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.boot.context.properties.EnableConfigurationProperties
;
import
org.springframework.context.annotation.Bean
;
import
org.springframework.context.annotation.Configuration
;
...
...
@@ -9,14 +12,25 @@ import org.springframework.context.annotation.Configuration;
* 配置Memcache
*/
@Configuration
@EnableConfigurationProperties
(
MemcacheProperties
.
class
)
public
class
MemcacheConfig
{
@Autowired
private
MemcacheProperties
properties
;
@Bean
(
initMethod
=
"init"
)
public
SystemContext
systemContext
(){
return
new
SystemContext
();
SystemContext
systemContext
=
new
SystemContext
();
systemContext
.
setMemcacheutilIpPort
(
properties
.
getServerAddr
());
systemContext
.
setMemcacheutilUsername
(
properties
.
getUsername
());
systemContext
.
setMemcacheutilPassword
(
properties
.
getPassword
());
systemContext
.
setMemcacheforonecardutilIpPort
(
properties
.
getOneCard
().
getServerAddr
());
systemContext
.
setMemcacheforonecardutilUsername
(
properties
.
getOneCard
().
getUsername
());
systemContext
.
setMemcacheforonecardutilPassword
(
properties
.
getOneCard
().
getPassword
());
systemContext
.
setLocalfileDic
(
properties
.
getLocalfileDic
());
systemContext
.
setLocalfileInternet
(
properties
.
getLocalfileInternet
());
return
systemContext
;
}
}
spacetech-service-api/src/main/java/com/spacetech/config/property/MemcacheProperties.java
0 → 100644
View file @
a9644e5d
package
com
.
spacetech
.
config
.
property
;
import
org.springframework.boot.context.properties.ConfigurationProperties
;
@ConfigurationProperties
(
prefix
=
"memcache"
)
public
class
MemcacheProperties
{
private
String
serverAddr
;
private
String
username
;
private
String
password
;
private
Boolean
internalOss
=
false
;
private
Boolean
saveLocalfile
=
false
;
private
String
localfileDic
=
""
;
private
String
localfileInternet
;
private
OnecardProperties
oneCard
=
new
OnecardProperties
();
public
String
getServerAddr
()
{
return
serverAddr
;
}
public
void
setServerAddr
(
String
serverAddr
)
{
this
.
serverAddr
=
serverAddr
;
}
public
String
getUsername
()
{
return
username
;
}
public
void
setUsername
(
String
username
)
{
this
.
username
=
username
;
}
public
String
getPassword
()
{
return
password
;
}
public
void
setPassword
(
String
password
)
{
this
.
password
=
password
;
}
public
Boolean
getInternalOss
()
{
return
internalOss
;
}
public
void
setInternalOss
(
Boolean
internalOss
)
{
this
.
internalOss
=
internalOss
;
}
public
OnecardProperties
getOneCard
()
{
return
oneCard
;
}
public
void
setOneCard
(
OnecardProperties
oneCard
)
{
this
.
oneCard
=
oneCard
;
}
public
Boolean
getSaveLocalfile
()
{
return
saveLocalfile
;
}
public
void
setSaveLocalfile
(
Boolean
saveLocalfile
)
{
this
.
saveLocalfile
=
saveLocalfile
;
}
public
String
getLocalfileDic
()
{
return
localfileDic
;
}
public
void
setLocalfileDic
(
String
localfileDic
)
{
this
.
localfileDic
=
localfileDic
;
}
public
String
getLocalfileInternet
()
{
return
localfileInternet
;
}
public
void
setLocalfileInternet
(
String
localfileInternet
)
{
this
.
localfileInternet
=
localfileInternet
;
}
public
static
class
OnecardProperties
{
private
String
serverAddr
;
private
String
username
;
private
String
password
;
public
String
getServerAddr
()
{
return
serverAddr
;
}
public
void
setServerAddr
(
String
serverAddr
)
{
this
.
serverAddr
=
serverAddr
;
}
public
String
getUsername
()
{
return
username
;
}
public
void
setUsername
(
String
username
)
{
this
.
username
=
username
;
}
public
String
getPassword
()
{
return
password
;
}
public
void
setPassword
(
String
password
)
{
this
.
password
=
password
;
}
}
}
spacetech-service-api/src/main/java/com/spacetech/framework/SystemContext.java
View file @
a9644e5d
package
com
.
spacetech
.
framework
;
import
java.net.InterfaceAddress
;
import
java.net.NetworkInterface
;
import
java.util.Collections
;
import
java.util.Enumeration
;
import
java.util.List
;
import
com.alibaba.fastjson.JSONObject
;
import
com.spacetech.common.ConstantVar
;
import
com.spacetech.common.utils.FileUtil
;
...
...
@@ -14,6 +8,13 @@ import com.spacetech.provider.ApiProvider;
import
com.spacetech.util.MemCacheForOnecardUtil
;
import
com.spacetech.util.MemCacheUtil
;
import
javax.annotation.PostConstruct
;
import
java.net.InterfaceAddress
;
import
java.net.NetworkInterface
;
import
java.util.Collections
;
import
java.util.Enumeration
;
import
java.util.List
;
/**
*
* @author wm web工程上下文
...
...
@@ -37,6 +38,7 @@ public final class SystemContext {
public
static
String
SERVER_IP_ADDRESS
=
""
;
public
void
init
()
{
// 初始化参数配置
...
...
@@ -48,9 +50,7 @@ public final class SystemContext {
throw
new
RuntimeException
(
"Zookeeper未配置本地存储目录路径"
);
}
FileUtil
.
makeDir
(
localfileDic
);
if
(
saveLocalfile
&&
StringUtil
.
isNullOrEmpty
(
localfileInternet
))
{
throw
new
RuntimeException
(
"Zookeeper未配置本地访问路径"
);
}
baseParams
.
put
(
"saveLocalfile"
,
saveLocalfile
);
baseParams
.
put
(
"localfileDic"
,
localfileDic
);
baseParams
.
put
(
"localfileInternet"
,
localfileInternet
);
...
...
spacetech-service-api/src/main/java/com/spacetech/service/ApiHub.java
View file @
a9644e5d
...
...
@@ -8,7 +8,7 @@ import java.util.Arrays;
import
javax.servlet.http.HttpServletRequest
;
import
javax.servlet.http.HttpServletResponse
;
import
jdk.nashorn.internal.ir.annotations
.Reference
;
import
org.apache.dubbo.config.annotation
.Reference
;
import
org.slf4j.Logger
;
import
org.slf4j.LoggerFactory
;
import
org.springframework.beans.factory.annotation.Autowired
;
...
...
@@ -112,7 +112,7 @@ public class ApiHub {
@Reference
private
TokenApiHub
tokenApiHub
;
@
Reference
@
Autowired
private
ProviderService
providerService
;
@Reference
...
...
spacetech-service-api/src/main/resources/application.yml
View file @
a9644e5d
...
...
@@ -67,6 +67,17 @@ dubbo:
scan
:
base-packages
:
com.spacetech.service
cloud
:
subscribed-services
:
service-growth,service-basedata
subscribed-services
:
'
*'
consumer
:
check
:
false
memcache
:
server-addr
:
10.10.10.190:33332
username
:
spaceplaceholder
password
:
spaceplaceholder
one-card
:
server-addr
:
10.10.10.190:33333
username
:
spaceplaceholder
password
:
spaceplaceholder
internal-oss
:
false
localfile-dic
:
/mnt/work/weixtshare/
localfile-internet
:
http://weixt.spacetech.com.cn:8090/weixtshare/
\ No newline at end of file
spacetech-service-growth/pom.xml
View file @
a9644e5d
...
...
@@ -52,11 +52,15 @@
</exclusions>
</dependency>
-->
<dependency>
<groupId>
org.jboss.resteasy
</groupId>
<artifactId>
resteasy-jaxrs
</artifactId>
<version>
3.13.0.Final
</version>
</dependency>
<dependency>
<groupId>
org.springframework.boot
</groupId>
<artifactId>
spring-boot-starter
-web
</artifactId>
<artifactId>
spring-boot-starter
</artifactId>
</dependency>
<dependency>
...
...
spacetech-service-growth/src/main/java/com/spacetech/util/MemCacheForOnecardUtil.java
View file @
a9644e5d
...
...
@@ -76,7 +76,7 @@ public class MemCacheForOnecardUtil {
/**
* 设置aeskey
*
* @param
aesKey
* @param
*/
public
static
String
getAesKeyDataSafe
()
{
String
result
=
""
;
...
...
spacetech-service-growth/src/main/resources/bootstrap.yml
View file @
a9644e5d
spring
:
application
:
name
:
service-
growth
name
:
growth
cloud
:
nacos
:
# nacos 服务发现
...
...
spacetech-service-interface/pom.xml
View file @
a9644e5d
...
...
@@ -23,6 +23,12 @@
<dependency>
<groupId>
com.alibaba.cloud
</groupId>
<artifactId>
spring-cloud-starter-alibaba-nacos-discovery
</artifactId>
<exclusions>
<exclusion>
<groupId>
javax.ws.rs
</groupId>
<artifactId>
jsr311-api
</artifactId>
</exclusion>
</exclusions>
</dependency>
<!--sentinel 流控-->
...
...
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