Skip to content

Commit 1317d00

Browse files
authored
Merge pull request byzer-org#1478 from chncaesar/tgz
refactor: issue # 1477 To build a release tar ball
2 parents 68cdb0a + af188af commit 1317d00

5 files changed

Lines changed: 57 additions & 22 deletions

File tree

.gitignore

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -172,4 +172,4 @@ streamingpro-mlsql/spark-warehouse
172172
external/mlsql-native-operators/cmake-build-debug-ubuntu/
173173
external/mlsql-native-operators/.clion.source.upload.marker
174174
external/mlsql-native-operators/build/
175-
cifar.tgz
175+
*.tgz

dev/package.sh

Lines changed: 6 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ usage: package
66
run package command based on different spark version.
77
Inputs are specified with the following environment variables:
88
9-
MLSQL_SPARK_VERSION - the spark version, 2.2/2.3/2.4/3.0 default 2.4
9+
MLSQL_SPARK_VERSION - the spark version, 2.3/2.4/3.0 default 2.4
1010
DRY_RUN true|false default false
1111
DISTRIBUTION true|false default false
1212
DATASOURCE_INCLUDED true|false default false
@@ -23,11 +23,10 @@ fi
2323

2424
SELF=$(cd $(dirname $0) && pwd)
2525
cd $SELF
26-
2726
cd ..
2827

2928
MLSQL_SPARK_VERSION=${MLSQL_SPARK_VERSION:-2.4}
30-
SCALA_VERSION=${SCALA_VERSION:-2.11}
29+
# SCALA_VERSION=${SCALA_VERSION:-2.11}
3130
DRY_RUN=${DRY_RUN:-false}
3231
DISTRIBUTION=${DISTRIBUTION:-false}
3332
OSS_ENABLE=${OSS_ENABLE:-false}
@@ -74,7 +73,7 @@ else
7473
fi
7574
#---------------------
7675

77-
BASE_PROFILES="-Pscala-${SCALA_VERSION} -Ponline "
76+
BASE_PROFILES="-Ponline "
7877

7978
if [[ "${ENABLE_HIVE_THRIFT_SERVER}" == "true" ]]; then
8079
BASE_PROFILES="$BASE_PROFILES -Phive-thrift-server"
@@ -89,10 +88,10 @@ if [[ "${ENABLE_CHINESE_ANALYZER}" == "true" ]]; then
8988
fi
9089

9190

92-
if [[ "$MLSQL_SPARK_VERSION" > "2.2" ]]; then
93-
BASE_PROFILES="$BASE_PROFILES"
91+
if [[ "$MLSQL_SPARK_VERSION" == "2.3" || "$MLSQL_SPARK_VERSION" == "2.4" ]]; then
92+
BASE_PROFILES="$BASE_PROFILES -Pscala-2.11"
9493
else
95-
BASE_PROFILES="$BASE_PROFILES"
94+
BASE_PROFILES="$BASE_PROFILES -Pscala-2.12"
9695
fi
9796

9897
BASE_PROFILES="$BASE_PROFILES -Pspark-$MLSQL_SPARK_VERSION.0 -Pstreamingpro-spark-$MLSQL_SPARK_VERSION.0-adaptor"
@@ -147,5 +146,3 @@ EOF
147146
mvn clean ${COMMAND} ${SKIPTEST} ${BASE_PROFILES} ${TESTPROFILE}
148147
fi
149148

150-
151-

pom.xml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@
99

1010
<name>StreamingPro Parent POM</name>
1111
<url>https://github.com/allwefantasy/streamingpro</url>
12-
<description>With MLSQL,you can unifies big data and machine learning,one language, one platform.
12+
<description>With MLSQL,you can unify big data and machine learning,one language, one platform.
1313
</description>
1414
<licenses>
1515
<license>

streamingpro-assembly/pom.xml

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,16 +4,16 @@
44
<modelVersion>4.0.0</modelVersion>
55
<parent>
66
<groupId>tech.mlsql</groupId>
7-
<artifactId>streamingpro</artifactId>
8-
<version>1.6.0-SNAPSHOT</version>
7+
<artifactId>streamingpro_2.11</artifactId>
8+
<version>2.1.0-SNAPSHOT</version>
99
<relativePath>../pom.xml</relativePath>
1010
</parent>
1111

