You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@servicecomb.apache.org by GitBox <gi...@apache.org> on 2019/02/19 03:45:33 UTC
[GitHub] coolbeevip opened a new pull request #407: [SCB-1158] Modify `ZIP`
layout in maven plugin configuration support external jars
coolbeevip opened a new pull request #407: [SCB-1158] Modify `ZIP` layout in maven plugin configuration support external jars
URL: https://github.com/apache/servicecomb-pack/pull/407
We can use loads external jars support multiple database types
create libs directory in the alpha-server-0.4.0-SNAPSHOT-exec.jar directory, copy mysql-connector-java-8.0.15.jar to the libs directory And add config -Dloader.path=./libs to the command line, e.g.
```shell
java -Dloader.path=./libs -jar alpha-server-0.4.0-SNAPSHOT-exec.jar \
--spring.datasource.platform=mysql \
--spring.datasource.dataSourceClassName=com.mysql.jdbc.Driver \
--spring.datasource.url='jdbc:mysql://0.0.0.0:3306/saga?useUnicode=true&characterEncoding=utf-8&autoReconnect=true' \
--spring.datasource.username=saga-user \
--spring.datasource.password=saga-password \
--spring.profiles.active=prd
```
In order to external jars support need to modify alpha-server pom.xml use `ZIP` layout in maven plugin configuration, e.g
```
<plugin>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-maven-plugin</artifactId>
<configuration>
<layout>ZIP</layout>
</configuration>
</plugin>
```
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
With regards,
Apache Git Services