|
28 | 28 | <version>4.20.0.0-SNAPSHOT</version> |
29 | 29 | </parent> |
30 | 30 | <dependencies> |
| 31 | + <dependency> |
| 32 | + <groupId>com.mysql</groupId> |
| 33 | + <artifactId>mysql-connector-j</artifactId> |
| 34 | + <version>${cs.mysql.version}</version> |
| 35 | + <scope>compile</scope> |
| 36 | + </dependency> |
31 | 37 | <dependency> |
32 | 38 | <groupId>org.apache.commons</groupId> |
33 | 39 | <artifactId>commons-dbcp2</artifactId> |
|
108 | 114 | <plugin> |
109 | 115 | <groupId>org.codehaus.mojo</groupId> |
110 | 116 | <artifactId>exec-maven-plugin</artifactId> |
111 | | - <version>1.2.1</version> |
112 | | - <dependencies> |
113 | | - <!-- specify the dependent jdbc driver here --> |
114 | | - <dependency> |
115 | | - <groupId>com.mysql</groupId> |
116 | | - <artifactId>mysql-connector-j</artifactId> |
117 | | - <version>${cs.mysql.version}</version> |
118 | | - </dependency> |
119 | | - </dependencies> |
| 117 | + <version>${cs.exec-maven-plugin.version}</version> |
120 | 118 | <executions> |
121 | 119 | <execution> |
122 | 120 | <phase>process-resources</phase> |
123 | 121 | <id>create-schema</id> |
124 | 122 | <goals> |
125 | | - <goal>java</goal> |
| 123 | + <goal>exec</goal> |
126 | 124 | </goals> |
127 | 125 | </execution> |
128 | 126 | </executions> |
129 | 127 | <configuration> |
130 | | - <mainClass>com.cloud.upgrade.DatabaseCreator</mainClass> |
| 128 | + <executable>java</executable> |
| 129 | + <workingDirectory>${basedir}/..</workingDirectory> |
131 | 130 | <includePluginDependencies>true</includePluginDependencies> |
132 | 131 | <arguments> |
| 132 | + <argument>--add-opens=java.base/java.lang=ALL-UNNAMED</argument> |
| 133 | + <argument>-classpath</argument> |
| 134 | + <classpath /> |
| 135 | + <argument>com.cloud.upgrade.DatabaseCreator</argument> |
133 | 136 | <!-- db properties file --> |
134 | 137 | <argument>${basedir}/../utils/conf/db.properties</argument> |
135 | 138 | <argument>${basedir}/../utils/conf/db.properties.override</argument> |
|
177 | 180 | <plugin> |
178 | 181 | <groupId>org.codehaus.mojo</groupId> |
179 | 182 | <artifactId>exec-maven-plugin</artifactId> |
180 | | - <version>1.2.1</version> |
181 | | - <dependencies> |
182 | | - <dependency> |
183 | | - <groupId>com.mysql</groupId> |
184 | | - <artifactId>mysql-connector-j</artifactId> |
185 | | - <version>${cs.mysql.version}</version> |
186 | | - </dependency> |
187 | | - </dependencies> |
| 183 | + <version>${cs.exec-maven-plugin.version}</version> |
188 | 184 | <executions> |
189 | 185 | <execution> |
190 | 186 | <phase>process-resources</phase> |
191 | 187 | <id>create-schema-simulator</id> |
192 | 188 | <goals> |
193 | | - <goal>java</goal> |
| 189 | + <goal>exec</goal> |
194 | 190 | </goals> |
195 | 191 | </execution> |
196 | 192 | </executions> |
197 | 193 | <configuration> |
198 | | - <mainClass>com.cloud.upgrade.DatabaseCreator</mainClass> |
| 194 | + <executable>java</executable> |
| 195 | + <workingDirectory>${basedir}/..</workingDirectory> |
199 | 196 | <includePluginDependencies>true</includePluginDependencies> |
200 | 197 | <arguments> |
| 198 | + <argument>--add-opens=java.base/java.lang=ALL-UNNAMED</argument> |
| 199 | + <argument>-classpath</argument> |
| 200 | + <classpath /> |
| 201 | + <argument>com.cloud.upgrade.DatabaseCreator</argument> |
201 | 202 | <!-- db properties file --> |
202 | 203 | <argument>${basedir}/../utils/conf/db.properties</argument> |
203 | 204 | <argument>${basedir}/../utils/conf/db.properties.override</argument> |
|
235 | 236 | <plugin> |
236 | 237 | <groupId>org.codehaus.mojo</groupId> |
237 | 238 | <artifactId>exec-maven-plugin</artifactId> |
238 | | - <version>1.2.1</version> |
239 | | - <dependencies> |
240 | | - <dependency> |
241 | | - <groupId>com.mysql</groupId> |
242 | | - <artifactId>mysql-connector-j</artifactId> |
243 | | - <version>${cs.mysql.version}</version> |
244 | | - </dependency> |
245 | | - </dependencies> |
| 239 | + <version>${cs.exec-maven-plugin.version}</version> |
246 | 240 | <executions> |
247 | 241 | <execution> |
248 | 242 | <phase>process-resources</phase> |
249 | 243 | <id>create-schema-simulator</id> |
250 | 244 | <goals> |
251 | | - <goal>java</goal> |
| 245 | + <goal>exec</goal> |
252 | 246 | </goals> |
253 | 247 | </execution> |
254 | 248 | </executions> |
255 | 249 | <configuration> |
256 | | - <mainClass>com.cloud.upgrade.DatabaseCreator</mainClass> |
| 250 | + <executable>java</executable> |
| 251 | + <workingDirectory>${basedir}/..</workingDirectory> |
257 | 252 | <includePluginDependencies>true</includePluginDependencies> |
258 | 253 | <arguments> |
| 254 | + <argument>--add-opens=java.base/java.lang=ALL-UNNAMED</argument> |
| 255 | + <argument>-classpath</argument> |
| 256 | + <classpath /> |
| 257 | + <argument>com.cloud.upgrade.DatabaseCreator</argument> |
259 | 258 | <!-- db properties file --> |
260 | 259 | <argument>${basedir}/../utils/conf/db.properties</argument> |
261 | 260 | <argument>${basedir}/../utils/conf/db.properties.override</argument> |
|
0 commit comments