1212
<artifactId>streamingpro-assembly</artifactId>
1313
<packaging>pom</packaging>
1414

1515
<build>
16-
<finalName>${project.parent.artifactId}</finalName>
16+
<finalName>${project.parent.artifactId}_${version}</finalName>
1717
<plugins>
1818
<plugin>
1919
<groupId>org.apache.maven.plugins</groupId>
@@ -27,6 +27,8 @@
2727
<outputDirectory>
2828
${project.parent.basedir}
2929
</outputDirectory>
30+
<tarLongFileMode>posix</tarLongFileMode>
31+
<appendAssemblyId>false</appendAssemblyId>
3032
</configuration>
3133
<executions>
3234
<execution>

streamingpro-assembly/src/main/assembly/assembly.xml

Lines changed: 44 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,34 +3,70 @@
33
<formats>
44
<format>tgz</format>
55
</formats>
6+
<includeBaseDirectory>true</includeBaseDirectory>
7+
68
<moduleSets>
79
<moduleSet>
8-
910
<!-- Enable access to all projects in the current multimodule build! -->
1011
<useAllReactorProjects>true</useAllReactorProjects>
1112

1213
<!-- Now, select which projects to include in this module-set. -->
1314
<includes>
14-
<include>tech.msql:*</include>
15+
<include>tech.mlsql:streamingpro-mlsql-spark_${spark.bigversion}_${scala.binary.version}</include>
1516
</includes>
16-
<!--<excludes>-->
17-
<!--<exclude>tech.msql:streamingpro-manager</exclude>-->
18-
<!--<exclude>tech.msql:streamingpro-dl4j</exclude>-->
19-
<!--</excludes>-->
17+
<excludes>
18+
<!-- <exclude>tech.mlsql:streamingpro-common-${spark.bigversion}_${scala.binary.version}</exclude>-->
19+
<!-- <exclude>tech.msql:streamingpro-dl4j</exclude>-->
20+
</excludes>
2021
<binaries>
2122
<outputDirectory>libs</outputDirectory>
23+
<includeDependencies>false</includeDependencies>
2224
<unpack>false</unpack>
2325
</binaries>
2426
</moduleSet>
2527
</moduleSets>
2628
<fileSets>
2729
<fileSet>
30+
<!-- Executables -->
2831
<directory>${project.parent.basedir}/dev</directory>
29-
<outputDirectory>.</outputDirectory>
3032
<includes>
3133
<include>start-local.sh</include>
34+
</includes>
35+
<outputDirectory>bin</outputDirectory>
36+
</fileSet>
37+
38+
<fileSet>
39+
<!-- Config files -->
40+
<directory>${project.parent.basedir}/streamingpro-mlsql/src/main/resources-online/</directory>
41+
<includes>
42+
<include>log4j.properties</include>
43+
</includes>
44+
<outputDirectory>conf</outputDirectory>
45+
</fileSet>
46+
47+
<fileSet>
48+
<directory>${project.parent.basedir}/dev/</directory>
49+
<!-- Include empty.json as a placeholder, to avoid every other files being copied -->
50+
<includes>
3251
<include>empty.json</include>
3352
</includes>
53+
<outputDirectory>plugin</outputDirectory>
3454
</fileSet>
55+
56+
<fileSet>
57+
<!-- Examples -->
58+
<directory>${project.parent.basedir}/examples</directory>
59+
<outputDirectory>examples</outputDirectory>
60+
</fileSet>
61+
62+
<fileSet>
63+
<directory>${project.parent.basedir}/dev</directory>
64+
<!-- Include empty.json as a placeholder, to avoid every other files being copied -->
65+
<includes>
66+
<include>empty.json</include>
67+
</includes>
68+
<outputDirectory>data</outputDirectory>
69+
</fileSet>
70+
3571
</fileSets>
36-
</assembly>
72+
</assembly>

0 commit comments

Comments
 (0)