Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
H
hel-developer-guide
Project
Project
Details
Activity
Releases
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
Spencer Chang
hel-developer-guide
Commits
f3b13c7c
Commit
f3b13c7c
authored
Jul 30, 2017
by
zihao21
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Updates 后端开发/deployment.md
Auto commit by GitBook Editor
parent
9feba54f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
72 deletions
+1
-72
deployment.md
后端开发/deployment.md
+1
-72
No files found.
后端开发/deployment.md
View file @
f3b13c7c
...
...
@@ -58,78 +58,8 @@ db.jndiName=hap_dev
```
> tomcat 中是 java:comp/env/jdbc/hap_dev,这点不一样
### 2. jar 冲突问题
weblogic 上的一些 jar 和框架中的存在冲突,需要排除掉。
修改项目中的
`pom.xml`
,留意注释下的配置
```
xml
<dependency>
<groupId>
com.hand
</groupId>
<artifactId>
hap
</artifactId>
<type>
war
</type>
<version>
${hap.version}
</version>
<!--排除 jar -->
<exclusions>
<exclusion>
<groupId>
com.google.guava
</groupId>
<artifactId>
guava
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
com.hand
</groupId>
<artifactId>
hap
</artifactId>
<version>
${hap.version}
</version>
<classifier>
classes
</classifier>
<scope>
provided
</scope>
<!--排除 jar -->
<exclusions>
<exclusion>
<groupId>
com.google.guava
</groupId>
<artifactId>
guava
</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>
com.hand
</groupId>
<artifactId>
hap-db
</artifactId>
<version>
${hap.version}
</version>
<!--排除 jar -->
<exclusions>
<exclusion>
<groupId>
com.google.guava
</groupId>
<artifactId>
guava
</artifactId>
</exclusion>
</exclusions>
</dependency>
...
<plugin>
<groupId>
org.apache.maven.plugins
</groupId>
<artifactId>
maven-war-plugin
</artifactId>
<version>
2.6
</version>
<configuration>
<attachClasses>
true
</attachClasses>
<overlays>
<overlay>
<groupId>
com.hand
</groupId>
<artifactId>
hap
</artifactId>
<!--排除 jar -->
<excludes>
<exclude>
WEB-INF/lib/guava-15.0.jar
</exclude>
<exclude>
WEB-INF/lib/stax-api-1.0.1.jar
</exclude>
<exclude>
WEB-INF/lib/xercesImpl-2.10.0.jar
</exclude>
<exclude>
WEB-INF/lib/xml-apis-1.3.04.jar
</exclude>
<exclude>
WEB-INF/lib/xml-apis-ext-1.3.04.jar
</exclude>
</excludes>
</overlay>
</overlays>
</configuration>
</plugin>
```
打包后确保 lib 目录不存在上述 6 个 jar。
### 3. 新增 weblogic.xml
### 2. 新增 weblogic.xml
在 WEB-INF 目录下新增 weblogic.xml
```
xml
<?xml version="1.0" encoding="UTF-8"?>
...
...
@@ -145,6 +75,5 @@ weblogic 上的一些 jar 和框架中的存在冲突,需要排除掉。
<show-archived-real-path-enabled>
true
</show-archived-real-path-enabled>
</container-descriptor>
</weblogic-web-app>
```
上述 3 点在部署的时候请留意。
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