Compare commits
356 Commits
master
...
patch/7.3.
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c035091f88 | ||
|
|
3d8c28928a | ||
|
|
54af03d3ef | ||
|
|
1adad9fe93 | ||
|
|
a20ea15f4d | ||
|
|
1df79674e1 | ||
|
|
c0fedf4ef4 | ||
|
|
f3b45bf229 | ||
|
|
243a1f3326 | ||
|
|
4abf245ca1 | ||
|
|
d71b4b148a | ||
|
|
45f94c22be | ||
|
|
1c41f0c05d | ||
|
|
d70ad09a49 | ||
|
|
6e440ed726 | ||
|
|
d8ace9d577 | ||
|
|
8b3bbf7dcb | ||
|
|
0d0a67be0c | ||
|
|
3e410b5373 | ||
|
|
aad3651c38 | ||
|
|
6515a196e2 | ||
|
|
cdc51a076c | ||
|
|
5e327d255d | ||
|
|
63fffa6d6c | ||
|
|
9a974a67c0 | ||
|
|
2a8a6c074a | ||
|
|
53435511fb | ||
|
|
7840e1783e | ||
|
|
48c26b2d21 | ||
|
|
8027965b4c | ||
|
|
e9bad7dd32 | ||
|
|
593a717084 | ||
|
|
fb884595dd | ||
|
|
756ba629ed | ||
|
|
aac496bf8f | ||
|
|
7ac98d48a3 | ||
|
|
8752a75abd | ||
|
|
9e85699b85 | ||
|
|
c09016f435 | ||
|
|
028b6681c3 | ||
|
|
22fbf0ff0b | ||
|
|
ec74ac0f35 | ||
|
|
c5d44ab48b | ||
|
|
1db9854428 | ||
|
|
5d1ab30b34 | ||
|
|
3502a8e79a | ||
|
|
f3b91a3cac | ||
|
|
e1bceeea2d | ||
|
|
967a3d94ce | ||
|
|
69a5234730 | ||
|
|
c8f4dd2e6d | ||
|
|
a0b0366bcb | ||
|
|
f24633190e | ||
|
|
8e4e04c9cd | ||
|
|
05a0815778 | ||
|
|
965c02c58d | ||
|
|
5eb4100d98 | ||
|
|
b0059fdb12 | ||
|
|
061f3dc431 | ||
|
|
e85afa939c | ||
|
|
cb475f4e5e | ||
|
|
a76b52f3b9 | ||
|
|
4689d45132 | ||
|
|
9b5eccc67c | ||
|
|
53d4b392bc | ||
|
|
a2510f5e2a | ||
|
|
539710015b | ||
|
|
a398a56e95 | ||
|
|
ba647bde38 | ||
|
|
3b37b58fd0 | ||
|
|
cc07722ebb | ||
|
|
625792e472 | ||
|
|
b55e6c1c02 | ||
|
|
b43b149ba4 | ||
|
|
918cf4eed5 | ||
|
|
5fcaae4e48 | ||
|
|
41231a43b6 | ||
|
|
03eeaac507 | ||
|
|
ad7316b2ce | ||
|
|
31e27f97e0 | ||
|
|
09fd069243 | ||
|
|
f5ea29812e | ||
|
|
5acbcd229e | ||
|
|
203187c05f | ||
|
|
39996404a7 | ||
|
|
50e7057eb9 | ||
|
|
94c39f79ff | ||
|
|
a1b85f19c1 | ||
|
|
66755538e8 | ||
|
|
a2209548ae | ||
|
|
d8e604bdb0 | ||
|
|
e4194eea26 | ||
|
|
3a9ea6fafd | ||
|
|
d71fce6268 | ||
|
|
11368d3910 | ||
|
|
d01477ab11 | ||
|
|
7900e44e13 | ||
|
|
04988ed52b | ||
|
|
e0b54b7df4 | ||
|
|
9b70682a48 | ||
|
|
75fb043c1c | ||
|
|
e8c2b70985 | ||
|
|
e727191389 | ||
|
|
340b59a17e | ||
|
|
6a2257f107 | ||
|
|
d4751f4cfb | ||
|
|
9e9406e2fa | ||
|
|
647dbe0676 | ||
|
|
775e5a59f6 | ||
|
|
9a18f18a76 | ||
|
|
7a66f2715c | ||
|
|
33c569d7cb | ||
|
|
41d611a140 | ||
|
|
7381677f63 | ||
|
|
0685203687 | ||
|
|
02bd1c98e7 | ||
|
|
2115adb42e | ||
|
|
cfd4a491ea | ||
|
|
c1c0c5481b | ||
|
|
9b6eb4d7ab | ||
|
|
ebb4502761 | ||
|
|
38ce7af3e9 | ||
|
|
e5c07ac253 | ||
|
|
176e3489ce | ||
|
|
65c980efdf | ||
|
|
2fb8abe293 | ||
|
|
036736f589 | ||
|
|
5b8b168860 | ||
|
|
ea82a11f32 | ||
|
|
81e7e49dcf | ||
|
|
e5f2b94511 | ||
|
|
1b6f6cb3cb | ||
|
|
e7a58886dc | ||
|
|
84d87eb37a | ||
|
|
3506e3b76a | ||
|
|
60b1216d84 | ||
|
|
38635cfa1d | ||
|
|
73c93317fd | ||
|
|
584dd71b8b | ||
|
|
7179453025 | ||
|
|
9497eee89e | ||
|
|
b8bae80459 | ||
|
|
8827109f7f | ||
|
|
a2ffcbba3e | ||
|
|
6c5c7bcfec | ||
|
|
c5f8b26687 | ||
|
|
614556ce8c | ||
|
|
478a707a7c | ||
|
|
a7c9258846 | ||
|
|
4f63e93995 | ||
|
|
9a44a3006f | ||
|
|
59da4a3e14 | ||
|
|
27928d664f | ||
|
|
e2bc6699fa | ||
|
|
d840d36182 | ||
|
|
1492cf8130 | ||
|
|
bce81ea615 | ||
|
|
c49a50b971 | ||
|
|
1f66234efa | ||
|
|
fd1fd16679 | ||
|
|
c7213657a5 | ||
|
|
d362662fa1 | ||
|
|
5d53d880ed | ||
|
|
1d508903ea | ||
|
|
87c312f5b5 | ||
|
|
f206247506 | ||
|
|
c8ee01160c | ||
|
|
8dd10f9d2d | ||
|
|
fb83719828 | ||
|
|
3fa500b3ac | ||
|
|
219c78267e | ||
|
|
f43e648cd8 | ||
|
|
c69c81bba7 | ||
|
|
82a927aed4 | ||
|
|
b507c601f2 | ||
|
|
b7c7689554 | ||
|
|
1dce8ebdb8 | ||
|
|
dfb1157d92 | ||
|
|
3ee0dd2559 | ||
|
|
225ce06412 | ||
|
|
0a18ad8c80 | ||
|
|
b3fca54bde | ||
|
|
47b3c48580 | ||
|
|
b14945f092 | ||
|
|
823443b922 | ||
|
|
6c7c7e2d0d | ||
|
|
a05b884249 | ||
|
|
a36c14163a | ||
|
|
efe395f1bb | ||
|
|
6353bf261a | ||
|
|
441e39a51e | ||
|
|
c803692a65 | ||
|
|
a2bef6021d | ||
|
|
f6fe7cc804 | ||
|
|
8c167c470d | ||
|
|
9c91e6cce0 | ||
|
|
a003ea6a61 | ||
|
|
dd6a40cd68 | ||
|
|
a67032cdfa | ||
|
|
2a38cf7a5b | ||
|
|
4380916dcf | ||
|
|
7c7e1efb24 | ||
|
|
fc5dca5f67 | ||
|
|
54c951c4bd | ||
|
|
320c282a09 | ||
|
|
d9bff92a85 | ||
|
|
a360ffd1a7 | ||
|
|
3d7aa5a71b | ||
|
|
1bd53e9905 | ||
|
|
5580b4f8d2 | ||
|
|
9cbf21f766 | ||
|
|
4f35e05d28 | ||
|
|
c3268d3afa | ||
|
|
f5c24520ca | ||
|
|
0e30f970cf | ||
|
|
8782a4840f | ||
|
|
248c7c6d74 | ||
|
|
a2a3eb2fbf | ||
|
|
0592a4ddcc | ||
|
|
bf30eba808 | ||
|
|
e16c6f379e | ||
|
|
863a874fb2 | ||
|
|
78b2702600 | ||
|
|
18a18ce336 | ||
|
|
51d66a086e | ||
|
|
93735786d2 | ||
|
|
006b9c00b9 | ||
|
|
4790a880e1 | ||
|
|
a96fdec0a7 | ||
|
|
bde9640722 | ||
|
|
a93372f60e | ||
|
|
d1559451e4 | ||
|
|
6abc8d737d | ||
|
|
69c9182794 | ||
|
|
dc62c40afe | ||
|
|
f7952374e4 | ||
|
|
de3f85fc35 | ||
|
|
e62819fd76 | ||
|
|
adca838561 | ||
|
|
e87cfa18a1 | ||
|
|
961e39ef3b | ||
|
|
205d575bab | ||
|
|
15a25708b6 | ||
|
|
4468d89b0e | ||
|
|
3a25678438 | ||
|
|
115ddb1b05 | ||
|
|
e6a755129f | ||
|
|
1938ecc8af | ||
|
|
b15d901b27 | ||
|
|
7f92ad83a1 | ||
|
|
66b0cf243b | ||
|
|
e8ec4d0337 | ||
|
|
1e30a7ea90 | ||
|
|
debbd1107f | ||
|
|
35d279a32a | ||
|
|
6416c9c9bb | ||
|
|
e03637981c | ||
|
|
52c5ef7dfa | ||
|
|
31b3974f81 | ||
|
|
0507e76d5e | ||
|
|
c484ce75b4 | ||
|
|
212c74ebb4 | ||
|
|
489125e931 | ||
|
|
c0b2bae68e | ||
|
|
1f6dd38d99 | ||
|
|
954a123f66 | ||
|
|
a40d2a2379 | ||
|
|
e20d0e57b5 | ||
|
|
e14e19e306 | ||
|
|
94534daf40 | ||
|
|
16e8c9a4fd | ||
|
|
59f80736a2 | ||
|
|
511c3ccbd0 | ||
|
|
dbf67ed4bb | ||
|
|
29a09a75bc | ||
|
|
a73c156a6a | ||
|
|
790fe2ccb4 | ||
|
|
b507ddda61 | ||
|
|
6512df89ad | ||
|
|
a5043f56e8 | ||
|
|
c8ef5195f8 | ||
|
|
2c2bb17695 | ||
|
|
95400d2a90 | ||
|
|
39cf036547 | ||
|
|
2a39dcaab8 | ||
|
|
34e490dd0f | ||
|
|
d1f7dea73c | ||
|
|
c767870d82 | ||
|
|
cc6a1bc1da | ||
|
|
fee90cdd2f | ||
|
|
b8e0a55fb7 | ||
|
|
447e26d05c | ||
|
|
8a24135a74 | ||
|
|
316f2f7e96 | ||
|
|
9693179a6e | ||
|
|
567abbf3d4 | ||
|
|
9a3617679d | ||
|
|
215cf5fe8d | ||
|
|
21be67d243 | ||
|
|
717623b206 | ||
|
|
ea13d1115d | ||
|
|
af52c4df65 | ||
|
|
e934d2112c | ||
|
|
385843d3be | ||
|
|
aae6ad44b5 | ||
|
|
a5e1f73458 | ||
|
|
47cebcbddf | ||
|
|
0efcfa2983 | ||
|
|
76b0a7a979 | ||
|
|
045d5df5df | ||
|
|
453ca6e25a | ||
|
|
844d9e6c29 | ||
|
|
9d218fbecf | ||
|
|
2e2c5f810d | ||
|
|
9c25ce552b | ||
|
|
a42b25c9bb | ||
|
|
7d6e7e1c85 | ||
|
|
cfabaf818a | ||
|
|
e2f426e39f | ||
|
|
ba1bf20653 | ||
|
|
063db841c0 | ||
|
|
a6640f95a9 | ||
|
|
d01f8a7da9 | ||
|
|
f8e9e01e31 | ||
|
|
94ff584488 | ||
|
|
1db094edd3 | ||
|
|
8b9fe33a86 | ||
|
|
4782321f64 | ||
|
|
12b61b8d5f | ||
|
|
8b26ef7e15 | ||
|
|
8ac9327375 | ||
|
|
9f4810e59e | ||
|
|
0f89caccfb | ||
|
|
c16c8f71f8 | ||
|
|
7ab0f2015a | ||
|
|
af43cd8973 | ||
|
|
4169210118 | ||
|
|
3d185eeb95 | ||
|
|
85a8f83baa | ||
|
|
d3faad612e | ||
|
|
059c211971 | ||
|
|
ce028761e5 | ||
|
|
8c2a503063 | ||
|
|
ca7263b7a1 | ||
|
|
04d41a8421 | ||
|
|
d35506dce1 | ||
|
|
5e05ca8947 | ||
|
|
51f8af8aed | ||
|
|
360f1a2612 | ||
|
|
4f668f6a46 | ||
|
|
f75fed8fd8 | ||
|
|
812ac5399d | ||
|
|
d917b791d0 | ||
|
|
9bc4abb02d | ||
|
|
3daedf72de | ||
|
|
854ac0d1b1 |
1
.gitignore
vendored
1
.gitignore
vendored
@@ -11,3 +11,4 @@ main/plugins/org.talend.designer.codegen/resources/sparkstreaming_header.javajet
|
||||
main/plugins/org.talend.designer.codegen/resources/sparkstreaming_subprocess_footer.javajet
|
||||
main/plugins/org.talend.designer.codegen/resources/sparkstreaming_subprocess_header.javajet
|
||||
main/plugins/org.talend.designer.codegen/resources/routelet.skeleton
|
||||
.DS_Store
|
||||
@@ -4,5 +4,6 @@ Huge thanks to these people who contributed in making Talend product better:
|
||||
- [jlolling](https://github.com/jlolling) (Jan -and Miss- Lolling)
|
||||
- [kirkalicious](https://github.com/kirkalicious) (Kirk Tarou)
|
||||
- [mrizzato](https://github.com/mrizzato) (Massimiliano Rizzato)
|
||||
- [overpackaging](https://github.com/overpackaging) (Steeve Dreux)
|
||||
- [brazabr](https://github.com/brazabr) (Thiago Benvenuto)
|
||||
- [phoflack](https://jira.talendforge.org/secure/ViewProfile.jspa?name=phoflack) (Philip Hoflack)
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.abstractmap.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.alfrescooutput.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.business.diagram.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.codegen.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.components.exchange.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.core.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.dbmap.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.documentation.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.fileoutputxml.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.gefabstractmap.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.mapper.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.maven.job.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.rowgenerator.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.runprocess.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.scd.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.webservice.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.xmlmap.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.expressionbuilder.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.presentation.onboarding.resource.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.presentation.onboarding.resource.tos.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.repository.ftp.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.repository.json.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.repository.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.repository.view.di.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.sbi.engines.client.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.spagic.engines.client.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.sqlbuilder.nl</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.business.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.fragment.jars.di.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.help.tos.components.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.rcp.branding.tos.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.rcp.branding.tos.test.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.repository.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.sbi.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.spagic.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.tos.components.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.tos.core.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.tos.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.tos.libraries.feature</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.abstractmap</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.alfrescooutput</artifactId>
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.business.diagram</artifactId>
|
||||
|
||||
@@ -50,8 +50,11 @@ List<IConnection> allSubProcessConnection = codeGenArgument.getAllMainSubTreeCon
|
||||
String cid = node.getUniqueName();
|
||||
|
||||
List<? extends INode> jobCatcherNodes = process.getNodesOfType("tJobStructureCatcher");
|
||||
boolean enableLogStash = jobCatcherNodes != null && !jobCatcherNodes.isEmpty();
|
||||
boolean logstashCurrent = !cid.startsWith("tJobStructureCatcher") && !cid.startsWith("talend") && enableLogStash;
|
||||
boolean jobCatcherExists = jobCatcherNodes != null && !jobCatcherNodes.isEmpty();
|
||||
INode jobCatcherNode = jobCatcherExists ? jobCatcherNodes.get(0) : null;
|
||||
|
||||
boolean enableLogStash = !Boolean.getBoolean("deactivate_extended_component_log") && jobCatcherExists;
|
||||
boolean logstashCurrent = enableLogStash && !cid.startsWith("tJobStructureCatcher") && !cid.startsWith("talend");
|
||||
|
||||
if((codePart.equals(ECodePart.END))&&(stat || logstashCurrent)){
|
||||
boolean iterateInVFComp = (node.getVirtualLinkTo() != null && node.getVirtualLinkTo() == EConnectionType.ITERATE);
|
||||
@@ -86,11 +89,18 @@ if((codePart.equals(ECodePart.END))&&(stat || logstashCurrent)){
|
||||
for(IConnection con:connSet){
|
||||
INode source = con.getSource();
|
||||
String sourceNodeId = source.getUniqueName();
|
||||
|
||||
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
|
||||
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel);
|
||||
|
||||
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
|
||||
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel);
|
||||
|
||||
String sourceNodeComponent = source.getComponent().getName();
|
||||
for (INode jobStructureCatcher : jobCatcherNodes) {
|
||||
%>
|
||||
if(runStat.updateStatAndLog(execStat,enableLogStash,resourceMap,iterateId,"<%=con.getUniqueName()%>",2,0,
|
||||
<%=jobStructureCatcher.getUniqueName()%>,"<%=sourceNodeId%>","<%=sourceNodeComponent%>","<%=node.getUniqueName()%>","<%=node.getComponent().getName()%>","<%="REJECT".equals(con.getConnectorName()) ? "reject" : "output"%>")) {
|
||||
"<%=sourceNodeId%>","<%=sourceNodeLabel%>","<%=sourceNodeComponent%>","<%=node.getUniqueName()%>","<%=targetNodeLabel%>","<%=node.getComponent().getName()%>","<%="REJECT".equals(con.getConnectorName()) ? "reject" : "output"%>")) {
|
||||
<%=jobStructureCatcher.getDesignSubjobStartNode().getUniqueName() %>Process(globalMap);
|
||||
}
|
||||
<%
|
||||
@@ -113,11 +123,18 @@ if((codePart.equals(ECodePart.END))&&(stat || logstashCurrent)){
|
||||
for(IConnection con:connSet){
|
||||
INode source = con.getSource();
|
||||
String sourceNodeId = source.getUniqueName();
|
||||
|
||||
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
|
||||
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel);
|
||||
|
||||
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
|
||||
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel);
|
||||
|
||||
String sourceNodeComponent = source.getComponent().getName();
|
||||
for (INode jobStructureCatcher : jobCatcherNodes) {
|
||||
%>
|
||||
if(runStat.log(resourceMap,iterateId,"<%=con.getUniqueName()%>",2,0,
|
||||
<%=jobStructureCatcher.getUniqueName()%>,"<%=sourceNodeId%>","<%=sourceNodeComponent%>","<%=node.getUniqueName()%>","<%=node.getComponent().getName()%>","<%="REJECT".equals(con.getConnectorName()) ? "reject" : "output"%>")) {
|
||||
"<%=sourceNodeId%>","<%=sourceNodeLabel%>","<%=sourceNodeComponent%>","<%=node.getUniqueName()%>","<%=targetNodeLabel%>","<%=node.getComponent().getName()%>","<%="REJECT".equals(con.getConnectorName()) ? "reject" : "output"%>")) {
|
||||
<%=jobStructureCatcher.getDesignSubjobStartNode().getUniqueName() %>Process(globalMap);
|
||||
}
|
||||
<%
|
||||
@@ -150,6 +167,7 @@ if((codePart.equals(ECodePart.END))&&(stat || logstashCurrent)){
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
List<IMetadataTable> metadatas = node.getMetadataList();
|
||||
if ((!node.isSubProcessStart())&&(NodeUtil.isDataAutoPropagated(node))) {
|
||||
if (inputColName!=null) {
|
||||
@@ -175,6 +193,117 @@ if((codePart.equals(ECodePart.END))&&(stat || logstashCurrent)){
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
//log runtime lineage
|
||||
boolean enable_runtime_lineage_log = NodeUtil.isJobUsingRuntimeLineage(process) && jobCatcherExists && !cid.startsWith("tJobStructureCatcher") && !cid.startsWith("talend");
|
||||
if(enable_runtime_lineage_log) {//}
|
||||
|
||||
List<? extends IConnection> outConns = node.getOutgoingConnections();
|
||||
if(!outConns.isEmpty()) {
|
||||
%>
|
||||
if(tos_count_<%=node.getUniqueName() %> == 0) {
|
||||
<%
|
||||
//}
|
||||
}
|
||||
|
||||
for (IConnection conn : outConns) {
|
||||
if(!conn.getLineStyle().equals(EConnectionType.FLOW_MAIN) && !conn.getLineStyle().equals(EConnectionType.FLOW_MERGE) && !conn.getLineStyle().equals(EConnectionType.FLOW_REF)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
IMetadataTable metadata = conn.getMetadataTable();
|
||||
if (metadata==null) {
|
||||
continue;
|
||||
}
|
||||
|
||||
List<IMetadataColumn> columns = metadata.getListColumns();
|
||||
|
||||
if(columns == null || columns.isEmpty()) {
|
||||
continue;
|
||||
}
|
||||
|
||||
%>
|
||||
|
||||
class SchemaUtil_<%=conn.getUniqueName()%>_<%=conn.getMetadataTable().getTableName()%> {
|
||||
|
||||
public java.util.List<java.util.Map<String, String>> getSchema(final <%=NodeUtil.getPrivateConnClassName(conn) %>Struct <%=conn.getName()%>) {
|
||||
java.util.List<java.util.Map<String, String>> schema = new java.util.ArrayList<>();
|
||||
if(<%=conn.getName()%> == null) {
|
||||
return schema;
|
||||
}
|
||||
java.util.Map<String, String> field = null;
|
||||
<%
|
||||
for(IMetadataColumn column : columns){
|
||||
if("id_Dynamic".equals(column.getTalendType())) {
|
||||
%>
|
||||
routines.system.Dynamic dynamic = <%=conn.getName()%>.<%=column.getLabel()%>;
|
||||
if(dynamic != null) {
|
||||
for(routines.system.DynamicMetadata metadata : dynamic.metadatas) {
|
||||
field = new java.util.HashMap<>();
|
||||
field.put("name", metadata.getName());
|
||||
field.put("origin_name", metadata.getDbName());
|
||||
field.put("iskey", "" + metadata.isKey());
|
||||
field.put("talend_type", metadata.getType());
|
||||
field.put("type", metadata.getDbType());
|
||||
field.put("nullable", "" + metadata.isNullable());
|
||||
field.put("pattern", metadata.getFormat());
|
||||
field.put("length", "" + metadata.getLength());
|
||||
field.put("precision", "" + metadata.getPrecision());
|
||||
schema.add(field);
|
||||
}
|
||||
}
|
||||
|
||||
<%
|
||||
continue;
|
||||
}
|
||||
|
||||
String pattern = column.getPattern();
|
||||
if(pattern == null || pattern.isEmpty() || pattern.equals("\"\"")) {
|
||||
pattern = "\"\"";
|
||||
}
|
||||
%>
|
||||
field = new java.util.HashMap<>();
|
||||
field.put("name", "<%=column.getLabel()%>");
|
||||
field.put("origin_name", "<%=column.getOriginalDbColumnName()%>");
|
||||
field.put("iskey", "<%=column.isKey()%>");
|
||||
field.put("talend_type", "<%=column.getTalendType()%>");
|
||||
field.put("type", "<%=column.getType()%>");
|
||||
field.put("nullable", "<%=column.isNullable()%>");
|
||||
field.put("pattern", <%=pattern%>);
|
||||
field.put("length", "<%=column.getLength()%>");
|
||||
field.put("precision", "<%=column.getPrecision()%>");
|
||||
schema.add(field);
|
||||
<%
|
||||
}
|
||||
%>
|
||||
return schema;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
java.util.List<java.util.Map<String, String>> schema_<%=conn.getUniqueName()%>_<%=conn.getMetadataTable().getTableName()%> = new SchemaUtil_<%=conn.getUniqueName()%>_<%=conn.getMetadataTable().getTableName()%>().getSchema(<%=conn.getName()%>);
|
||||
<%
|
||||
INode target = conn.getTarget();
|
||||
String targetNodeId = target.getUniqueName();
|
||||
String targetNodeComponent = target.getComponent().getName();
|
||||
|
||||
%>
|
||||
<%=jobCatcherNode.getUniqueName()%>.addConnectionSchemaMessage("<%=node.getUniqueName()%>","<%=node.getComponent().getName()%>",
|
||||
"<%=targetNodeId%>","<%=targetNodeComponent%>", "<%=conn.getUniqueName()%>" + iterateId, schema_<%=conn.getUniqueName()%>_<%=conn.getMetadataTable().getTableName()%>);
|
||||
<%=jobCatcherNode.getDesignSubjobStartNode().getUniqueName() %>Process(globalMap);
|
||||
<%
|
||||
}
|
||||
|
||||
if(!outConns.isEmpty()) {
|
||||
//{
|
||||
%>
|
||||
}
|
||||
<%
|
||||
}
|
||||
|
||||
//{
|
||||
}
|
||||
|
||||
//======================================TDI-17183 end=====================================
|
||||
boolean traceCodeGenerated = false;
|
||||
for (IConnection conn : node.getOutgoingConnections()) {
|
||||
|
||||
@@ -8,6 +8,9 @@
|
||||
org.talend.core.model.metadata.IMetadataColumn
|
||||
org.talend.core.model.process.EConnectionType
|
||||
org.talend.core.model.process.ElementParameterParser
|
||||
org.talend.core.model.process.EParameterFieldType
|
||||
org.talend.designer.core.model.components.EParameterName
|
||||
org.talend.designer.core.model.components.ElementParameter
|
||||
org.talend.designer.codegen.config.CodeGeneratorArgument
|
||||
org.talend.core.model.utils.NodeUtil
|
||||
org.talend.core.model.process.IConnectionCategory
|
||||
@@ -140,10 +143,17 @@
|
||||
connSet.addAll(node.getIncomingConnections(EConnectionType.FLOW_MAIN));
|
||||
connSet.addAll(node.getIncomingConnections(EConnectionType.FLOW_MERGE));
|
||||
|
||||
List<? extends INode> jobCatcherNodes = node.getProcess().getNodesOfType("tJobStructureCatcher");
|
||||
boolean enableLogStash = jobCatcherNodes != null && !jobCatcherNodes.isEmpty();
|
||||
String cid = node.getUniqueName();
|
||||
boolean logstashCurrent = !cid.startsWith("tJobStructureCatcher") && !cid.startsWith("talend") && enableLogStash;
|
||||
|
||||
List<? extends INode> jobCatcherNodes = node.getProcess().getNodesOfType("tJobStructureCatcher");
|
||||
boolean jobCatcherExists = jobCatcherNodes != null && !jobCatcherNodes.isEmpty();
|
||||
INode jobCatcherNode = jobCatcherExists ? jobCatcherNodes.get(0) : null;
|
||||
|
||||
boolean enableLogStash = !Boolean.getBoolean("deactivate_extended_component_log") && jobCatcherExists;
|
||||
boolean logstashCurrent = enableLogStash && !cid.startsWith("tJobStructureCatcher") && !cid.startsWith("talend");
|
||||
|
||||
//about performance monitor, no way to support more than one job catcher component, also that is not necessary
|
||||
final String subprocessName4Catcher = logstashCurrent ? jobCatcherNodes.get(0).getDesignSubjobStartNode().getUniqueName() : null;
|
||||
|
||||
if ((codePart.equals(ECodePart.BEGIN))&&(stat || logstashCurrent)&&connSet.size()>0) {
|
||||
if(containsTPartitioner) {
|
||||
@@ -181,13 +191,35 @@
|
||||
if(!node.getComponent().useMerge()) {
|
||||
if(stat && logstashCurrent) {
|
||||
%>
|
||||
runStat.updateStatAndLog(execStat,enableLogStash,iterateId,1,1<%for(IConnection con : connSet){%>,"<%=con.getUniqueName()%>"<%}%>);
|
||||
if(runStat.update(execStat,enableLogStash,iterateId,1,1
|
||||
<%for(IConnection con : connSet){
|
||||
INode source = con.getSource();
|
||||
String sourceNodeId = source.getUniqueName();
|
||||
|
||||
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
|
||||
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel);
|
||||
|
||||
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
|
||||
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel);
|
||||
|
||||
String sourceNodeComponent = source.getComponent().getName();
|
||||
%>
|
||||
,"<%=con.getUniqueName()%>","<%=sourceNodeId%>","<%=sourceNodeLabel%>","<%=sourceNodeComponent%>","<%=node.getUniqueName()%>","<%=targetNodeLabel%>","<%=node.getComponent().getName()%>"
|
||||
<%}%>
|
||||
)) {
|
||||
<%=subprocessName4Catcher %>Process(globalMap);
|
||||
}
|
||||
<%
|
||||
} else {
|
||||
if(stat) {
|
||||
%>
|
||||
if(execStat){
|
||||
runStat.updateStatOnConnection(iterateId,1,1<%for(IConnection con : connSet){%>,"<%=con.getUniqueName()%>"<%}%>);
|
||||
runStat.updateStatOnConnection(iterateId,1,1
|
||||
<%for(IConnection con : connSet){
|
||||
%>
|
||||
,"<%=con.getUniqueName()%>"
|
||||
<%}%>
|
||||
);
|
||||
}
|
||||
<%
|
||||
}
|
||||
@@ -195,7 +227,24 @@
|
||||
if(logstashCurrent) {
|
||||
%>
|
||||
if(enableLogStash) {
|
||||
runStat.log(iterateId,1,1<%for(IConnection con : connSet){%>,"<%=con.getUniqueName()%>"<%}%>);
|
||||
if(runStat.updateLog(iterateId,1,1
|
||||
<%for(IConnection con : connSet){
|
||||
INode source = con.getSource();
|
||||
String sourceNodeId = source.getUniqueName();
|
||||
|
||||
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
|
||||
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel);
|
||||
|
||||
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
|
||||
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel);
|
||||
|
||||
String sourceNodeComponent = source.getComponent().getName();
|
||||
%>
|
||||
,"<%=con.getUniqueName()%>","<%=sourceNodeId%>","<%=sourceNodeLabel%>","<%=sourceNodeComponent%>","<%=node.getUniqueName()%>","<%=targetNodeLabel%>","<%=node.getComponent().getName()%>"
|
||||
<%}%>
|
||||
)) {
|
||||
<%=subprocessName4Catcher %>Process(globalMap);
|
||||
}
|
||||
}
|
||||
<%
|
||||
}
|
||||
@@ -205,18 +254,62 @@
|
||||
if(connection.getUniqueName().equals((String)codeGenArgument.getIncomingName())){
|
||||
if(stat && logstashCurrent) {
|
||||
%>
|
||||
runStat.updateStatAndLog(execStat,enableLogStash,iterateId,1,1<%for(IConnection con : connSet){if(con.getUniqueName().equals((String)codeGenArgument.getIncomingName())){%>,"<%=con.getUniqueName()%>"<%}}%>);
|
||||
if(runStat.update(execStat,enableLogStash,iterateId,1,1
|
||||
<%for(IConnection con : connSet){
|
||||
INode source = con.getSource();
|
||||
String sourceNodeId = source.getUniqueName();
|
||||
|
||||
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
|
||||
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel);
|
||||
|
||||
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
|
||||
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel);
|
||||
|
||||
String sourceNodeComponent = source.getComponent().getName();
|
||||
|
||||
if(con.getUniqueName().equals((String)codeGenArgument.getIncomingName())){%>
|
||||
,"<%=con.getUniqueName()%>","<%=sourceNodeId%>","<%=sourceNodeLabel%>","<%=sourceNodeComponent%>","<%=node.getUniqueName()%>","<%=targetNodeLabel%>","<%=node.getComponent().getName()%>"
|
||||
<%}
|
||||
}%>
|
||||
)) {
|
||||
<%=subprocessName4Catcher %>Process(globalMap);
|
||||
}
|
||||
<%
|
||||
} else {
|
||||
if(stat) {%>
|
||||
if(execStat){
|
||||
runStat.updateStatOnConnection(iterateId,1,1<%for(IConnection con : connSet){if(con.getUniqueName().equals((String)codeGenArgument.getIncomingName())){%>,"<%=con.getUniqueName()%>"<%}}%>);
|
||||
runStat.updateStatOnConnection(iterateId,1,1
|
||||
<%for(IConnection con : connSet){
|
||||
if(con.getUniqueName().equals((String)codeGenArgument.getIncomingName())){%>
|
||||
,"<%=con.getUniqueName()%>"
|
||||
<%}
|
||||
}%>
|
||||
);
|
||||
}
|
||||
<%}
|
||||
|
||||
if(logstashCurrent) {%>
|
||||
if(enableLogStash) {
|
||||
runStat.log(iterateId,1,1<%for(IConnection con : connSet){if(con.getUniqueName().equals((String)codeGenArgument.getIncomingName())){%>,"<%=con.getUniqueName()%>"<%}}%>);
|
||||
if(runStat.updateLog(iterateId,1,1
|
||||
<%for(IConnection con : connSet){
|
||||
INode source = con.getSource();
|
||||
String sourceNodeId = source.getUniqueName();
|
||||
|
||||
String sourceLabel = ElementParameterParser.getValue(source, "__LABEL__");
|
||||
String sourceNodeLabel = ((sourceLabel==null || "__UNIQUE_NAME__".equals(sourceLabel) || sourceLabel.contains("\"")) ? sourceNodeId : sourceLabel);
|
||||
|
||||
String targetLabel = ElementParameterParser.getValue(node, "__LABEL__");
|
||||
String targetNodeLabel = ((targetLabel==null || "__UNIQUE_NAME__".equals(targetLabel) || targetLabel.contains("\"")) ? node.getUniqueName() : targetLabel);
|
||||
|
||||
String sourceNodeComponent = source.getComponent().getName();
|
||||
|
||||
if(con.getUniqueName().equals((String)codeGenArgument.getIncomingName())){%>
|
||||
,"<%=con.getUniqueName()%>","<%=sourceNodeId%>","<%=sourceNodeLabel%>","<%=sourceNodeComponent%>","<%=node.getUniqueName()%>","<%=targetNodeLabel%>","<%=node.getComponent().getName()%>"
|
||||
<%}
|
||||
}%>
|
||||
)) {
|
||||
<%=subprocessName4Catcher %>Process(globalMap);
|
||||
}
|
||||
}
|
||||
<%}
|
||||
}
|
||||
@@ -245,12 +338,107 @@
|
||||
<%
|
||||
log.startWork();
|
||||
log.logCompSetting();
|
||||
boolean enable_runtime_lineage_log = NodeUtil.isJobUsingRuntimeLineage(node.getProcess()) && jobCatcherExists && !cid.startsWith("tJobStructureCatcher") && !cid.startsWith("talend");
|
||||
if(enable_runtime_lineage_log) {
|
||||
%>
|
||||
class ParameterUtil_<%=cid%>{
|
||||
|
||||
public java.util.Map<String, String> getParameter() throws Exception{
|
||||
java.util.Map<String, String> component_parameters = new java.util.HashMap<>();
|
||||
<%
|
||||
java.util.Set<org.talend.core.model.process.EParameterFieldType> ignoredParamsTypes = new java.util.HashSet<org.talend.core.model.process.EParameterFieldType>();
|
||||
ignoredParamsTypes.addAll(
|
||||
java.util.Arrays.asList(
|
||||
org.talend.core.model.process.EParameterFieldType.SCHEMA_TYPE,
|
||||
org.talend.core.model.process.EParameterFieldType.SCHEMA_REFERENCE,
|
||||
org.talend.core.model.process.EParameterFieldType.LABEL,
|
||||
org.talend.core.model.process.EParameterFieldType.EXTERNAL,
|
||||
org.talend.core.model.process.EParameterFieldType.MAPPING_TYPE,
|
||||
org.talend.core.model.process.EParameterFieldType.IMAGE,
|
||||
org.talend.core.model.process.EParameterFieldType.TNS_EDITOR,
|
||||
org.talend.core.model.process.EParameterFieldType.WSDL2JAVA,
|
||||
org.talend.core.model.process.EParameterFieldType.GENERATEGRAMMARCONTROLLER,
|
||||
org.talend.core.model.process.EParameterFieldType.GENERATE_SURVIVORSHIP_RULES_CONTROLLER,
|
||||
org.talend.core.model.process.EParameterFieldType.REFRESH_REPORTS,
|
||||
org.talend.core.model.process.EParameterFieldType.BROWSE_REPORTS,
|
||||
org.talend.core.model.process.EParameterFieldType.PALO_DIM_SELECTION,
|
||||
org.talend.core.model.process.EParameterFieldType.GUESS_SCHEMA,
|
||||
org.talend.core.model.process.EParameterFieldType.MATCH_RULE_IMEX_CONTROLLER,
|
||||
org.talend.core.model.process.EParameterFieldType.MEMO_PERL,
|
||||
org.talend.core.model.process.EParameterFieldType.DBTYPE_LIST,
|
||||
org.talend.core.model.process.EParameterFieldType.VERSION,
|
||||
org.talend.core.model.process.EParameterFieldType.TECHNICAL,
|
||||
org.talend.core.model.process.EParameterFieldType.ICON_SELECTION,
|
||||
org.talend.core.model.process.EParameterFieldType.JAVA_COMMAND,
|
||||
org.talend.core.model.process.EParameterFieldType.TREE_TABLE,
|
||||
org.talend.core.model.process.EParameterFieldType.VALIDATION_RULE_TYPE,
|
||||
org.talend.core.model.process.EParameterFieldType.DCSCHEMA,
|
||||
org.talend.core.model.process.EParameterFieldType.SURVIVOR_RELATION,
|
||||
org.talend.core.model.process.EParameterFieldType.REST_RESPONSE_SCHEMA_TYPE,
|
||||
org.talend.core.model.process.EParameterFieldType.BUTTON
|
||||
)
|
||||
);
|
||||
for(org.talend.core.model.process.IElementParameter ep : org.talend.core.model.utils.NodeUtil.getDisplayedParameters(node)){
|
||||
if(!ep.isLog4JEnabled() || ignoredParamsTypes.contains(ep.getFieldType())){
|
||||
continue;
|
||||
}
|
||||
|
||||
ElementParameter p = (ElementParameter)ep;
|
||||
Object pluginValue = p.getTaggedValue("org.talend.sdk.component.source");
|
||||
if(pluginValue != null && String.class.cast(pluginValue).equalsIgnoreCase("tacokit")) {
|
||||
try {
|
||||
if (!(Boolean) org.talend.core.runtime.IAdditionalInfo.class.cast(p).func("isPersisted")) {
|
||||
continue;
|
||||
}
|
||||
} catch (Exception ex) {
|
||||
//do nothing
|
||||
}
|
||||
|
||||
%>
|
||||
<%@ include file="./tacokit_runtime_log.javajet"%>
|
||||
<%
|
||||
|
||||
continue;
|
||||
}
|
||||
|
||||
String name = ep.getName();
|
||||
java.util.Set<String> ignoredParamsNames = new java.util.HashSet<String>();
|
||||
ignoredParamsNames.add("SQLPATTERN_VALUE");
|
||||
ignoredParamsNames.add("ADDITIONAL_INSERT_COLUMNS");
|
||||
ignoredParamsNames.add("ADDITIONAL_UPDATE_COLUMNS");
|
||||
ignoredParamsNames.add("SELECTION_TABLE");
|
||||
ignoredParamsNames.add("DIFFER_MESSAGE");
|
||||
ignoredParamsNames.add("NO_DIFFER_MESSAGE");
|
||||
|
||||
if(ignoredParamsNames.contains(name)) {
|
||||
//do nothing
|
||||
} else if(org.talend.core.model.process.EParameterFieldType.PASSWORD.equals(ep.getFieldType())){
|
||||
//not log password
|
||||
}else{
|
||||
String value = org.talend.core.model.utils.NodeUtil.getRuntimeParameterValue(node, ep);
|
||||
%>
|
||||
component_parameters.put("<%=name%>", String.valueOf(<%=value%>));
|
||||
<%
|
||||
}
|
||||
}
|
||||
%>
|
||||
return component_parameters;
|
||||
}
|
||||
}
|
||||
|
||||
<%=jobCatcherNode.getUniqueName()%>.addComponentParameterMessage("<%=node.getUniqueName()%>", "<%=node.getComponent().getName()%>",
|
||||
new ParameterUtil_<%=cid%>().getParameter());
|
||||
<%=jobCatcherNode.getDesignSubjobStartNode().getUniqueName() %>Process(globalMap);
|
||||
<%
|
||||
}
|
||||
|
||||
if(logstashCurrent) {
|
||||
for (INode jobStructureCatcher : jobCatcherNodes) {
|
||||
String label = ElementParameterParser.getValue(node, "__LABEL__");
|
||||
String nodeLabel = ((label==null || "__UNIQUE_NAME__".equals(label) || label.contains("\"")) ? node.getUniqueName() : label);
|
||||
%>
|
||||
if(enableLogStash) {
|
||||
<%=jobStructureCatcher.getUniqueName() %>.addCM("<%=node.getUniqueName()%>", "<%=node.getComponent().getName()%>");
|
||||
<%=jobStructureCatcher.getUniqueName() %>.addCM("<%=node.getUniqueName()%>", "<%=nodeLabel%>", "<%=node.getComponent().getName()%>");
|
||||
<%=jobStructureCatcher.getDesignSubjobStartNode().getUniqueName() %>Process(globalMap);
|
||||
}
|
||||
<%
|
||||
|
||||
@@ -24,6 +24,7 @@
|
||||
org.talend.core.model.process.ProcessUtils
|
||||
org.talend.core.model.components.IComponent
|
||||
org.talend.core.model.components.EComponentType
|
||||
org.talend.core.model.utils.NodeUtil
|
||||
"
|
||||
class="Footer"
|
||||
skeleton="footer_java.skeleton"
|
||||
@@ -108,6 +109,21 @@
|
||||
exist_tSQLDB = true;
|
||||
}
|
||||
|
||||
|
||||
String[] tcompV0Components = new String[] {
|
||||
"tAzureStorageConnection",
|
||||
"tGoogleDriveConnection",
|
||||
"tMarketoConnection",
|
||||
"tSnowflakeConnection",
|
||||
"tSalesforceConnection",
|
||||
"tNetsuiteConnection",
|
||||
"tMarkLogicConnection"
|
||||
};
|
||||
List<INode> tcompV0ComponentsList = new ArrayList<INode>();
|
||||
for (String tcompV0Component : tcompV0Components) {
|
||||
tcompV0ComponentsList.addAll((List<INode>)process.getNodesOfType(tcompV0Component));
|
||||
}
|
||||
|
||||
boolean exist_tSCP = false;
|
||||
List<INode> scpComponentsList = (List<INode>)process.getNodesOfType("tSCPConnection");
|
||||
if (scpComponentsList.size() > 0) {
|
||||
@@ -167,6 +183,8 @@
|
||||
exist_tSalesforce = true;
|
||||
}
|
||||
|
||||
List<INode> snowflakeComponentsList = (List<INode>)process.getNodesOfType("tSnowflakeConnection");
|
||||
|
||||
boolean exist_tSAP= false;
|
||||
List<INode> sapComponentsList = (List<INode>)process.getNodesOfType("tSAPConnection");
|
||||
if (sapComponentsList.size() > 0) {
|
||||
@@ -258,7 +276,7 @@
|
||||
}
|
||||
%>
|
||||
|
||||
private PropertiesWithType context_param = new PropertiesWithType();
|
||||
protected PropertiesWithType context_param = new PropertiesWithType();
|
||||
public java.util.Map<String, Object> parentContextMap = new java.util.HashMap<String, Object>();
|
||||
|
||||
public String status= "";
|
||||
@@ -447,7 +465,7 @@
|
||||
lastStr = "";
|
||||
}
|
||||
}
|
||||
enableLogStash = "true".equalsIgnoreCase(System.getProperty("monitoring"));
|
||||
enableLogStash = "true".equalsIgnoreCase(System.getProperty("audit.enabled"));
|
||||
|
||||
<%if(isLog4jEnabled){%>
|
||||
if(!"".equals(log4jLevel)){
|
||||
@@ -501,8 +519,63 @@
|
||||
break;
|
||||
}
|
||||
}
|
||||
if(jobCatcherNode!=null) {
|
||||
String location = ElementParameterParser.getValue(jobCatcherNode, "__LOCATION__");
|
||||
|
||||
boolean enableLogStash = !Boolean.getBoolean("deactivate_extended_component_log") && (jobCatcherNode!=null);
|
||||
boolean enable_runtime_lineage_log = NodeUtil.isJobUsingRuntimeLineage(process) && (jobCatcherNode!=null);
|
||||
if(enable_runtime_lineage_log) {
|
||||
%>
|
||||
java.util.Properties p_<%=jobCatcherNode.getUniqueName()%> = new java.util.Properties();
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("root.logger", "runtime");
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("encoding", "UTF-8");
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("application.name", "Talend Studio");
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("service.name", "Talend Studio Job");
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("instance.name", "Talend Studio Job Instance");
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("propagate.appender.exceptions", "none");
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("log.appender", "file");
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("appender.file.path", "runtime.json");
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("appender.file.maxsize", "52428800");
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("appender.file.maxbackup", "20");
|
||||
p_<%=jobCatcherNode.getUniqueName()%>.setProperty("host", "false");
|
||||
|
||||
final String runtime_dir_<%=jobCatcherNode.getUniqueName()%> = System.getProperty("runtime.lineage.outputpath");
|
||||
final String runtime_path_<%=jobCatcherNode.getUniqueName()%> = System.getProperty("runtime.lineage.appender.file.path");
|
||||
if(runtime_path_<%=jobCatcherNode.getUniqueName()%>==null || runtime_path_<%=jobCatcherNode.getUniqueName()%>.isEmpty()) {
|
||||
if(runtime_dir_<%=jobCatcherNode.getUniqueName()%>!=null && !runtime_dir_<%=jobCatcherNode.getUniqueName()%>.isEmpty()) {
|
||||
System.setProperty("runtime.lineage.appender.file.path",
|
||||
new StringBuilder().append(runtime_dir_<%=jobCatcherNode.getUniqueName()%>)
|
||||
.append((runtime_dir_<%=jobCatcherNode.getUniqueName()%>.endsWith("/") || runtime_dir_<%=jobCatcherNode.getUniqueName()%>.endsWith("\\")) ? "" : java.io.File.separator)
|
||||
.append(projectName)
|
||||
.append(java.io.File.separatorChar)
|
||||
.append(jobName)
|
||||
.append(java.io.File.separatorChar)
|
||||
.append(jobVersion)
|
||||
.append(java.io.File.separatorChar)
|
||||
.append("runtime_log_")
|
||||
.append(new java.text.SimpleDateFormat("yyyyMMddHHmmss").format(new java.util.Date()))
|
||||
.append(".json")
|
||||
.toString()
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
System.getProperties().stringPropertyNames().stream()
|
||||
.filter(it -> it.startsWith("runtime.lineage.") && !"runtime.lineage.outputpath".equals(it))
|
||||
.forEach(key -> p_<%=jobCatcherNode.getUniqueName()%>.setProperty(key.substring("runtime.lineage.".length()), System.getProperty(key)));
|
||||
|
||||
<%if(isLog4j1Enabled) {%>
|
||||
org.apache.log4j.Logger.getLogger(p_<%=jobCatcherNode.getUniqueName()%>.getProperty("root.logger")).setLevel(org.apache.log4j.Level.DEBUG);
|
||||
<%}%>
|
||||
|
||||
<%if(isLog4j2Enabled) {%>
|
||||
org.apache.logging.log4j.core.config.Configurator.setLevel(p_<%=jobCatcherNode.getUniqueName()%>.getProperty("root.logger"), org.apache.logging.log4j.Level.DEBUG);
|
||||
<%}%>
|
||||
|
||||
runtime_lineage_logger_<%=jobCatcherNode.getUniqueName()%> = org.talend.job.audit.JobEventAuditLoggerFactory.createJobAuditLogger(p_<%=jobCatcherNode.getUniqueName()%>);
|
||||
<%
|
||||
}
|
||||
|
||||
if(enableLogStash) {
|
||||
String location = ElementParameterParser.getValue(jobCatcherNode, "__LOCATION__");
|
||||
%>
|
||||
if(enableLogStash) {
|
||||
java.util.Properties properties_<%=jobCatcherNode.getUniqueName()%> = new java.util.Properties();
|
||||
@@ -519,21 +592,21 @@
|
||||
properties_<%=jobCatcherNode.getUniqueName()%>.setProperty("host", "false");
|
||||
|
||||
System.getProperties().stringPropertyNames().stream()
|
||||
.filter(it -> it.startsWith("monitoring.audit.logger.properties."))
|
||||
.forEach(key -> properties_<%=jobCatcherNode.getUniqueName()%>.setProperty(key.substring("monitoring.audit.logger.properties.".length()), System.getProperty(key)));
|
||||
.filter(it -> it.startsWith("audit.logger."))
|
||||
.forEach(key -> properties_<%=jobCatcherNode.getUniqueName()%>.setProperty(key.substring("audit.logger.".length()), System.getProperty(key)));
|
||||
|
||||
<%if(isLog4j1Enabled) {%>
|
||||
org.apache.log4j.Logger.getLogger("audit").setLevel(org.apache.log4j.Level.DEBUG);
|
||||
org.apache.log4j.Logger.getLogger(properties_<%=jobCatcherNode.getUniqueName()%>.getProperty("root.logger")).setLevel(org.apache.log4j.Level.DEBUG);
|
||||
<%}%>
|
||||
|
||||
<%if(isLog4j2Enabled) {%>
|
||||
org.apache.logging.log4j.core.config.Configurator.setLevel("audit", org.apache.logging.log4j.Level.DEBUG);
|
||||
org.apache.logging.log4j.core.config.Configurator.setLevel(properties_<%=jobCatcherNode.getUniqueName()%>.getProperty("root.logger"), org.apache.logging.log4j.Level.DEBUG);
|
||||
<%}%>
|
||||
auditLogger_<%=jobCatcherNode.getUniqueName()%> = org.talend.job.audit.JobEventAuditLoggerFactory.createJobAuditLogger(properties_<%=jobCatcherNode.getUniqueName()%>);
|
||||
}
|
||||
<%
|
||||
}
|
||||
%>
|
||||
%>
|
||||
|
||||
if(clientHost == null) {
|
||||
clientHost = defaultClientHost;
|
||||
@@ -576,13 +649,15 @@
|
||||
inContext = <%=className%>.class.getClassLoader().getResourceAsStream("config/contexts/" + contextStr + ".properties");
|
||||
}
|
||||
if (inContext != null) {
|
||||
//defaultProps is in order to keep the original context value
|
||||
if(context != null && context.isEmpty()) {
|
||||
try {
|
||||
//defaultProps is in order to keep the original context value
|
||||
if(context != null && context.isEmpty()) {
|
||||
defaultProps.load(inContext);
|
||||
context = new ContextProperties(defaultProps);
|
||||
}
|
||||
} finally {
|
||||
inContext.close();
|
||||
}
|
||||
|
||||
inContext.close();
|
||||
} else if (!isDefaultContext) {
|
||||
//print info and job continue to run, for case: context_param is not empty.
|
||||
System.err.println("Could not find the context " + contextStr);
|
||||
@@ -619,7 +694,16 @@
|
||||
} //endIf
|
||||
%>
|
||||
context.setContextType("<%=ctxParam.getName()%>", "<%=ctxParam.getType()%>");
|
||||
if(context.getStringValue("<%=ctxParam.getName()%>") == null) {
|
||||
context.<%=ctxParam.getName()%> = null;
|
||||
} else {
|
||||
<%//}B1 block%>
|
||||
<%
|
||||
String typeToGenerate ="String";
|
||||
if( !(ctxParam.getType().equals("id_File") || ctxParam.getType().equals("id_Directory") ||ctxParam.getType().equals("id_List Of Value"))) {
|
||||
typeToGenerate=JavaTypesManager.getTypeToGenerate(ctxParam.getType(),true);
|
||||
}
|
||||
|
||||
if (ctxParam.getType().equals("id_Password")) {
|
||||
%>
|
||||
String pwd_<%=ctxParam.getName()%>_value = context.getProperty("<%=ctxParam.getName()%>");
|
||||
@@ -637,13 +721,7 @@
|
||||
}
|
||||
}
|
||||
<%
|
||||
continue;
|
||||
}
|
||||
String typeToGenerate ="String";
|
||||
if( !(ctxParam.getType().equals("id_File") || ctxParam.getType().equals("id_Directory") ||ctxParam.getType().equals("id_List Of Value"))) {
|
||||
typeToGenerate=JavaTypesManager.getTypeToGenerate(ctxParam.getType(),true);
|
||||
}
|
||||
if(typeToGenerate.equals("java.util.Date")) {
|
||||
} else if(typeToGenerate.equals("java.util.Date")) {
|
||||
%>
|
||||
try{
|
||||
String context_<%=ctxParam.getName()%>_value = context.getProperty("<%=ctxParam.getName()%>");
|
||||
@@ -702,6 +780,10 @@
|
||||
}
|
||||
<%
|
||||
}
|
||||
%>
|
||||
<%//{B1 block%>
|
||||
}
|
||||
<%
|
||||
}
|
||||
%>
|
||||
} <%/*close last method*/%>
|
||||
@@ -872,20 +954,6 @@ if(execStat) {
|
||||
}
|
||||
%>
|
||||
|
||||
<%if (hadoopClusterIds.size() > 1) {%>
|
||||
System.err.println("Only one hadoop configuration is allowed in one job!");
|
||||
<%}%>
|
||||
|
||||
<%
|
||||
// run tHadoopConfManager component if there is it.
|
||||
if(!hadoopConfNodes.isEmpty()) {
|
||||
INode hadoopConfNode = hadoopConfNodes.get(0);
|
||||
%>
|
||||
<%=createCallProcess(hadoopConfNode, className, false) %>
|
||||
<%
|
||||
}
|
||||
%>
|
||||
|
||||
<%
|
||||
//2. load implicit contextload
|
||||
if(implicit_Context != null) {
|
||||
@@ -908,6 +976,21 @@ this.globalResumeTicket = true;//to run tPreJob
|
||||
}
|
||||
%>
|
||||
|
||||
<%if (hadoopClusterIds.size() > 1) {%>
|
||||
System.err.println("Only one hadoop configuration is allowed in one job!");
|
||||
<%}%>
|
||||
|
||||
<%
|
||||
// run tHadoopConfManager component if there is it.
|
||||
if(!hadoopConfNodes.isEmpty()) {
|
||||
INode hadoopConfNode = hadoopConfNodes.get(0);
|
||||
if (hadoopConfNode.isStart()) {
|
||||
%>
|
||||
<%=createCallProcess(hadoopConfNode, className, false) %>
|
||||
<%
|
||||
}
|
||||
}
|
||||
%>
|
||||
|
||||
<%
|
||||
//4. flush the begin msg
|
||||
@@ -921,7 +1004,7 @@ this.globalResumeTicket = true;//to run tPreJob
|
||||
<%
|
||||
}
|
||||
|
||||
if(jobCatcherNode!=null) {
|
||||
if(enableLogStash) {
|
||||
%>
|
||||
if(enableLogStash) {
|
||||
<%=jobCatcherNode.getUniqueName() %>.addJobStartMessage();
|
||||
@@ -1074,7 +1157,7 @@ this.globalResumeTicket = true;//to run tPostJob
|
||||
<%
|
||||
}
|
||||
|
||||
if(jobCatcherNode!=null) {
|
||||
if(enableLogStash) {
|
||||
%>
|
||||
if(enableLogStash) {
|
||||
<%=jobCatcherNode.getUniqueName() %>.addJobEndMessage(startTime, end, status);
|
||||
@@ -1113,6 +1196,24 @@ if (execStat) {
|
||||
}
|
||||
%>
|
||||
int returnCode = 0;
|
||||
|
||||
<%
|
||||
if (isRunInMultiThread) {
|
||||
%>
|
||||
Integer localErrorCode = (Integer)(((java.util.Map)threadLocal.get()).get("errorCode"));
|
||||
String localStatus = (String)(((java.util.Map)threadLocal.get()).get("status"));
|
||||
if (localErrorCode != null) {
|
||||
if (errorCode == null || localErrorCode.compareTo(errorCode) > 0) {
|
||||
errorCode = localErrorCode;
|
||||
}
|
||||
}
|
||||
if (localStatus != null && !status.equals("failure")){
|
||||
status = localStatus;
|
||||
}
|
||||
<%
|
||||
}
|
||||
%>
|
||||
|
||||
if(errorCode == null) {
|
||||
returnCode = status != null && status.equals("failure") ? 1 : 0;
|
||||
} else {
|
||||
@@ -1320,13 +1421,11 @@ if (execStat) {
|
||||
} else {
|
||||
type = "ftp";
|
||||
}
|
||||
if ("ftp".equals(type)) { %>
|
||||
((com.enterprisedt.net.ftp.FTPClient) obj_conn).quit();
|
||||
<%} else if ("sftp".equals(type)) { %>
|
||||
if ("sftp".equals(type)) { %>
|
||||
((com.jcraft.jsch.ChannelSftp) obj_conn).quit();
|
||||
<%} else { %>
|
||||
((org.apache.commons.net.ftp.FTPSClient) obj_conn).disconnect();
|
||||
<%}%>
|
||||
<%} else { %>
|
||||
((org.apache.commons.net.ftp.FTPClient) obj_conn).disconnect();
|
||||
<%}%>
|
||||
}
|
||||
<% } %>
|
||||
} catch (java.lang.Exception e) {
|
||||
@@ -1416,11 +1515,24 @@ if (execStat) {
|
||||
private void closeGSConnections() {
|
||||
try {
|
||||
<% for (INode gsComponent : gsComponentsList) { %>
|
||||
org.jets3t.service.impl.rest.httpclient.GoogleStorageService service_<%=gsComponent.getUniqueName()%> =
|
||||
(org.jets3t.service.impl.rest.httpclient.GoogleStorageService)globalMap.get("service_<%=gsComponent.getUniqueName()%>");
|
||||
if(service_<%=gsComponent.getUniqueName()%> !=null){
|
||||
service_<%=gsComponent.getUniqueName()%>.shutdown();
|
||||
}
|
||||
|
||||
<%
|
||||
String authType = ElementParameterParser.getValue(gsComponent, "__AUTH_TYPE__");
|
||||
if (authType.equals("USER_ACCOUNT_HMAC")){
|
||||
%>
|
||||
|
||||
org.jets3t.service.impl.rest.httpclient.GoogleStorageService service_<%=gsComponent.getUniqueName()%> =
|
||||
(org.jets3t.service.impl.rest.httpclient.GoogleStorageService)globalMap.get("service_<%=gsComponent.getUniqueName()%>");
|
||||
if(service_<%=gsComponent.getUniqueName()%> !=null){
|
||||
service_<%=gsComponent.getUniqueName()%>.shutdown();
|
||||
}
|
||||
<%
|
||||
} else if (authType.equals("SERVICE_ACCOUNT")) {
|
||||
%>
|
||||
//Don't need to close storage when use google storage api
|
||||
<%
|
||||
}
|
||||
%>
|
||||
|
||||
<% } %>
|
||||
} catch (java.lang.Exception e) {
|
||||
@@ -1501,12 +1613,14 @@ if (execStat) {
|
||||
<% } %>
|
||||
<% for (INode existNode : existComponentsList) { %>
|
||||
connections.put("col_<%=existNode.getUniqueName()%>", globalMap.get("col_<%=existNode.getUniqueName()%>"));
|
||||
<% } %>
|
||||
<% }
|
||||
|
||||
<% for (INode salesforceNode : salesforceComponentsList) { %>
|
||||
connections.put("conn_<%=salesforceNode.getUniqueName()%>", globalMap.get("conn_<%=salesforceNode.getUniqueName()%>"));
|
||||
<% } %>
|
||||
<% for (INode sapNode : sapComponentsList) { %>
|
||||
for (INode tcompV0ConnectionNode : tcompV0ComponentsList) { %>
|
||||
connections.put("<%=tcompV0ConnectionNode.getUniqueName()%>_connection", globalMap.get("<%=tcompV0ConnectionNode.getUniqueName()%>_connection"));
|
||||
connections.put("<%=tcompV0ConnectionNode.getUniqueName()%>_COMPONENT_RUNTIME_PROPERTIES", globalMap.get("<%=tcompV0ConnectionNode.getUniqueName()%>_COMPONENT_RUNTIME_PROPERTIES"));
|
||||
<% }
|
||||
|
||||
for (INode sapNode : sapComponentsList) { %>
|
||||
connections.put("conn_<%=sapNode.getUniqueName()%>", globalMap.get("conn_<%=sapNode.getUniqueName()%>"));
|
||||
<% } %>
|
||||
<% for (INode gsNode : gsComponentsList) { %>
|
||||
@@ -1570,7 +1684,7 @@ if (execStat) {
|
||||
}
|
||||
} else if (arg.startsWith("--log4jLevel=")) {
|
||||
log4jLevel = arg.substring(13);
|
||||
} else if (arg.startsWith("--monitoring") && arg.contains("=")) {//for trunjob call
|
||||
} else if (arg.startsWith("--audit.enabled") && arg.contains("=")) {//for trunjob call
|
||||
final int equal = arg.indexOf('=');
|
||||
final String key = arg.substring("--".length(), equal);
|
||||
System.setProperty(key, arg.substring(equal + 1));
|
||||
|
||||
@@ -60,6 +60,10 @@ if ((metadatas != null) && (metadatas.size() > 0)) { // metadata
|
||||
|
||||
org.talend.components.api.component.ComponentDefinition def_<%=cid %> =
|
||||
new <%= def.getClass().getName()%>();
|
||||
|
||||
org.talend.components.api.component.runtime.Writer writer_<%=cid%> = null;
|
||||
org.talend.components.api.component.runtime.Reader reader_<%=cid%> = null;
|
||||
|
||||
<%
|
||||
List<Component.CodegenPropInfo> propsToProcess = component.getCodegenPropInfos(componentProps);
|
||||
%>
|
||||
@@ -240,11 +244,11 @@ if(isTopologyNone) {
|
||||
|
||||
if (hasOutputOnly || asInputComponent) {
|
||||
%>
|
||||
org.talend.components.api.component.runtime.Source source_<%=cid%> =
|
||||
(org.talend.components.api.component.runtime.Source)sourceOrSink_<%=cid%>;
|
||||
org.talend.components.api.component.runtime.Reader reader_<%=cid%> =
|
||||
source_<%=cid%>.createReader(container_<%=cid%>);
|
||||
reader_<%=cid%> = new org.talend.codegen.flowvariables.runtime.FlowVariablesReader(reader_<%=cid%>, container_<%=cid%>);
|
||||
if (sourceOrSink_<%=cid%> instanceof org.talend.components.api.component.runtime.Source) {
|
||||
org.talend.components.api.component.runtime.Source source_<%=cid%> =
|
||||
(org.talend.components.api.component.runtime.Source)sourceOrSink_<%=cid%>;
|
||||
reader_<%=cid%> = source_<%=cid%>.createReader(container_<%=cid%>);
|
||||
reader_<%=cid%> = new org.talend.codegen.flowvariables.runtime.FlowVariablesReader(reader_<%=cid%>, container_<%=cid%>);
|
||||
|
||||
<%
|
||||
IConnection main = null;
|
||||
@@ -266,19 +270,19 @@ if (hasOutputOnly || asInputComponent) {
|
||||
IConnection schemaSourceConnector = (main!=null ? main : reject);
|
||||
String schemaSourceConnectorName = schemaSourceConnector.getMetadataTable().getAttachedConnector();
|
||||
%>
|
||||
boolean multi_output_is_allowed_<%=cid%> = false;
|
||||
boolean multi_output_is_allowed_<%=cid%> = false;
|
||||
<% //take care SourceOrSink.validate will change the schema if it contains include-all-fields, so need to get design Avro schema before validate %>
|
||||
org.talend.components.api.component.Connector c_<%=cid%> = null;
|
||||
for (org.talend.components.api.component.Connector currentConnector : props_<%=cid %>.getAvailableConnectors(null, true)) {
|
||||
if (currentConnector.getName().equals("<%=schemaSourceConnectorName%>")) {
|
||||
c_<%=cid%> = currentConnector;
|
||||
}
|
||||
org.talend.components.api.component.Connector c_<%=cid%> = null;
|
||||
for (org.talend.components.api.component.Connector currentConnector : props_<%=cid %>.getAvailableConnectors(null, true)) {
|
||||
if (currentConnector.getName().equals("<%=schemaSourceConnectorName%>")) {
|
||||
c_<%=cid%> = currentConnector;
|
||||
}
|
||||
|
||||
if (currentConnector.getName().equals("REJECT")) {//it's better to move the code to javajet
|
||||
multi_output_is_allowed_<%=cid%> = true;
|
||||
if (currentConnector.getName().equals("REJECT")) {//it's better to move the code to javajet
|
||||
multi_output_is_allowed_<%=cid%> = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
org.apache.avro.Schema schema_<%=cid%> = props_<%=cid %>.getSchema(c_<%=cid%>, true);
|
||||
org.apache.avro.Schema schema_<%=cid%> = props_<%=cid %>.getSchema(c_<%=cid%>, true);
|
||||
|
||||
<%
|
||||
irToRow = new IndexedRecordToRowStructGenerator(cid, null, columnList);
|
||||
@@ -286,117 +290,119 @@ if (hasOutputOnly || asInputComponent) {
|
||||
}
|
||||
%>
|
||||
|
||||
// Iterate through the incoming data.
|
||||
boolean available_<%=cid%> = reader_<%=cid%>.start();
|
||||
// Iterate through the incoming data.
|
||||
boolean available_<%=cid%> = reader_<%=cid%>.start();
|
||||
|
||||
resourceMap.put("reader_<%=cid%>", reader_<%=cid%>);
|
||||
resourceMap.put("reader_<%=cid%>", reader_<%=cid%>);
|
||||
|
||||
for (; available_<%=cid%>; available_<%=cid%> = reader_<%=cid%>.advance()) {
|
||||
nb_line_<%=cid %>++;
|
||||
for (; available_<%=cid%>; available_<%=cid%> = reader_<%=cid%>.advance()) {
|
||||
nb_line_<%=cid %>++;
|
||||
|
||||
<%if(hasDataOutput) {%>
|
||||
if (multi_output_is_allowed_<%=cid%>) {
|
||||
<%if(main!=null){%>
|
||||
<%=main.getName()%> = null;
|
||||
<%}%>
|
||||
|
||||
<%if(reject!=null){%>
|
||||
<%=reject.getName()%> = null;
|
||||
<%}%>
|
||||
}
|
||||
<%}%>
|
||||
|
||||
<%if(hasDataOutput) {%>
|
||||
if (multi_output_is_allowed_<%=cid%>) {
|
||||
<%if(main!=null){%>
|
||||
<%=main.getName()%> = null;
|
||||
<%}%>
|
||||
|
||||
<%if(reject!=null){%>
|
||||
<%=reject.getName()%> = null;
|
||||
<%}%>
|
||||
}
|
||||
<%}%>
|
||||
|
||||
try {
|
||||
Object data_<%=cid%> = reader_<%=cid%>.getCurrent();
|
||||
<%
|
||||
if (main != null) {
|
||||
%>
|
||||
|
||||
if(multi_output_is_allowed_<%=cid%>) {
|
||||
<%=main.getName()%> = new <%=main.getName() %>Struct();
|
||||
}
|
||||
|
||||
<%
|
||||
irToRow.generateConvertRecord("data_" + cid, main.getName(), main.getMetadataTable().getListColumns());
|
||||
}
|
||||
%>
|
||||
} catch (org.talend.components.api.exception.DataRejectException e_<%=cid%>) {
|
||||
java.util.Map<String,Object> info_<%=cid%> = e_<%=cid%>.getRejectInfo();
|
||||
<%
|
||||
if (reject!=null) {
|
||||
%>
|
||||
Object data_<%=cid%> = info_<%=cid%>.get("talend_record");
|
||||
|
||||
if (multi_output_is_allowed_<%=cid%>) {
|
||||
<%=reject.getName()%> = new <%=reject.getName() %>Struct();
|
||||
}
|
||||
try{
|
||||
<%
|
||||
irToRow.generateConvertRecord("data_" + cid, reject.getName());
|
||||
%>
|
||||
}catch(java.lang.Exception e){
|
||||
// do nothing
|
||||
}
|
||||
<%
|
||||
Set<String> commonColumns = new HashSet<String>();
|
||||
|
||||
for (IMetadataColumn column : columnList) {
|
||||
commonColumns.add(column.getLabel());
|
||||
}
|
||||
|
||||
//pass error columns
|
||||
List<IMetadataColumn> rejectColumns = reject.getMetadataTable().getListColumns();
|
||||
for(IMetadataColumn column : rejectColumns) {
|
||||
String columnName = column.getLabel();
|
||||
|
||||
// JavaType javaType = JavaTypesManager.getJavaTypeFromId(column.getTalendType());
|
||||
String typeToGenerate = JavaTypesManager.getTypeToGenerate(column.getTalendType(), column.isNullable());
|
||||
|
||||
//error columns
|
||||
if(!commonColumns.contains(columnName)) {
|
||||
%>
|
||||
<%=reject.getName()%>.<%=columnName%> = (<%=typeToGenerate%>)info_<%=cid%>.get("<%=columnName%>");
|
||||
<%
|
||||
}
|
||||
}
|
||||
} else {
|
||||
%>
|
||||
//TODO use a method instead of getting method by the special key "error/errorMessage"
|
||||
Object errorMessage_<%=cid%> = null;
|
||||
if(info_<%=cid%>.containsKey("error")){
|
||||
errorMessage_<%=cid%> = info_<%=cid%>.get("error");
|
||||
}else if(info_<%=cid%>.containsKey("errorMessage")){
|
||||
errorMessage_<%=cid%> = info_<%=cid%>.get("errorMessage");
|
||||
}else{
|
||||
errorMessage_<%=cid%> = "Rejected but error message missing";
|
||||
}
|
||||
errorMessage_<%=cid%> = "Row "+ nb_line_<%=cid %> + ": "+errorMessage_<%=cid%>;
|
||||
System.err.println(errorMessage_<%=cid%>);
|
||||
<%
|
||||
}
|
||||
if (main != null) {
|
||||
%>
|
||||
// If the record is reject, the main line record should put NULL
|
||||
<%=main.getName()%> = null;
|
||||
<%
|
||||
}
|
||||
%>
|
||||
}
|
||||
try {
|
||||
Object data_<%=cid%> = reader_<%=cid%>.getCurrent();
|
||||
<%
|
||||
if (main != null) {
|
||||
%>
|
||||
|
||||
if(multi_output_is_allowed_<%=cid%>) {
|
||||
<%=main.getName()%> = new <%=main.getName() %>Struct();
|
||||
}
|
||||
|
||||
<%
|
||||
irToRow.generateConvertRecord("data_" + cid, main.getName(), main.getMetadataTable().getListColumns());
|
||||
}
|
||||
%>
|
||||
} catch (org.talend.components.api.exception.DataRejectException e_<%=cid%>) {
|
||||
java.util.Map<String,Object> info_<%=cid%> = e_<%=cid%>.getRejectInfo();
|
||||
<%
|
||||
if (reject!=null) {
|
||||
%>
|
||||
Object data_<%=cid%> = info_<%=cid%>.get("talend_record");
|
||||
|
||||
if (multi_output_is_allowed_<%=cid%>) {
|
||||
<%=reject.getName()%> = new <%=reject.getName() %>Struct();
|
||||
}
|
||||
try{
|
||||
<%
|
||||
irToRow.generateConvertRecord("data_" + cid, reject.getName());
|
||||
%>
|
||||
}catch(java.lang.Exception e){
|
||||
// do nothing
|
||||
}
|
||||
<%
|
||||
Set<String> commonColumns = new HashSet<String>();
|
||||
|
||||
for (IMetadataColumn column : columnList) {
|
||||
commonColumns.add(column.getLabel());
|
||||
}
|
||||
|
||||
//pass error columns
|
||||
List<IMetadataColumn> rejectColumns = reject.getMetadataTable().getListColumns();
|
||||
for(IMetadataColumn column : rejectColumns) {
|
||||
String columnName = column.getLabel();
|
||||
|
||||
// JavaType javaType = JavaTypesManager.getJavaTypeFromId(column.getTalendType());
|
||||
String typeToGenerate = JavaTypesManager.getTypeToGenerate(column.getTalendType(), column.isNullable());
|
||||
|
||||
//error columns
|
||||
if(!commonColumns.contains(columnName)) {
|
||||
%>
|
||||
<%=reject.getName()%>.<%=columnName%> = (<%=typeToGenerate%>)info_<%=cid%>.get("<%=columnName%>");
|
||||
<%
|
||||
}
|
||||
}
|
||||
} else {
|
||||
%>
|
||||
//TODO use a method instead of getting method by the special key "error/errorMessage"
|
||||
Object errorMessage_<%=cid%> = null;
|
||||
if(info_<%=cid%>.containsKey("error")){
|
||||
errorMessage_<%=cid%> = info_<%=cid%>.get("error");
|
||||
}else if(info_<%=cid%>.containsKey("errorMessage")){
|
||||
errorMessage_<%=cid%> = info_<%=cid%>.get("errorMessage");
|
||||
}else{
|
||||
errorMessage_<%=cid%> = "Rejected but error message missing";
|
||||
}
|
||||
errorMessage_<%=cid%> = "Row "+ nb_line_<%=cid %> + ": "+errorMessage_<%=cid%>;
|
||||
System.err.println(errorMessage_<%=cid%>);
|
||||
<%
|
||||
}
|
||||
if (main != null) {
|
||||
%>
|
||||
// If the record is reject, the main line record should put NULL
|
||||
<%=main.getName()%> = null;
|
||||
<%
|
||||
}
|
||||
%>
|
||||
} // end of catch
|
||||
<%
|
||||
// The for loop around the incoming records from the reader is left open.
|
||||
|
||||
|
||||
} else if (hasInput) {
|
||||
%>
|
||||
org.talend.components.api.component.runtime.Sink sink_<%=cid%> =
|
||||
(org.talend.components.api.component.runtime.Sink)sourceOrSink_<%=cid%>;
|
||||
org.talend.components.api.component.runtime.WriteOperation writeOperation_<%=cid%> = sink_<%=cid%>.createWriteOperation();
|
||||
writeOperation_<%=cid%>.initialize(container_<%=cid%>);
|
||||
org.talend.components.api.component.runtime.Writer writer_<%=cid%> = writeOperation_<%=cid%>.createWriter(container_<%=cid%>);
|
||||
writer_<%=cid%>.open("<%=cid%>");
|
||||
|
||||
resourceMap.put("writer_<%=cid%>", writer_<%=cid%>);
|
||||
org.talend.codegen.enforcer.IncomingSchemaEnforcer incomingEnforcer_<%=cid%> = null;
|
||||
if (sourceOrSink_<%=cid%> instanceof org.talend.components.api.component.runtime.Sink) {
|
||||
org.talend.components.api.component.runtime.Sink sink_<%=cid%> =
|
||||
(org.talend.components.api.component.runtime.Sink)sourceOrSink_<%=cid%>;
|
||||
org.talend.components.api.component.runtime.WriteOperation writeOperation_<%=cid%> = sink_<%=cid%>.createWriteOperation();
|
||||
writeOperation_<%=cid%>.initialize(container_<%=cid%>);
|
||||
writer_<%=cid%> = writeOperation_<%=cid%>.createWriter(container_<%=cid%>);
|
||||
writer_<%=cid%>.open("<%=cid%>");
|
||||
|
||||
resourceMap.put("writer_<%=cid%>", writer_<%=cid%>);
|
||||
} // end of "sourceOrSink_<%=cid%> instanceof ...Sink"
|
||||
org.talend.components.api.component.Connector c_<%=cid%> = null;
|
||||
for (org.talend.components.api.component.Connector currentConnector : props_<%=cid %>.getAvailableConnectors(null, false)) {
|
||||
if (currentConnector.getName().equals("MAIN")) {
|
||||
@@ -405,8 +411,7 @@ if (hasOutputOnly || asInputComponent) {
|
||||
}
|
||||
}
|
||||
org.apache.avro.Schema designSchema_<%=cid%> = props_<%=cid %>.getSchema(c_<%=cid%>, false);
|
||||
org.talend.codegen.enforcer.IncomingSchemaEnforcer incomingEnforcer_<%=cid%>
|
||||
= new org.talend.codegen.enforcer.IncomingSchemaEnforcer(designSchema_<%=cid%>);
|
||||
incomingEnforcer_<%=cid%> = new org.talend.codegen.enforcer.IncomingSchemaEnforcer(designSchema_<%=cid%>);
|
||||
<%
|
||||
List<? extends IConnection> outgoingConns = node.getOutgoingSortedConnections();
|
||||
if (outgoingConns!=null){
|
||||
@@ -442,7 +447,8 @@ if (hasOutputOnly || asInputComponent) {
|
||||
}
|
||||
}
|
||||
}
|
||||
%>
|
||||
%>
|
||||
|
||||
java.lang.Iterable<?> outgoingMainRecordsList_<%=cid%> = new java.util.ArrayList<Object>();
|
||||
java.util.Iterator outgoingMainRecordsIt_<%=cid%> = null;
|
||||
|
||||
|
||||
@@ -58,13 +58,24 @@ if(isTopologyNone) {
|
||||
else if(hasOutputOnly || asInputComponent){
|
||||
%>
|
||||
} // while
|
||||
reader_<%=cid%>.close();
|
||||
final java.util.Map<String, Object> resultMap_<%=cid%> = reader_<%=cid%>.getReturnValues();
|
||||
<%
|
||||
if (hasOutputOnly || asInputComponent) {
|
||||
%>
|
||||
} // end of "if (sourceOrSink_<%=cid%> instanceof ...Source)"
|
||||
<% } %>
|
||||
java.util.Map<String, Object> resultMap_<%=cid%> = null;
|
||||
if (reader_<%=cid%> != null) {
|
||||
reader_<%=cid%>.close();
|
||||
resultMap_<%=cid%> = reader_<%=cid%>.getReturnValues();
|
||||
}
|
||||
<%
|
||||
}else if(hasInput){
|
||||
%>
|
||||
org.talend.components.api.component.runtime.Result resultObject_<%=cid%> = (org.talend.components.api.component.runtime.Result)writer_<%=cid%>.close();
|
||||
final java.util.Map<String, Object> resultMap_<%=cid%> = writer_<%=cid%>.getWriteOperation().finalize(java.util.Arrays.<org.talend.components.api.component.runtime.Result>asList(resultObject_<%=cid%>), container_<%=cid%>);
|
||||
java.util.Map<String, Object> resultMap_<%=cid%> = null;
|
||||
if (writer_<%=cid%> != null) {
|
||||
org.talend.components.api.component.runtime.Result resultObject_<%=cid%> = (org.talend.components.api.component.runtime.Result)writer_<%=cid%>.close();
|
||||
resultMap_<%=cid%> = writer_<%=cid%>.getWriteOperation().finalize(java.util.Arrays.<org.talend.components.api.component.runtime.Result>asList(resultObject_<%=cid%>), container_<%=cid%>);
|
||||
}
|
||||
<%
|
||||
} else {
|
||||
return stringBuffer.toString();
|
||||
|
||||
@@ -84,7 +84,7 @@ if(hasInput){
|
||||
for (int i = 0; i < input_columnList.size(); i++) {
|
||||
if(!input_columnList.get(i).getTalendType().equals("id_Dynamic")) {
|
||||
%>
|
||||
if (incomingEnforcer_<%=cid%>.getDesignSchema().getField("<%=input_columnList.get(i)%>") == null){
|
||||
if (incomingEnforcer_<%=cid%> != null && incomingEnforcer_<%=cid%>.getDesignSchema().getField("<%=input_columnList.get(i)%>") == null){
|
||||
incomingEnforcer_<%=cid%>.addIncomingNodeField("<%=input_columnList.get(i)%>", ((Object) <%=inputConn.getName()%>.<%=input_columnList.get(i)%>).getClass().getCanonicalName());
|
||||
shouldCreateRuntimeSchemaForIncomingNode = true;
|
||||
}
|
||||
@@ -92,7 +92,7 @@ if(hasInput){
|
||||
}
|
||||
}
|
||||
%>
|
||||
if (shouldCreateRuntimeSchemaForIncomingNode){
|
||||
if (shouldCreateRuntimeSchemaForIncomingNode && incomingEnforcer_<%=cid%> != null){
|
||||
incomingEnforcer_<%=cid%>.createRuntimeSchema();
|
||||
}
|
||||
<%
|
||||
@@ -111,7 +111,7 @@ if(hasInput){
|
||||
|
||||
if (dynamicPos != -1) {
|
||||
%>
|
||||
if (!incomingEnforcer_<%=cid%>.areDynamicFieldsInitialized()) {
|
||||
if (incomingEnforcer_<%=cid%> != null && !incomingEnforcer_<%=cid%>.areDynamicFieldsInitialized()) {
|
||||
// Initialize the dynamic columns when they are first encountered.
|
||||
for (routines.system.DynamicMetadata dm_<%=cid%> : <%=inputConn.getName()%>.<%=input_columnList.get(dynamicPos).getLabel()%>.metadatas) {
|
||||
incomingEnforcer_<%=cid%>.addDynamicField(
|
||||
@@ -128,22 +128,26 @@ if(hasInput){
|
||||
}
|
||||
|
||||
%>
|
||||
incomingEnforcer_<%=cid%>.createNewRecord();
|
||||
if (incomingEnforcer_<%=cid%> != null) {
|
||||
incomingEnforcer_<%=cid%>.createNewRecord();
|
||||
}
|
||||
<%
|
||||
for (int i = 0; i < input_columnList.size(); i++) { // column
|
||||
IMetadataColumn column = input_columnList.get(i);
|
||||
if (dynamicPos != i) {
|
||||
%>
|
||||
//skip the put action if the input column doesn't appear in component runtime schema
|
||||
if (incomingEnforcer_<%=cid%>.getRuntimeSchema().getField("<%=input_columnList.get(i)%>") != null){
|
||||
if (incomingEnforcer_<%=cid%> != null && incomingEnforcer_<%=cid%>.getRuntimeSchema().getField("<%=input_columnList.get(i)%>") != null){
|
||||
incomingEnforcer_<%=cid%>.put("<%=column.getLabel()%>", <%=inputConn.getName()%>.<%=column.getLabel()%>);
|
||||
}
|
||||
<%
|
||||
} else {
|
||||
%>
|
||||
for (int i = 0; i < <%=inputConn.getName()%>.<%=column.getLabel()%>.getColumnCount(); i++) {
|
||||
incomingEnforcer_<%=cid%>.put(<%=inputConn.getName()%>.<%=column.getLabel()%>.getColumnMetadata(i).getName(),
|
||||
<%=inputConn.getName()%>.<%=column.getLabel()%>.getColumnValue(i));
|
||||
if (incomingEnforcer_<%=cid%> != null) {
|
||||
for (int i = 0; i < <%=inputConn.getName()%>.<%=column.getLabel()%>.getColumnCount(); i++) {
|
||||
incomingEnforcer_<%=cid%>.put(<%=inputConn.getName()%>.<%=column.getLabel()%>.getColumnMetadata(i).getName(),
|
||||
<%=inputConn.getName()%>.<%=column.getLabel()%>.getColumnValue(i));
|
||||
}
|
||||
}
|
||||
<%
|
||||
}
|
||||
@@ -177,7 +181,11 @@ if(hasInput){
|
||||
} // propInfo
|
||||
|
||||
%>
|
||||
org.apache.avro.generic.IndexedRecord data_<%=cid%> = incomingEnforcer_<%=cid%>.getCurrentRecord();
|
||||
|
||||
org.apache.avro.generic.IndexedRecord data_<%=cid%> = null;
|
||||
if (incomingEnforcer_<%=cid%> != null) {
|
||||
data_<%=cid%> = incomingEnforcer_<%=cid%>.getCurrentRecord();
|
||||
}
|
||||
|
||||
<%
|
||||
boolean isParallelize ="true".equalsIgnoreCase(ElementParameterParser.getValue(node, "__PARALLELIZE__"));
|
||||
@@ -190,8 +198,9 @@ if(hasInput){
|
||||
}
|
||||
}
|
||||
%>
|
||||
|
||||
writer_<%=cid%>.write(data_<%=cid%>);
|
||||
if (writer_<%=cid%> != null && data_<%=cid%> != null) {
|
||||
writer_<%=cid%>.write(data_<%=cid%>);
|
||||
}
|
||||
|
||||
nb_line_<%=cid %>++;
|
||||
<%if(hasMainOutput){
|
||||
|
||||
@@ -116,7 +116,11 @@ class IndexedRecordToRowStructGenerator {
|
||||
routines.system.DynamicMetadata dynamicMetadata_<%=cid%> = new routines.system.DynamicMetadata();
|
||||
org.apache.avro.Schema dynamicFieldSchema_<%=cid%> = dynamicField_<%=cid%>.schema();
|
||||
// set name
|
||||
dynamicMetadata_<%=cid%>.setName(dynamicField_<%=cid%>.name());
|
||||
if("true".equals(dynamicField_<%=cid%>.getProp("ENABLE_SPECIAL_TABLENAME"))){
|
||||
dynamicMetadata_<%=cid%>.setName(dynamicField_<%=cid%>.getProp("talend.field.dbColumnName"));
|
||||
}else{
|
||||
dynamicMetadata_<%=cid%>.setName(dynamicField_<%=cid%>.name());
|
||||
}
|
||||
// set db name
|
||||
dynamicMetadata_<%=cid%>.setDbName(dynamicField_<%=cid%>.name());
|
||||
// set nullable
|
||||
@@ -166,6 +170,14 @@ class IndexedRecordToRowStructGenerator {
|
||||
if (columnName.equals(dynamicColName)) {
|
||||
%>
|
||||
java.util.Map<String, Object> dynamicValue_<%=cid%> = (java.util.Map<String, Object>) <%=codeVarSchemaEnforcer%>.get(<%=i%>);
|
||||
org.apache.avro.Schema dynSchema_<%=cid%> = ((org.talend.codegen.enforcer.OutgoingDynamicSchemaEnforcer) <%=codeVarSchemaEnforcer%>).getDynamicFieldsSchema();
|
||||
for (org.apache.avro.Schema.Field dynamicField_<%=cid%> : dynSchema_<%=cid%>.getFields()){
|
||||
String name = dynamicField_<%=cid%>.name();
|
||||
if("true".equals(dynamicField_<%=cid%>.getProp("ENABLE_SPECIAL_TABLENAME"))){
|
||||
dynamicValue_<%=cid%>.put(dynamicField_<%=cid%>.getProp("talend.field.dbColumnName"), dynamicValue_<%=cid%>.get(name));
|
||||
dynamicValue_<%=cid%>.remove(name);
|
||||
}
|
||||
}
|
||||
for (java.util.Map.Entry<String, Object> dynamicValueEntry_<%=cid%> : dynamicValue_<%=cid%>.entrySet()) {
|
||||
<%=codeVarDynamic%>.setColumnValue(<%=codeVarDynamic%>.getIndex(dynamicValueEntry_<%=cid%>.getKey()), dynamicValueEntry_<%=cid%>.getValue());
|
||||
}
|
||||
|
||||
@@ -298,6 +298,15 @@ if(isRunInMultiThread){
|
||||
}
|
||||
<% } %>
|
||||
}
|
||||
|
||||
//if the stored or passed value is "<TALEND_NULL>" string, it mean null
|
||||
public String getStringValue(String key) {
|
||||
String origin_value = this.getProperty(key);
|
||||
if(NULL_VALUE_EXPRESSION_IN_COMMAND_STRING_FOR_CHILD_JOB_ONLY.equals(origin_value)) {
|
||||
return null;
|
||||
}
|
||||
return origin_value;
|
||||
}
|
||||
|
||||
<%
|
||||
for (IContextParameter ctxParam :params)
|
||||
@@ -380,8 +389,28 @@ public <%=JavaTypesManager.getTypeToGenerate(ctxParam.getType(),true)%> get<%=Ch
|
||||
break;
|
||||
}
|
||||
}
|
||||
boolean enableLogStash = jobCatcherNode != null;
|
||||
if (stats || enableLogStash) {
|
||||
|
||||
boolean enableLogStash = !Boolean.getBoolean("deactivate_extended_component_log") && (jobCatcherNode!=null);
|
||||
boolean enable_runtime_lineage_log = NodeUtil.isJobUsingRuntimeLineage(process) && (jobCatcherNode!=null);
|
||||
|
||||
if(jobCatcherNode!=null) {
|
||||
%>
|
||||
private final JobStructureCatcherUtils <%=jobCatcherNode.getUniqueName() %> = new JobStructureCatcherUtils(jobName, "<%=process.getId() %>", "<%=process.getVersion() %>");
|
||||
<%
|
||||
}
|
||||
if(enable_runtime_lineage_log) {
|
||||
%>
|
||||
private org.talend.job.audit.JobAuditLogger runtime_lineage_logger_<%=jobCatcherNode.getUniqueName()%> = null;
|
||||
<%
|
||||
}
|
||||
|
||||
if (enableLogStash) {
|
||||
%>
|
||||
private org.talend.job.audit.JobAuditLogger auditLogger_<%=jobCatcherNode.getUniqueName()%> = null;
|
||||
|
||||
private RunStat runStat = new RunStat(<%=jobCatcherNode.getUniqueName() %>, System.getProperty("audit.interval"));
|
||||
<%
|
||||
} else if(stats) {
|
||||
%>
|
||||
private RunStat runStat = new RunStat();
|
||||
<%
|
||||
@@ -408,6 +437,20 @@ private RunTrace runTrace = new RunTrace();
|
||||
globalMap.put(KEY_DB_DATASOURCES, talendDataSources);
|
||||
globalMap.put(KEY_DB_DATASOURCES_RAW, new java.util.HashMap<String, javax.sql.DataSource>(dataSources));
|
||||
}
|
||||
|
||||
public void setDataSourceReferences(List serviceReferences) throws Exception{
|
||||
|
||||
java.util.Map<String, routines.system.TalendDataSource> talendDataSources = new java.util.HashMap<String, routines.system.TalendDataSource>();
|
||||
java.util.Map<String, javax.sql.DataSource> dataSources = new java.util.HashMap<String, javax.sql.DataSource>();
|
||||
|
||||
for (java.util.Map.Entry<String, javax.sql.DataSource> entry : BundleUtils.getServices(serviceReferences, javax.sql.DataSource.class).entrySet()) {
|
||||
dataSources.put(entry.getKey(), entry.getValue());
|
||||
talendDataSources.put(entry.getKey(), new routines.system.TalendDataSource(entry.getValue()));
|
||||
}
|
||||
|
||||
globalMap.put(KEY_DB_DATASOURCES, talendDataSources);
|
||||
globalMap.put(KEY_DB_DATASOURCES_RAW, new java.util.HashMap<String, javax.sql.DataSource>(dataSources));
|
||||
}
|
||||
|
||||
<%
|
||||
for (INode logCatcher : process.getNodesOfType("tLogCatcher")) {
|
||||
@@ -422,13 +465,6 @@ private RunTrace runTrace = new RunTrace();
|
||||
<%
|
||||
}
|
||||
|
||||
if(enableLogStash) {
|
||||
%>
|
||||
JobStructureCatcherUtils <%=jobCatcherNode.getUniqueName() %> = new JobStructureCatcherUtils(jobName, "<%=process.getId() %>", "<%=process.getVersion() %>");
|
||||
org.talend.job.audit.JobAuditLogger auditLogger_<%=jobCatcherNode.getUniqueName()%> = null;
|
||||
<%
|
||||
}
|
||||
|
||||
for (INode metterCatcher : process.getNodesOfType("tFlowMeterCatcher")) {
|
||||
%>
|
||||
MetterCatcherUtils <%=metterCatcher.getUniqueName() %> = new MetterCatcherUtils("<%=process.getId() %>", "<%=process.getVersion() %>");
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
org.talend.designer.codegen.config.CodeGeneratorArgument
|
||||
org.talend.designer.codegen.config.NodesSubTree
|
||||
org.talend.core.model.process.IProcess
|
||||
org.talend.core.model.process.ProcessUtils
|
||||
org.talend.core.model.utils.NodeUtil
|
||||
org.talend.core.model.process.IContextParameter
|
||||
java.util.List
|
||||
@@ -28,7 +29,13 @@ INode node = (INode)codeGenArgument.getArgument();
|
||||
boolean containsTPartitioner = node.getProcess().getNodesOfType("tPartitioner").size() > 0 ? true : false;
|
||||
boolean isRunJob = "tRunJob".equals(node.getComponent().getName());
|
||||
IProcess process = node.getProcess();
|
||||
|
||||
|
||||
boolean isTestContainer=ProcessUtils.isTestContainer(process);
|
||||
String className = process.getName();
|
||||
if (isTestContainer) {
|
||||
className = className + "Test";
|
||||
}
|
||||
|
||||
NodesSubTree subTree = (NodesSubTree) codeGenArgument.getSubTree();
|
||||
ECodePart codePart = codeGenArgument.getCodePart();
|
||||
//boolean trace = codeGenArgument.isTrace();
|
||||
@@ -78,10 +85,10 @@ for (IConnection iterateConn : iterateConnSet) { //1
|
||||
@Override
|
||||
public Object put(String key, Object value) {
|
||||
<%if(!isRunInMultiThread){%>
|
||||
synchronized (<%=process.getName()%>.this.obj) {
|
||||
synchronized (<%=className%>.this.obj) {
|
||||
<%}%>
|
||||
super.put(key, value);
|
||||
return <%=process.getName()%>.this.globalMap.put(key, value);
|
||||
return <%=className%>.this.globalMap.put(key, value);
|
||||
<%if(!isRunInMultiThread){%>
|
||||
}
|
||||
<%}%>
|
||||
@@ -158,7 +165,7 @@ for (IConnection iterateConn : iterateConnSet) { //1
|
||||
synchronized (globalMap) {
|
||||
this.globalMap = java.util.Collections.synchronizedMap(new ThreadedMap(globalMap));
|
||||
<%}else{%>
|
||||
synchronized (<%=process.getName()%>.this.obj) {
|
||||
synchronized (<%=className%>.this.obj) {
|
||||
this.globalMap = new ThreadedMap(globalMap);
|
||||
<%}%>
|
||||
}
|
||||
|
||||
@@ -0,0 +1,121 @@
|
||||
<%
|
||||
//copy from configuration.javajet for tacokit
|
||||
%>
|
||||
|
||||
<%
|
||||
//TODO: modify this part for Maps and nested lists.
|
||||
if (p.getFieldType() == EParameterFieldType.TABLE || p.getFieldType() == EParameterFieldType.TACOKIT_SUGGESTABLE_TABLE) {
|
||||
java.util.List<java.util.Map<String, String>> tableValues = ElementParameterParser.createTableValues((java.util.List<java.util.Map<String, Object>>) p.getValue(), p);
|
||||
String[] items = p.getListItemsDisplayCodeName();
|
||||
String tableName = p.getName().replace('$', '.');
|
||||
boolean primitiveTable = items.length == 1 && items[0].equals(tableName + "[]");
|
||||
String tableNamePrefix = tableName + "[]";
|
||||
for (int i = 0; i < tableValues.size(); i++) {
|
||||
java.util.Map<String, String> lineValues = tableValues.get(i);
|
||||
for (int j = 0; j < items.length; j++) {
|
||||
String key = tableName + "[" + i + "]";
|
||||
if (!primitiveTable) {
|
||||
final String columnName = items[j].substring(tableNamePrefix.length(), items[j].length());
|
||||
key = key + columnName;
|
||||
}
|
||||
String value = lineValues.get(items[j]);
|
||||
if (!org.talend.core.model.utils.ContextParameterUtils.isDynamic(value)) {
|
||||
value = org.talend.core.model.utils.TalendTextUtils.removeQuotes(value);
|
||||
value = org.talend.core.model.utils.TalendTextUtils.addQuotes(value);
|
||||
}
|
||||
|
||||
if(value==null || "null".equals(value.trim())) {
|
||||
value = "(Object)null";
|
||||
}
|
||||
%>
|
||||
component_parameters.put("<%=key%>",String.valueOf(<%=value%>));
|
||||
<%
|
||||
}
|
||||
}
|
||||
} else if(p.getFieldType() == EParameterFieldType.SCHEMA_TYPE) {
|
||||
final String parameterName = p.getName();
|
||||
IConnection connection = null;
|
||||
final List<? extends IConnection> connections = NodeUtil.getOutgoingConnections(node, p.getContext());
|
||||
if(connections != null && !connections.isEmpty()) {
|
||||
connection = connections.get(0);
|
||||
}
|
||||
if(connection != null) {
|
||||
IMetadataTable metaTable = connection.getMetadataTable();
|
||||
List<IMetadataColumn> columns = metaTable.getListColumns();
|
||||
for(int i = 0; i < columns.size(); i++) {
|
||||
IMetadataColumn column = columns.get(i);
|
||||
%>
|
||||
component_parameters.put("<%=parameterName%>[<%=i%>]", "<%=column.getLabel()%>");
|
||||
<%
|
||||
}
|
||||
}
|
||||
} else if (p.getFieldType() == EParameterFieldType.TACOKIT_INPUT_SCHEMA) {
|
||||
final String parameterName = p.getName();
|
||||
IConnection connection = null;
|
||||
final List<? extends IConnection> connections = NodeUtil.getIncomingConnections(node, p.getContext());
|
||||
if(connections != null && !connections.isEmpty()) {
|
||||
connection = connections.get(0);
|
||||
}
|
||||
if(connection != null) {
|
||||
IMetadataTable metaTable = connection.getMetadataTable();
|
||||
List<IMetadataColumn> columns = metaTable.getListColumns();
|
||||
for(int i = 0; i < columns.size(); i++) {
|
||||
IMetadataColumn column = columns.get(i);
|
||||
%>
|
||||
component_parameters.put("<%=parameterName%>[<%=i%>]", "<%=column.getLabel()%>");
|
||||
<%
|
||||
}
|
||||
}
|
||||
} else {
|
||||
final String key;
|
||||
if(!p.getName().contains("$")){
|
||||
key = p.getName();
|
||||
}else{
|
||||
final StringBuilder keyBuilder = new StringBuilder();
|
||||
for (String part : p.getName().split("\\.")) {
|
||||
if (keyBuilder.length() != 0) {
|
||||
keyBuilder.append(".");
|
||||
}
|
||||
if (part.contains("$") && !part.startsWith("$")) {
|
||||
keyBuilder.append(part.replace("$", "."));
|
||||
} else {
|
||||
keyBuilder.append(part);
|
||||
}
|
||||
}
|
||||
key = keyBuilder.toString();
|
||||
}
|
||||
String value = null;
|
||||
if(p.getFieldType() == EParameterFieldType.PASSWORD) {
|
||||
continue;
|
||||
} else {
|
||||
value = ElementParameterParser.getStringElementParameterValue(p);
|
||||
if (!org.talend.core.model.utils.ContextParameterUtils.isDynamic(value)) {
|
||||
value = org.talend.core.model.utils.TalendTextUtils.removeQuotes(value);
|
||||
value = org.talend.core.model.utils.TalendTextUtils.addQuotes(value);
|
||||
}
|
||||
}
|
||||
if (value != null) {
|
||||
if(key.endsWith("$maxBatchSize")){
|
||||
%>
|
||||
|
||||
<%
|
||||
} else if(p.getFieldType() == EParameterFieldType.CLOSED_LIST) {
|
||||
String valueTemp = org.talend.core.model.utils.TalendTextUtils.removeQuotes(value);
|
||||
if ("".equals(valueTemp)) {
|
||||
String[] listItemsDisplayCodeValue = p.getListItemsDisplayCodeName();
|
||||
if(listItemsDisplayCodeValue != null && listItemsDisplayCodeValue.length > 0){
|
||||
valueTemp = listItemsDisplayCodeValue[0];
|
||||
value = org.talend.core.model.utils.TalendTextUtils.addQuotes(valueTemp);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
if(value==null || "null".equals(value.trim())) {
|
||||
value = "(Object)null";
|
||||
}
|
||||
%>
|
||||
component_parameters.put("<%=key%>", String.valueOf(<%=value%>));
|
||||
<%
|
||||
} // else do not put value in configuration
|
||||
}
|
||||
%>
|
||||
@@ -68,6 +68,14 @@
|
||||
id="org.talend.designer.components.model.UserComponentsProvider">
|
||||
</ComponentsProvider>
|
||||
</extension>
|
||||
<extension
|
||||
point="org.talend.core.components_provider">
|
||||
<ComponentsProvider
|
||||
class="org.talend.designer.codegen.components.model.SharedStudioUserComponentProvider"
|
||||
folderName="user"
|
||||
id="org.talend.designer.codegen.components.model.SharedStudioUserComponentProvider">
|
||||
</ComponentsProvider>
|
||||
</extension>
|
||||
<extension
|
||||
point="org.eclipse.core.runtime.preferences">
|
||||
<initializer
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.codegen</artifactId>
|
||||
|
||||
@@ -66,6 +66,7 @@ import org.talend.designer.codegen.model.CodeGeneratorEmittersPoolFactory;
|
||||
import org.talend.designer.codegen.model.CodeGeneratorInternalTemplatesFactoryProvider;
|
||||
import org.talend.designer.codegen.proxy.JetProxy;
|
||||
import org.talend.designer.core.generic.model.Component;
|
||||
import org.talend.designer.runprocess.ProcessorUtilities;
|
||||
|
||||
/**
|
||||
* CodeGenerator.
|
||||
@@ -353,8 +354,12 @@ public class CodeGenerator implements ICodeGenerator {
|
||||
.getDefault().getService(IResourcesDependenciesService.class);
|
||||
String resourcePathForContext = null;
|
||||
if (process instanceof IProcess2) {
|
||||
resourcePathForContext = resourceService.getResourcePathForContext(process,
|
||||
contextPar.getValue());
|
||||
String value = contextPar.getValue();
|
||||
// for runtime
|
||||
if (!ProcessorUtilities.isExportConfig()) {
|
||||
contextPar.setType(JavaTypesManager.FILE.getId());
|
||||
}
|
||||
resourcePathForContext = resourceService.getResourcePathForContext(process, value);
|
||||
} else {
|
||||
// for PreviewFileInputContentDataProcess run
|
||||
resourcePathForContext = resourceService.getResourceItemFilePath(contextPar.getValue());
|
||||
|
||||
@@ -26,11 +26,9 @@ import java.util.HashMap;
|
||||
import java.util.HashSet;
|
||||
import java.util.Iterator;
|
||||
import java.util.List;
|
||||
import java.util.Locale;
|
||||
import java.util.Map;
|
||||
import java.util.ResourceBundle;
|
||||
import java.util.Optional;
|
||||
import java.util.Set;
|
||||
import java.util.concurrent.Semaphore;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import java.util.concurrent.atomic.AtomicBoolean;
|
||||
import java.util.concurrent.locks.Lock;
|
||||
@@ -70,12 +68,12 @@ import org.talend.core.model.components.ComponentCategory;
|
||||
import org.talend.core.model.components.ComponentManager;
|
||||
import org.talend.core.model.components.ComponentProviderInfo;
|
||||
import org.talend.core.model.components.ComponentUtilities;
|
||||
import org.talend.core.model.components.EComponentType;
|
||||
import org.talend.core.model.components.IComponent;
|
||||
import org.talend.core.model.components.IComponentsFactory;
|
||||
import org.talend.core.model.components.IComponentsHandler;
|
||||
import org.talend.core.model.components.filters.ComponentsFactoryProviderManager;
|
||||
import org.talend.core.model.components.filters.IComponentFactoryFilter;
|
||||
import org.talend.core.runtime.util.ComponentsLocationProvider;
|
||||
import org.talend.core.ui.IJobletProviderService;
|
||||
import org.talend.core.ui.ISparkJobletProviderService;
|
||||
import org.talend.core.ui.ISparkStreamingJobletProviderService;
|
||||
@@ -84,8 +82,6 @@ import org.talend.core.ui.images.CoreImageProvider;
|
||||
import org.talend.core.utils.TalendCacheUtils;
|
||||
import org.talend.designer.codegen.CodeGeneratorActivator;
|
||||
import org.talend.designer.codegen.i18n.Messages;
|
||||
import org.talend.designer.core.ITisLocalProviderService;
|
||||
import org.talend.designer.core.ITisLocalProviderService.ResClassLoader;
|
||||
import org.talend.designer.core.model.components.ComponentBundleToPath;
|
||||
import org.talend.designer.core.model.components.ComponentFilesNaming;
|
||||
import org.talend.designer.core.model.components.EmfComponent;
|
||||
@@ -165,7 +161,11 @@ public class ComponentsFactory implements IComponentsFactory {
|
||||
throw new RuntimeException(e);
|
||||
}
|
||||
isInitialising.set(true);
|
||||
removeOldComponentsUserFolder(); // not used anymore
|
||||
try {
|
||||
removeOldComponentsUserFolder();
|
||||
} catch (IOException ex) {
|
||||
ExceptionHandler.process(ex);
|
||||
} // not used anymore
|
||||
long startTime = System.currentTimeMillis();
|
||||
|
||||
// TimeMeasure.display = true;
|
||||
@@ -388,10 +388,12 @@ public class ComponentsFactory implements IComponentsFactory {
|
||||
ComponentManager.saveResource();
|
||||
}
|
||||
|
||||
private void removeOldComponentsUserFolder() {
|
||||
private void removeOldComponentsUserFolder() throws IOException {
|
||||
String userPath = IComponentsFactory.COMPONENTS_INNER_FOLDER + File.separatorChar
|
||||
+ ComponentUtilities.getExtFolder(OLD_COMPONENTS_USER_INNER_FOLDER);
|
||||
File componentsLocation = getComponentsLocation(userPath);
|
||||
ComponentsProviderManager componentsProviderManager = ComponentsProviderManager.getInstance();
|
||||
AbstractComponentsProvider componentsProvider = componentsProviderManager.loadUserComponentsProvidersFromExtension();
|
||||
File componentsLocation = getComponentsLocation(componentsProvider, userPath);
|
||||
if (componentsLocation != null && componentsLocation.exists()) {
|
||||
FilesUtils.removeFolder(componentsLocation, true);
|
||||
}
|
||||
@@ -672,114 +674,38 @@ public class ComponentsFactory implements IComponentsFactory {
|
||||
*
|
||||
* @param currentFolder
|
||||
* @return
|
||||
* @throws IOException
|
||||
* @throws BusinessException
|
||||
*/
|
||||
|
||||
private File getComponentsLocation(String folder) {
|
||||
String componentsPath = IComponentsFactory.COMPONENTS_LOCATION;
|
||||
IBrandingService breaningService = (IBrandingService) GlobalServiceRegister.getDefault()
|
||||
.getService(IBrandingService.class);
|
||||
if (breaningService.isPoweredOnlyCamel()) {
|
||||
componentsPath = IComponentsFactory.CAMEL_COMPONENTS_LOCATION;
|
||||
}
|
||||
Bundle b = Platform.getBundle(componentsPath);
|
||||
|
||||
File file = null;
|
||||
try {
|
||||
URL url = FileLocator.find(b, new Path(folder), null);
|
||||
if (url == null) {
|
||||
return null;
|
||||
private File getComponentsLocation(AbstractComponentsProvider componentsProvider, String folder) throws IOException {
|
||||
|
||||
if (componentsProvider instanceof ComponentsLocationProvider) {
|
||||
return componentsProvider.getInstallationFolder();
|
||||
} else {
|
||||
String componentsPath = IComponentsFactory.COMPONENTS_LOCATION;
|
||||
IBrandingService breaningService = (IBrandingService) GlobalServiceRegister.getDefault()
|
||||
.getService(IBrandingService.class);
|
||||
if (breaningService.isPoweredOnlyCamel()) {
|
||||
componentsPath = IComponentsFactory.CAMEL_COMPONENTS_LOCATION;
|
||||
}
|
||||
URL fileUrl = FileLocator.toFileURL(url);
|
||||
file = new File(fileUrl.getPath());
|
||||
} catch (Exception e) {
|
||||
// e.printStackTrace();
|
||||
ExceptionHandler.process(e);
|
||||
}
|
||||
Bundle b = Platform.getBundle(componentsPath);
|
||||
|
||||
return file;
|
||||
}
|
||||
|
||||
private File getComponentsLocation(String folder, AbstractComponentsProvider provider) {
|
||||
File file = null;
|
||||
try {
|
||||
if (provider != null) {
|
||||
file = provider.getInstallationFolder();
|
||||
} else {
|
||||
String componentsPath = IComponentsFactory.COMPONENTS_LOCATION;
|
||||
Bundle b = Platform.getBundle(componentsPath);
|
||||
IBrandingService breaningService = (IBrandingService) GlobalServiceRegister.getDefault()
|
||||
.getService(IBrandingService.class);
|
||||
if (breaningService.isPoweredOnlyCamel()) {
|
||||
componentsPath = IComponentsFactory.CAMEL_COMPONENTS_LOCATION;
|
||||
}
|
||||
File file = null;
|
||||
try {
|
||||
URL url = FileLocator.find(b, new Path(folder), null);
|
||||
if (url == null) {
|
||||
return null;
|
||||
}
|
||||
URL fileUrl = FileLocator.toFileURL(url);
|
||||
file = new File(fileUrl.getPath());
|
||||
|
||||
} catch (Exception e) {
|
||||
// e.printStackTrace();
|
||||
ExceptionHandler.process(e);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
ExceptionHandler.process(e);
|
||||
}
|
||||
return file;
|
||||
}
|
||||
|
||||
private ResourceBundle getComponentResourceBundle(IComponent currentComp, String source, String cachedPathSource,
|
||||
AbstractComponentsProvider provider) {
|
||||
try {
|
||||
AbstractComponentsProvider currentProvider = provider;
|
||||
if (currentProvider == null) {
|
||||
ComponentsProviderManager componentsProviderManager = ComponentsProviderManager.getInstance();
|
||||
Collection<AbstractComponentsProvider> providers = componentsProviderManager.getProviders();
|
||||
for (AbstractComponentsProvider curProvider : providers) {
|
||||
String path = new Path(curProvider.getInstallationFolder().toString()).toPortableString();
|
||||
if (source.startsWith(path)) {
|
||||
// fix for TDI-19889 and TDI-20507 to get the correct component provider
|
||||
if (cachedPathSource != null) {
|
||||
if (path.contains(cachedPathSource)) {
|
||||
currentProvider = curProvider;
|
||||
break;
|
||||
}
|
||||
} else {
|
||||
currentProvider = curProvider;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
String installPath = currentProvider.getInstallationFolder().toString();
|
||||
String label = ComponentFilesNaming.getInstance().getBundleName(currentComp.getName(),
|
||||
installPath.substring(installPath.lastIndexOf(IComponentsFactory.COMPONENTS_INNER_FOLDER)));
|
||||
|
||||
if (currentProvider.isUseLocalProvider()) {
|
||||
// if the component use local provider as storage (for user / ecosystem components)
|
||||
// then get the bundle resource from the current main component provider.
|
||||
|
||||
// note: code here to review later, service like this shouldn't be used...
|
||||
ResourceBundle bundle = null;
|
||||
IBrandingService brandingService = (IBrandingService) GlobalServiceRegister.getDefault()
|
||||
.getService(IBrandingService.class);
|
||||
if (brandingService.isPoweredOnlyCamel()) {
|
||||
bundle = currentProvider.getResourceBundle(label);
|
||||
} else {
|
||||
ITisLocalProviderService service = (ITisLocalProviderService) GlobalServiceRegister.getDefault()
|
||||
.getService(ITisLocalProviderService.class);
|
||||
bundle = service.getResourceBundle(label);
|
||||
}
|
||||
return bundle;
|
||||
} else {
|
||||
ResourceBundle bundle = ResourceBundle.getBundle(label, Locale.getDefault(),
|
||||
new ResClassLoader(currentProvider.getClass().getClassLoader()));
|
||||
return bundle;
|
||||
}
|
||||
} catch (IOException e) {
|
||||
ExceptionHandler.process(e);
|
||||
}
|
||||
|
||||
return null;
|
||||
return file;
|
||||
}
|
||||
}
|
||||
|
||||
private String getCodeLanguageSuffix() {
|
||||
@@ -838,23 +764,21 @@ public class ComponentsFactory implements IComponentsFactory {
|
||||
init(false);
|
||||
}
|
||||
|
||||
for (IComponent comp : componentList) {
|
||||
if (comp.getComponentType() != EComponentType.JOBLET) {
|
||||
continue;
|
||||
}
|
||||
String comName = comp.getName();
|
||||
if (comp != null && paletteType.equals(comp.getPaletteType())) {
|
||||
if (comName.equals(name)) {
|
||||
return comp;
|
||||
} else if (new JobletUtil().matchExpression(comName)) {
|
||||
String[] names = comName.split(":"); //$NON-NLS-1$
|
||||
comName = names[1];
|
||||
if (comName.equals(name)) {
|
||||
return comp;
|
||||
}
|
||||
// check if reference joblet component presents
|
||||
JobletUtil jobletUtils = new JobletUtil();
|
||||
Optional<IComponent> result = jobletUtils.findComponentByName(componentList, name, paletteType);
|
||||
if (!result.isPresent()) {
|
||||
// check if any name matching joblet component presents
|
||||
if (jobletUtils.matchExpression(name)) {
|
||||
name = StringUtils.substringAfterLast(name, ":"); //$NON-NLS-1$
|
||||
if (StringUtils.isNotBlank(name)) {
|
||||
result = jobletUtils.findComponentByName(componentList, name, paletteType);
|
||||
}
|
||||
}
|
||||
}
|
||||
if (result.isPresent()) {
|
||||
return result.get();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -1085,5 +1009,13 @@ public class ComponentsFactory implements IComponentsFactory {
|
||||
public void setComponentsHandler(IComponentsHandler componentsHandler) {
|
||||
this.componentsHandler = componentsHandler;
|
||||
}
|
||||
|
||||
public String getCustomComponentBundlePath() {
|
||||
ComponentsProviderManager componentsProviderManager = ComponentsProviderManager.getInstance();
|
||||
AbstractComponentsProvider componentsProvider = componentsProviderManager.loadUserComponentsProvidersFromExtension();
|
||||
String bundle = componentsProvider.getComponentsBundle();
|
||||
return ComponentBundleToPath.getPathFromBundle(bundle);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -23,6 +23,7 @@ import org.eclipse.core.runtime.IExtensionRegistry;
|
||||
import org.eclipse.core.runtime.Platform;
|
||||
import org.talend.core.GlobalServiceRegister;
|
||||
import org.talend.core.model.components.AbstractComponentsProvider;
|
||||
import org.talend.core.runtime.util.SharedStudioInfoProvider;
|
||||
import org.talend.core.ui.branding.IBrandingService;
|
||||
import org.talend.designer.codegen.i18n.Messages;
|
||||
|
||||
@@ -69,6 +70,9 @@ public final class ComponentsProviderManager {
|
||||
try {
|
||||
AbstractComponentsProvider componentsProvider = (AbstractComponentsProvider) configurationElement
|
||||
.createExecutableExtension("class"); //$NON-NLS-1$
|
||||
if (componentsProvider instanceof SharedStudioInfoProvider && !((SharedStudioInfoProvider)componentsProvider).isSupportCurrentMode()) {
|
||||
continue;
|
||||
}
|
||||
componentsProvider.setId(id);
|
||||
componentsProvider.setFolderName(folderName);
|
||||
componentsProvider.setContributer(contributerName);
|
||||
@@ -81,15 +85,15 @@ public final class ComponentsProviderManager {
|
||||
}
|
||||
}
|
||||
|
||||
public AbstractComponentsProvider loadUserComponentsProvidersFromExtension() {
|
||||
if (providers == null) {
|
||||
loadComponentsProvidersFromExtension();
|
||||
}
|
||||
for (AbstractComponentsProvider provider : providers) {
|
||||
if ("org.talend.designer.components.model.UserComponentsProvider".equals(provider.getId())) {
|
||||
return provider;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
public AbstractComponentsProvider loadUserComponentsProvidersFromExtension() {
|
||||
if (providers == null) {
|
||||
loadComponentsProvidersFromExtension();
|
||||
}
|
||||
for (AbstractComponentsProvider provider : providers) {
|
||||
if (provider instanceof UserComponentsProvider) {
|
||||
return provider;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,61 @@
|
||||
package org.talend.designer.codegen.components.model;
|
||||
//============================================================================
|
||||
//
|
||||
//Copyright (C) 2006-2019 Talend Inc. - www.talend.com
|
||||
//
|
||||
//This source code is available under agreement available at
|
||||
//%InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt
|
||||
//
|
||||
//You should have received a copy of the agreement
|
||||
//along with this program; if not, write to Talend SA
|
||||
//9 rue Pages 92150 Suresnes, France
|
||||
//
|
||||
//============================================================================
|
||||
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.net.URL;
|
||||
import java.net.URLClassLoader;
|
||||
import java.util.ResourceBundle;
|
||||
|
||||
import org.eclipse.core.runtime.IPath;
|
||||
import org.eclipse.core.runtime.Path;
|
||||
import org.eclipse.core.runtime.Platform;
|
||||
import org.talend.core.model.components.ComponentUtilities;
|
||||
import org.talend.core.model.components.IComponentsFactory;
|
||||
import org.talend.core.runtime.util.ComponentsLocationProvider;
|
||||
import org.talend.core.runtime.util.SharedStudioUtils;
|
||||
import org.talend.designer.core.model.components.ComponentBundleToPath;
|
||||
|
||||
public class SharedStudioUserComponentProvider extends UserComponentsProvider implements ComponentsLocationProvider{
|
||||
@Override
|
||||
public File getInstallationFolder() throws IOException {
|
||||
File componentFolder = SharedStudioUtils.getSharedStudioComponentsParentFolder();
|
||||
IPath path = new Path(IComponentsFactory.COMPONENTS_INNER_FOLDER);
|
||||
path = path.append(IComponentsFactory.EXTERNAL_COMPONENTS_INNER_FOLDER).append(ComponentUtilities.getExtFolder(getFolderName()));
|
||||
File installationFolder = new File (componentFolder, path.toOSString());
|
||||
return installationFolder;
|
||||
}
|
||||
|
||||
|
||||
public String getComponentsBundle() {
|
||||
return ComponentBundleToPath.SHARED_STUDIO_CUSTOM_COMPONENT_BUNDLE;
|
||||
}
|
||||
|
||||
public boolean isSupportCurrentMode() {
|
||||
if (SharedStudioUtils.isSharedStudioMode()) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResourceBundle getResourceBundle(String label) {
|
||||
URL configFolderUrl = Platform.getConfigurationLocation().getURL();
|
||||
URLClassLoader urlLoader = new URLClassLoader(new java.net.URL[]{configFolderUrl});
|
||||
java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle( label ,
|
||||
java.util.Locale.getDefault(), urlLoader );
|
||||
return bundle;
|
||||
}
|
||||
|
||||
}
|
||||
@@ -34,13 +34,15 @@ import org.talend.core.model.components.ComponentUtilities;
|
||||
import org.talend.core.model.components.IComponentsFactory;
|
||||
import org.talend.core.model.general.Project;
|
||||
import org.talend.core.model.repository.ERepositoryObjectType;
|
||||
import org.talend.core.runtime.util.SharedStudioInfoProvider;
|
||||
import org.talend.core.runtime.util.SharedStudioUtils;
|
||||
import org.talend.core.ui.branding.IBrandingService;
|
||||
import org.talend.designer.codegen.CodeGeneratorActivator;
|
||||
import org.talend.designer.codegen.components.ui.IComponentPreferenceConstant;
|
||||
import org.talend.repository.ProjectManager;
|
||||
|
||||
/***/
|
||||
public class UserComponentsProvider extends AbstractCustomComponentsProvider {
|
||||
public class UserComponentsProvider extends AbstractCustomComponentsProvider implements SharedStudioInfoProvider{
|
||||
|
||||
@Override
|
||||
protected File getExternalComponentsLocation() {
|
||||
@@ -147,5 +149,11 @@ public class UserComponentsProvider extends AbstractCustomComponentsProvider {
|
||||
public String getComponentsBundle() {
|
||||
return IComponentsFactory.COMPONENTS_LOCATION;
|
||||
}
|
||||
|
||||
|
||||
public boolean isSupportCurrentMode() {
|
||||
if (SharedStudioUtils.isSharedStudioMode()) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -60,6 +60,7 @@ public enum EInternalTemplate {
|
||||
// just to have compiled templates
|
||||
FOOTER_ROUTE("footer_route", "0.0.1"), //$NON-NLS-1$ //$NON-NLS-2$
|
||||
HEADER_ROUTE("header_route", "0.0.1"), //$NON-NLS-1$ //$NON-NLS-2$
|
||||
MICROSERVICE_APP_SECURITY("microservice_app_security","0.0.1"), //$NON-NLS-1$ //$NON-NLS-2$
|
||||
CAMEL_RUNIF("camel_run_if", "0.0.1"), //$NON-NLS-1$ //$NON-NLS-2$
|
||||
CAMEL_SPECIALLINKS("camel_speciallinks", "0.0.1"), //$NON-NLS-1$ //$NON-NLS-2$
|
||||
MICROSERVICE_APP("microservice_app", "0.0.1"), //$NON-NLS-1$ //$NON-NLS-2$
|
||||
|
||||
@@ -18,6 +18,7 @@ import java.util.Map;
|
||||
import org.eclipse.core.runtime.Platform;
|
||||
import org.talend.commons.exception.ExceptionHandler;
|
||||
import org.talend.commons.utils.StringUtils;
|
||||
import org.talend.designer.core.model.components.ComponentBundleToPath;
|
||||
|
||||
/**
|
||||
* Jet container for a particular component.
|
||||
@@ -213,8 +214,17 @@ public class JetBean {
|
||||
if (pluginIdToBundle.containsKey(pluginId)) {
|
||||
base = pluginIdToBundle.get(pluginId);
|
||||
} else {
|
||||
base = Platform.getBundle(pluginId).getEntry("/").toString(); //$NON-NLS-1$
|
||||
pluginIdToBundle.put(pluginId, base);
|
||||
if (ComponentBundleToPath.SHARED_STUDIO_CUSTOM_COMPONENT_BUNDLE.equals(pluginId)) {
|
||||
base = ComponentBundleToPath.getPathFromBundle(pluginId);
|
||||
if (!base.endsWith("/")) {
|
||||
base = base + "/";
|
||||
}
|
||||
pluginIdToBundle.put(pluginId, base);
|
||||
} else {
|
||||
base = Platform.getBundle(pluginId).getEntry("/").toString(); //$NON-NLS-1$
|
||||
pluginIdToBundle.put(pluginId, base);
|
||||
}
|
||||
|
||||
}
|
||||
String result = base + relativeUri;
|
||||
return result;
|
||||
|
||||
@@ -136,13 +136,11 @@ public class TalendJETCompiler extends JETCompiler {
|
||||
// get the plugin name from fileURI
|
||||
String refPluginName = matcher.group(1);
|
||||
// retrieve the plugin URI by pluginName.
|
||||
Bundle refBundle = Platform.getBundle(refPluginName);
|
||||
if (refBundle != null) {
|
||||
String realURI = TemplateUtil.getPlatformUrlOfBundle(refPluginName);
|
||||
String realURI = TemplateUtil.getPlatformUrlOfBundle(refPluginName);
|
||||
if (realURI != null) {
|
||||
// replace the old fileURI to new one by pluginURI
|
||||
String newFileURI = fileURI.replaceFirst(PLUGIN_VAR_PATTERN.pattern(), realURI);
|
||||
return newFileURI;
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -14,6 +14,7 @@ package org.talend.designer.codegen.config;
|
||||
|
||||
import org.eclipse.core.runtime.Platform;
|
||||
import org.osgi.framework.Bundle;
|
||||
import org.talend.designer.core.model.components.ComponentBundleToPath;
|
||||
|
||||
/**
|
||||
* CodeGenerator Templates Ressources Utils.
|
||||
@@ -161,10 +162,25 @@ public class TemplateUtil {
|
||||
* @return
|
||||
*/
|
||||
public static String getPlatformUrlOfBundle(String bundleName) {
|
||||
Bundle bundle = Platform.getBundle(bundleName);
|
||||
if (bundle == null) {
|
||||
return null;
|
||||
}
|
||||
return "platform:/plugin/" + bundle.getSymbolicName() + "_" + bundle.getVersion().toString() + "/";
|
||||
if (ComponentBundleToPath.SHARED_STUDIO_CUSTOM_COMPONENT_BUNDLE.equals(bundleName)) {
|
||||
String basePath = ComponentBundleToPath.getPathFromBundle(bundleName);
|
||||
if (!basePath.endsWith("/")) {
|
||||
basePath = basePath + "/";
|
||||
}
|
||||
return basePath;
|
||||
} else {
|
||||
Bundle bundle = Platform.getBundle(bundleName);
|
||||
if (bundle == null) {
|
||||
return null;
|
||||
}
|
||||
|
||||
StringBuilder sb = new StringBuilder();
|
||||
sb.append("platform:/plugin/");
|
||||
sb.append(bundle.getSymbolicName());
|
||||
sb.append("_");
|
||||
sb.append(bundle.getVersion().toString());
|
||||
sb.append("/");
|
||||
return sb.toString();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -47,6 +47,7 @@ import org.talend.core.ui.component.ComponentsFactoryProvider;
|
||||
import org.talend.designer.codegen.CodeGeneratorActivator;
|
||||
import org.talend.designer.codegen.config.TemplateUtil;
|
||||
import org.talend.designer.codegen.i18n.Messages;
|
||||
import org.talend.designer.core.model.components.ComponentBundleToPath;
|
||||
|
||||
/**
|
||||
* DOC xtan
|
||||
@@ -256,10 +257,9 @@ public final class JetSkeletonManager {
|
||||
};
|
||||
|
||||
for (TemplateUtil template : CodeGeneratorInternalTemplatesFactoryProvider.getInstance().getTemplates()) {
|
||||
Bundle b = Platform.getBundle(template.getJetPluginRepository());
|
||||
URL resourcesUrl = null;
|
||||
try {
|
||||
resourcesUrl = FileLocator.toFileURL(FileLocator.find(b, new Path(template.getTemplateRelativeUri()), null));
|
||||
resourcesUrl = FileLocator.toFileURL(ComponentBundleToPath.findComponentsBundleURL(template.getJetPluginRepository(), new Path(template.getTemplateRelativeUri()), null));
|
||||
} catch (IOException e) {
|
||||
ExceptionHandler.process(e);
|
||||
}
|
||||
|
||||
@@ -9,6 +9,14 @@
|
||||
id="org.talend.designer.components.exchange.ExchangeComponentsProvider">
|
||||
</ComponentsProvider>
|
||||
</extension>
|
||||
<extension
|
||||
point="org.talend.core.components_provider">
|
||||
<ComponentsProvider
|
||||
class="org.talend.designer.components.exchange.SharedStudioExchangeComponentsProvider"
|
||||
folderName="exchange"
|
||||
id="org.talend.designer.components.exchange.SharedStudioExchangeComponentsProvider">
|
||||
</ComponentsProvider>
|
||||
</extension>
|
||||
<extension
|
||||
point="org.talend.core.runtime.service">
|
||||
<Service
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
<parent>
|
||||
<groupId>org.talend.studio</groupId>
|
||||
<artifactId>tdi-studio-se</artifactId>
|
||||
<version>7.3.1-SNAPSHOT</version>
|
||||
<version>7.3.1-PATCH</version>
|
||||
<relativePath>../../../</relativePath>
|
||||
</parent>
|
||||
<artifactId>org.talend.designer.components.exchange</artifactId>
|
||||
|
||||
@@ -28,13 +28,15 @@ import org.talend.core.GlobalServiceRegister;
|
||||
import org.talend.core.model.components.AbstractComponentsProvider;
|
||||
import org.talend.core.model.components.ComponentUtilities;
|
||||
import org.talend.core.model.components.IComponentsFactory;
|
||||
import org.talend.core.runtime.util.SharedStudioInfoProvider;
|
||||
import org.talend.core.runtime.util.SharedStudioUtils;
|
||||
import org.talend.core.ui.branding.IBrandingService;
|
||||
import org.talend.designer.components.exchange.util.ExchangeUtils;
|
||||
|
||||
/**
|
||||
* DOC hcyi class global comment. Detailled comment
|
||||
*/
|
||||
public class ExchangeComponentsProvider extends AbstractComponentsProvider {
|
||||
public class ExchangeComponentsProvider extends AbstractComponentsProvider implements SharedStudioInfoProvider{
|
||||
|
||||
/**
|
||||
* ExchangeComponentsProvider constructor.
|
||||
@@ -184,4 +186,10 @@ public class ExchangeComponentsProvider extends AbstractComponentsProvider {
|
||||
return IComponentsFactory.COMPONENTS_LOCATION;
|
||||
}
|
||||
|
||||
public boolean isSupportCurrentMode() {
|
||||
if (SharedStudioUtils.isSharedStudioMode()) {
|
||||
return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,59 @@
|
||||
package org.talend.designer.components.exchange;
|
||||
//============================================================================
|
||||
//
|
||||
//Copyright (C) 2006-2019 Talend Inc. - www.talend.com
|
||||
//
|
||||
//This source code is available under agreement available at
|
||||
//%InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt
|
||||
//
|
||||
//You should have received a copy of the agreement
|
||||
//along with this program; if not, write to Talend SA
|
||||
//9 rue Pages 92150 Suresnes, France
|
||||
//
|
||||
//============================================================================
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.net.URL;
|
||||
import java.net.URLClassLoader;
|
||||
import java.util.ResourceBundle;
|
||||
|
||||
import org.eclipse.core.runtime.IPath;
|
||||
import org.eclipse.core.runtime.Path;
|
||||
import org.eclipse.core.runtime.Platform;
|
||||
import org.talend.core.model.components.ComponentUtilities;
|
||||
import org.talend.core.model.components.IComponentsFactory;
|
||||
import org.talend.core.runtime.util.ComponentsLocationProvider;
|
||||
import org.talend.core.runtime.util.SharedStudioUtils;
|
||||
import org.talend.designer.core.model.components.ComponentBundleToPath;
|
||||
|
||||
public class SharedStudioExchangeComponentsProvider extends ExchangeComponentsProvider implements ComponentsLocationProvider{
|
||||
@Override
|
||||
public File getInstallationFolder() throws IOException {
|
||||
File componentFolder = SharedStudioUtils.getSharedStudioComponentsParentFolder();
|
||||
IPath path = new Path(IComponentsFactory.COMPONENTS_INNER_FOLDER);
|
||||
path = path.append(IComponentsFactory.EXTERNAL_COMPONENTS_INNER_FOLDER).append(ComponentUtilities.getExtFolder(getFolderName()));
|
||||
File installationFolder = new File (componentFolder, path.toOSString());
|
||||
return installationFolder;
|
||||
}
|
||||
|
||||
|
||||
public String getComponentsBundle() {
|
||||
return ComponentBundleToPath.SHARED_STUDIO_CUSTOM_COMPONENT_BUNDLE;
|
||||
}
|
||||
|
||||
public boolean isSupportCurrentMode() {
|
||||
if (SharedStudioUtils.isSharedStudioMode()) {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ResourceBundle getResourceBundle(String label) {
|
||||
URL configFolderUrl = Platform.getConfigurationLocation().getURL();
|
||||
URLClassLoader urlLoader = new URLClassLoader(new java.net.URL[]{configFolderUrl});
|
||||
java.util.ResourceBundle bundle = java.util.ResourceBundle.getBundle( label ,
|
||||
java.util.Locale.getDefault(), urlLoader );
|
||||
return bundle;
|
||||
}
|
||||
}
|
||||
@@ -52,6 +52,7 @@ import org.talend.core.download.IDownloadHelper;
|
||||
import org.talend.core.model.components.ComponentManager;
|
||||
import org.talend.core.model.components.IComponent;
|
||||
import org.talend.core.model.components.IComponentsFactory;
|
||||
import org.talend.core.runtime.util.SharedStudioUtils;
|
||||
import org.talend.core.ui.component.ComponentPaletteUtilities;
|
||||
import org.talend.core.ui.component.ComponentsFactoryProvider;
|
||||
import org.talend.designer.codegen.ICodeGeneratorService;
|
||||
@@ -312,51 +313,54 @@ public class DownloadComponenentsAction extends Action implements IIntroAction {
|
||||
|
||||
protected void afterDownload(IProgressMonitor monitor, ComponentExtension extension, File localZipFile) throws Exception {
|
||||
if (UpdatesHelper.isComponentUpdateSite(localZipFile)) {
|
||||
final File workFolder = org.talend.utils.files.FileUtils.createTmpFolder("downloadedComponents", ""); //$NON-NLS-1$ //$NON-NLS-2$
|
||||
if (!SharedStudioUtils.isSharedStudioMode()) {
|
||||
final File workFolder = org.talend.utils.files.FileUtils.createTmpFolder("downloadedComponents", ""); //$NON-NLS-1$ //$NON-NLS-2$
|
||||
|
||||
try {
|
||||
FilesUtils.copyFile(localZipFile, new File(workFolder, localZipFile.getName()));
|
||||
try {
|
||||
FilesUtils.copyFile(localZipFile, new File(workFolder, localZipFile.getName()));
|
||||
|
||||
ComponentsInstallComponent component = LocalComponentInstallHelper.getComponent();
|
||||
if (component != null) {
|
||||
try {
|
||||
component.setComponentFolder(workFolder);
|
||||
if (component.install()) {
|
||||
ComponentsInstallComponent component = LocalComponentInstallHelper.getComponent();
|
||||
if (component != null) {
|
||||
try {
|
||||
component.setComponentFolder(workFolder);
|
||||
if (component.install()) {
|
||||
|
||||
if (component.needRelaunch()) {
|
||||
askReboot();
|
||||
} else {
|
||||
MessageDialog.openInformation(DisplayUtils.getDefaultShell(),
|
||||
Messages.getString("DownloadComponenentsAction.installComponentsTitle"),
|
||||
component.getInstalledMessages());
|
||||
|
||||
if (component.needRelaunch()) {
|
||||
askReboot();
|
||||
} else {
|
||||
MessageDialog.openInformation(DisplayUtils.getDefaultShell(),
|
||||
Messages.getString("DownloadComponenentsAction.installComponentsTitle"),
|
||||
component.getInstalledMessages());
|
||||
}
|
||||
} else {// install failure
|
||||
MessageDialog.openWarning(DisplayUtils.getDefaultShell(),
|
||||
Messages.getString("DownloadComponenentsAction_failureTitle"), //$NON-NLS-1$
|
||||
Messages.getString("DownloadComponenentsAction_failureMessage", extension.getLabel())); //$NON-NLS-1$
|
||||
}
|
||||
} else {// install failure
|
||||
MessageDialog.openWarning(DisplayUtils.getDefaultShell(),
|
||||
} finally {
|
||||
// after install, clear the setting for service.
|
||||
component.setComponentFolder(null);
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
// Popup dialog to user to waring install failed.
|
||||
Display.getDefault().syncExec(new Runnable() {
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
MessageDialog.openError(DisplayUtils.getDefaultShell(false),
|
||||
Messages.getString("DownloadComponenentsAction_failureTitle"), //$NON-NLS-1$
|
||||
Messages.getString("DownloadComponenentsAction_failureMessage", extension.getLabel())); //$NON-NLS-1$
|
||||
}
|
||||
} finally {
|
||||
// after install, clear the setting for service.
|
||||
component.setComponentFolder(null);
|
||||
}
|
||||
});
|
||||
throw e;
|
||||
} finally {
|
||||
FilesUtils.deleteFolder(workFolder, true);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
// Popup dialog to user to waring install failed.
|
||||
Display.getDefault().syncExec(new Runnable() {
|
||||
|
||||
@Override
|
||||
public void run() {
|
||||
MessageDialog.openError(DisplayUtils.getDefaultShell(false),
|
||||
Messages.getString("DownloadComponenentsAction_failureTitle"), //$NON-NLS-1$
|
||||
Messages.getString("DownloadComponenentsAction_failureMessage", extension.getLabel())); //$NON-NLS-1$
|
||||
}
|
||||
});
|
||||
throw e;
|
||||
} finally {
|
||||
FilesUtils.deleteFolder(workFolder, true);
|
||||
}
|
||||
monitor.done();
|
||||
ExchangeManager.getInstance().saveDownloadedExtensionsToFile(extension);
|
||||
monitor.done();
|
||||
ExchangeManager.getInstance().saveDownloadedExtensionsToFile(extension);
|
||||
}
|
||||
} else {
|
||||
File installedLocation = ComponentInstaller.unzip(localZipFile.getAbsolutePath(), getComponentsFolder()
|
||||
.getAbsolutePath());
|
||||
|
||||
@@ -55,6 +55,7 @@ import org.talend.core.language.ECodeLanguage;
|
||||
import org.talend.core.language.LanguageManager;
|
||||
import org.talend.core.model.components.IComponentsFactory;
|
||||
import org.talend.core.model.general.Project;
|
||||
import org.talend.core.runtime.util.SharedStudioUtils;
|
||||
import org.talend.core.ui.component.ComponentPaletteUtilities;
|
||||
import org.talend.core.ui.component.ComponentsFactoryProvider;
|
||||
import org.talend.designer.components.exchange.ExchangePlugin;
|
||||
@@ -205,14 +206,19 @@ public class ExchangeUtils {
|
||||
* @return
|
||||
*/
|
||||
public static File getComponentFolder(String componentfolder) {
|
||||
URL url = FileLocator.find(ExchangePlugin.getDefault().getBundle(), new Path(componentfolder), null);
|
||||
try {
|
||||
URL fileUrl = FileLocator.toFileURL(url);
|
||||
return new File(fileUrl.getPath());
|
||||
} catch (Exception e) {
|
||||
ExceptionHandler.process(e);
|
||||
}
|
||||
return null;
|
||||
if (SharedStudioUtils.isSharedStudioMode()) {
|
||||
File componentFolder = SharedStudioUtils.getSharedStudioComponentsExtFolder();
|
||||
return new File (componentFolder, componentfolder);
|
||||
} else {
|
||||
URL url = FileLocator.find(ExchangePlugin.getDefault().getBundle(), new Path(componentfolder), null);
|
||||
try {
|
||||
URL fileUrl = FileLocator.toFileURL(url);
|
||||
return new File(fileUrl.getPath());
|
||||
} catch (Exception e) {
|
||||
ExceptionHandler.process(e);
|
||||
}
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
|
||||
<!-- modification 2: compile classpath -->
|
||||
<path id="compile.classpath">
|
||||
<pathelement location="../../../../../../tcommon-studio-se/main/plugins/org.talend.libraries.dom4j-jaxen/lib/dom4j-1.6.1.jar" />
|
||||
<pathelement location="../../../../../../tcommon-studio-se/main/plugins/org.talend.libraries.dom4j-jaxen/lib/dom4j-2.1.3.jar" />
|
||||
<pathelement location="../../../../../../tcommon-studio-se/main/plugins/org.talend.libraries.apache.common/lib/commons-lang-2.6.jar" />
|
||||
</path>
|
||||
|
||||
|
||||
@@ -2,7 +2,6 @@
|
||||
<project name="org.talend.designer.components.libs" default="buildall" basedir=".">
|
||||
|
||||
<target name="buildall">
|
||||
<ant antfile="talend_file_enhanced_20070724/build.xml" target="process" inheritall="no" />
|
||||
<ant antfile="sugarCRMManagement/build.xml" target="process" inheritall="no" />
|
||||
<ant antfile="TalendSAX/build.xml" target="process" inheritall="no" />
|
||||
</target>
|
||||
|
||||
@@ -3,11 +3,32 @@
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.talend.components.lib</groupId>
|
||||
<artifactId>commons-net-ftps-proxy</artifactId>
|
||||
<version>3.6.1-talend-20190819</version>
|
||||
<version>3.6.1-talend-20200902</version>
|
||||
|
||||
<name>commons-net-talend</name>
|
||||
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<talend.nexus.url>https://artifacts-oss.talend.com</talend.nexus.url>
|
||||
<slf4.version>1.7.25</slf4.version>
|
||||
<lombok.version>1.18.12</lombok.version>
|
||||
</properties>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>${lombok.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.slf4j</groupId>
|
||||
<artifactId>slf4j-api</artifactId>
|
||||
<version>${slf4.version}</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>commons-net</groupId>
|
||||
<artifactId>commons-net</artifactId>
|
||||
@@ -15,10 +36,6 @@
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<properties>
|
||||
<talend.nexus.url>https://artifacts-oss.talend.com</talend.nexus.url>
|
||||
</properties>
|
||||
|
||||
<distributionManagement>
|
||||
<snapshotRepository>
|
||||
<id>talend_nexus_deployment</id>
|
||||
|
||||
@@ -11,8 +11,10 @@ import javax.net.ssl.SSLSession;
|
||||
import javax.net.ssl.SSLSessionContext;
|
||||
import javax.net.ssl.SSLSocket;
|
||||
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.net.ftp.FTPSClient;
|
||||
|
||||
@Slf4j
|
||||
public class SSLSessionReuseFTPSClient extends FTPSClient {
|
||||
|
||||
public SSLSessionReuseFTPSClient(boolean isImplicit, SSLContext context) {
|
||||
@@ -24,6 +26,12 @@ public class SSLSessionReuseFTPSClient extends FTPSClient {
|
||||
if (socket instanceof SSLSocket) {
|
||||
final SSLSession session = ((SSLSocket) _socket_).getSession();
|
||||
final SSLSessionContext context = session.getSessionContext();
|
||||
if (context == null) {
|
||||
// TDI-44654 (may be reproduced with Syncplify server)
|
||||
log.info("SSL Session Context is null. SSL Session was re-initialized.");
|
||||
return;
|
||||
}
|
||||
|
||||
try {
|
||||
final Field sessionHostPortCache = context.getClass().getDeclaredField("sessionHostPortCache");
|
||||
sessionHostPortCache.setAccessible(true);
|
||||
@@ -32,10 +40,10 @@ public class SSLSessionReuseFTPSClient extends FTPSClient {
|
||||
putMethod.setAccessible(true);
|
||||
InetAddress address = socket.getInetAddress();
|
||||
int port = socket.getPort();
|
||||
|
||||
|
||||
String key = String.format("%s:%s", address.getHostName(), String.valueOf(port)).toLowerCase(Locale.ROOT);
|
||||
putMethod.invoke(cache, key, session);
|
||||
|
||||
|
||||
key = String.format("%s:%s", address.getHostAddress(), String.valueOf(port)).toLowerCase(Locale.ROOT);
|
||||
putMethod.invoke(cache, key, session);
|
||||
} catch (Exception e) {
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.talend.libraries</groupId>
|
||||
<groupId>org.talend.components</groupId>
|
||||
<artifactId>filecopy</artifactId>
|
||||
<version>2.0.0</version>
|
||||
<version>2.0.1</version>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<name>talend-copy</name>
|
||||
|
||||
@@ -15,7 +15,10 @@ package org.talend;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.nio.file.Files;
|
||||
import java.nio.file.Path;
|
||||
import java.nio.file.Paths;
|
||||
import java.nio.file.StandardCopyOption;
|
||||
import java.nio.file.attribute.FileTime;
|
||||
|
||||
/**
|
||||
* DOC Administrator class global comment. Detailled comment
|
||||
@@ -35,14 +38,17 @@ public class FileCopy {
|
||||
* @throws IOException : if IO pb.
|
||||
*/
|
||||
public static void copyFile(String srcFileName, String desFileName, boolean delSrc) throws IOException {
|
||||
final File source = new File(srcFileName);
|
||||
final File destination = new File(desFileName);
|
||||
final Path source = Paths.get(srcFileName);
|
||||
final Path destination = Paths.get(desFileName);
|
||||
|
||||
if (delSrc) {
|
||||
// move : more efficient if in same FS and mustr delete existing file.
|
||||
Files.move(source.toPath(), destination.toPath(), StandardCopyOption.REPLACE_EXISTING);
|
||||
FileTime lastModifiedTime = Files.getLastModifiedTime(source);
|
||||
Files.move(source, destination, StandardCopyOption.REPLACE_EXISTING);
|
||||
Files.setLastModifiedTime(destination,lastModifiedTime);
|
||||
} else {
|
||||
Files.copy(source.toPath(), destination.toPath(), StandardCopyOption.REPLACE_EXISTING);
|
||||
Files.copy(source, destination, StandardCopyOption.REPLACE_EXISTING);
|
||||
Files.setLastModifiedTime(destination,Files.getLastModifiedTime(source));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -100,6 +100,24 @@ class FileCopyTest {
|
||||
Assertions.assertEquals(referenceSize, copy.length(), "Size error");
|
||||
}
|
||||
|
||||
@Test
|
||||
void testLastModifiedTime() throws Exception {
|
||||
final URL repCopy = Thread.currentThread().getContextClassLoader().getResource("copy");
|
||||
|
||||
File file = this.buildFile("fileLMT.txt", 10L * 1024L);
|
||||
file.deleteOnExit();
|
||||
long referencceTime = 324723894L;
|
||||
file.setLastModified(referencceTime);
|
||||
|
||||
File copy = new File(repCopy.getPath(), "fileLMTDestination.txt");
|
||||
if (copy.exists()) {
|
||||
copy.delete();
|
||||
}
|
||||
copy.deleteOnExit();
|
||||
FileCopy.copyFile(file.getPath(), copy.getPath(), true);
|
||||
Assertions.assertEquals(referencceTime, copy.lastModified(), "modified time is not idential");
|
||||
}
|
||||
|
||||
/**
|
||||
* Generate a new file for testing.
|
||||
*
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
<groupId>org.talend.components</groupId>
|
||||
<artifactId>google-storage-utils</artifactId>
|
||||
<version>1.0.0</version>
|
||||
<version>1.1.0</version>
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<talend.nexus.url>https://artifacts-oss.talend.com</talend.nexus.url>
|
||||
@@ -46,6 +46,12 @@
|
||||
<artifactId>jets3t</artifactId>
|
||||
<version>0.9.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.junit.jupiter</groupId>
|
||||
<artifactId>junit-jupiter-api</artifactId>
|
||||
<version>5.6.2</version>
|
||||
<scope>test</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<distributionManagement>
|
||||
<snapshotRepository>
|
||||
@@ -64,8 +70,8 @@
|
||||
<artifactId>maven-compiler-plugin</artifactId>
|
||||
<version>2.3.2</version>
|
||||
<configuration>
|
||||
<source>1.6</source>
|
||||
<target>1.6</target>
|
||||
<source>8</source>
|
||||
<target>8</target>
|
||||
</configuration>
|
||||
</plugin>
|
||||
<plugin>
|
||||
|
||||
@@ -3,10 +3,13 @@ package org.talend.gs.util;
|
||||
import java.io.File;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.nio.file.FileSystems;
|
||||
import java.security.NoSuchAlgorithmException;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.Set;
|
||||
|
||||
import org.jets3t.service.model.GSObject;
|
||||
@@ -44,6 +47,50 @@ public class GSObjectUtil {
|
||||
return objects;
|
||||
}
|
||||
|
||||
public Map<String, File> generateFileMap(File rootFile, String directory, Map<String, String> filter){
|
||||
Map<String, File> allFiles = generateFileMap(rootFile, directory);
|
||||
Map<String, File> resultMap = new HashMap<>();
|
||||
for (Map.Entry<String, String> entry : filter.entrySet()) {
|
||||
//key is path to file on local machine
|
||||
//value is new path in GS
|
||||
File currentFile = new File(entry.getKey());
|
||||
if (allFiles.containsValue(currentFile)){
|
||||
resultMap.put(entry.getValue(), currentFile);
|
||||
}
|
||||
}
|
||||
return resultMap;
|
||||
}
|
||||
|
||||
public Map<String, File> generateFileMap(File rootFile, String directory){
|
||||
if (rootFile == null){
|
||||
throw new IllegalArgumentException("File can't be null");
|
||||
}
|
||||
if (directory == null){
|
||||
throw new IllegalArgumentException("Directory name can't be null");
|
||||
}
|
||||
|
||||
if (!directory.isEmpty() && !"/".equals(directory.substring(directory.length()-1))){
|
||||
directory = directory + "/";
|
||||
}
|
||||
|
||||
Map<String,File> fileMap = new HashMap<>();
|
||||
|
||||
if (!rootFile.isDirectory()){
|
||||
fileMap.put(directory + rootFile.getName(), rootFile);
|
||||
return fileMap;
|
||||
}
|
||||
|
||||
String pathToDirectory = rootFile.getAbsolutePath();
|
||||
List<File> allFiles = listAllFiles(pathToDirectory);
|
||||
|
||||
for (File currentFile : allFiles){
|
||||
if (!currentFile.isDirectory()){
|
||||
fileMap.put(combineTwoNames(pathToDirectory, directory, currentFile), currentFile);
|
||||
}
|
||||
}
|
||||
return fileMap;
|
||||
}
|
||||
|
||||
public java.util.Map<String, String> genFileFilterList(java.util.List<java.util.Map<String, String>> list,
|
||||
String localdir, String remotedir) {
|
||||
if (remotedir != null && !"".equals(remotedir)) {
|
||||
@@ -120,4 +167,23 @@ public class GSObjectUtil {
|
||||
InputStream mimetypesFile = this.getClass().getResourceAsStream("/resource/mime.types");
|
||||
Mimetypes.getInstance().loadAndReplaceMimetypes(mimetypesFile);
|
||||
}
|
||||
|
||||
private List<File> listAllFiles(String directoryName) {
|
||||
File directory = new File(directoryName);
|
||||
List<File> resultList = new ArrayList<>();
|
||||
File[] fList = directory.listFiles();
|
||||
resultList.addAll(Arrays.asList(fList));
|
||||
for (File file : fList) {
|
||||
if (file.isDirectory()) {
|
||||
resultList.addAll(listAllFiles(file.getAbsolutePath()));
|
||||
}
|
||||
}
|
||||
return resultList;
|
||||
}
|
||||
|
||||
private String combineTwoNames(String coreDir, String targetDir, File file){
|
||||
String filePath = file.getAbsolutePath();
|
||||
String relativePath = targetDir + filePath.replace(coreDir + FileSystems.getDefault().getSeparator(), "");
|
||||
return relativePath.replaceAll("\\\\","/");
|
||||
}
|
||||
}
|
||||
|
||||
@@ -0,0 +1,131 @@
|
||||
package util;
|
||||
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.talend.gs.util.GSObjectUtil;
|
||||
|
||||
import java.io.File;
|
||||
import java.nio.file.Path;
|
||||
import java.nio.file.Paths;
|
||||
import java.util.Map;
|
||||
|
||||
import static org.junit.jupiter.api.Assertions.*;
|
||||
|
||||
class GSObjectUtilTest {
|
||||
|
||||
@Test
|
||||
void checkSizeOfFilesInFolderTest() {
|
||||
Path pathToDirectory = Paths.get("src", "test", "resources", "dirWithThreeFiles");
|
||||
Path pathToFile1 = Paths.get("src", "test", "resources", "dirWithThreeFiles", "1.csv");
|
||||
Path pathToFile2 = Paths.get("src", "test", "resources", "dirWithThreeFiles", "2.csv");
|
||||
Path pathToFile3 = Paths.get("src", "test", "resources", "dirWithThreeFiles", "3.csv");
|
||||
Path pathToFile4 = Paths.get("src", "test", "resources", "dirWithThreeFiles", "inner", "1.csv");
|
||||
|
||||
String expectedRelativePathToFile1 = "/1.csv";
|
||||
String expectedRelativePathToFile2 = "/2.csv";
|
||||
String expectedRelativePathToFile3 = "/3.csv";
|
||||
String expectedRelativePathToFile4 = "/inner/1.csv";
|
||||
|
||||
File rootFile = new File(pathToDirectory.toUri());
|
||||
GSObjectUtil gsObjectUtil = new GSObjectUtil();
|
||||
Map<String, File> files = gsObjectUtil.generateFileMap(rootFile, "/");
|
||||
assertEquals(4, files.size());
|
||||
|
||||
File expectedFile1 = new File(pathToFile1.toUri());
|
||||
File expectedFile2 = new File(pathToFile2.toUri());
|
||||
File expectedFile3 = new File(pathToFile3.toUri());
|
||||
File expectedFile4 = new File(pathToFile4.toUri());
|
||||
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile1));
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile2));
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile3));
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile4));
|
||||
|
||||
assertEquals(expectedFile1.getAbsoluteFile(), files.get(expectedRelativePathToFile1).getAbsoluteFile());
|
||||
assertEquals(expectedFile2.getAbsoluteFile(), files.get(expectedRelativePathToFile2).getAbsoluteFile());
|
||||
assertEquals(expectedFile3.getAbsoluteFile(), files.get(expectedRelativePathToFile3).getAbsoluteFile());
|
||||
assertEquals(expectedFile4.getAbsoluteFile(), files.get(expectedRelativePathToFile4).getAbsoluteFile());
|
||||
}
|
||||
|
||||
@Test
|
||||
void checkSizeOfFilesInFolder2Test() {
|
||||
Path pathToDirectory = Paths.get("src", "test", "resources", "dirWithThreeFiles");
|
||||
Path pathToFile1 = Paths.get("src", "test", "resources", "dirWithThreeFiles", "1.csv");
|
||||
Path pathToFile2 = Paths.get("src", "test", "resources", "dirWithThreeFiles", "2.csv");
|
||||
Path pathToFile3 = Paths.get("src", "test", "resources", "dirWithThreeFiles", "3.csv");
|
||||
Path pathToFile4 = Paths.get("src", "test", "resources", "dirWithThreeFiles", "inner", "1.csv");
|
||||
|
||||
String expectedRelativePathToFile1 = "1.csv";
|
||||
String expectedRelativePathToFile2 = "2.csv";
|
||||
String expectedRelativePathToFile3 = "3.csv";
|
||||
String expectedRelativePathToFile4 = "inner/1.csv";
|
||||
|
||||
File rootFile = new File(pathToDirectory.toUri());
|
||||
GSObjectUtil gsObjectUtil = new GSObjectUtil();
|
||||
Map<String, File> files = gsObjectUtil.generateFileMap(rootFile, "");
|
||||
assertEquals(4, files.size());
|
||||
|
||||
File expectedFile1 = new File(pathToFile1.toUri());
|
||||
File expectedFile2 = new File(pathToFile2.toUri());
|
||||
File expectedFile3 = new File(pathToFile3.toUri());
|
||||
File expectedFile4 = new File(pathToFile4.toUri());
|
||||
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile1));
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile2));
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile3));
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile4));
|
||||
|
||||
assertEquals(expectedFile1.getAbsoluteFile(), files.get(expectedRelativePathToFile1).getAbsoluteFile());
|
||||
assertEquals(expectedFile2.getAbsoluteFile(), files.get(expectedRelativePathToFile2).getAbsoluteFile());
|
||||
assertEquals(expectedFile3.getAbsoluteFile(), files.get(expectedRelativePathToFile3).getAbsoluteFile());
|
||||
assertEquals(expectedFile4.getAbsoluteFile(), files.get(expectedRelativePathToFile4).getAbsoluteFile());
|
||||
}
|
||||
|
||||
@Test
|
||||
void oneFileWithCustomPathTest(){
|
||||
Path pathToFile = Paths.get("src","test", "resources", "empty.csv");
|
||||
String pathToFolder = "/folder/folder";
|
||||
File expectedFile = new File(pathToFile.toUri());
|
||||
GSObjectUtil gsObjectUtil = new GSObjectUtil();
|
||||
|
||||
Map<String, File> files = gsObjectUtil.generateFileMap(expectedFile, pathToFolder);
|
||||
|
||||
String expectedRelativePathToFile = "/folder/folder/empty.csv";
|
||||
|
||||
assertEquals(1, files.size());
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile));
|
||||
assertEquals(expectedFile.getAbsoluteFile(), files.get(expectedRelativePathToFile).getAbsoluteFile());
|
||||
}
|
||||
|
||||
@Test
|
||||
void oneFileWithOtherCustomPathTest(){
|
||||
Path pathToFile = Paths.get("src","test", "resources", "empty.csv");
|
||||
String pathToFolder = "folder/folder";
|
||||
File expectedFile = new File(pathToFile.toUri());
|
||||
GSObjectUtil gsObjectUtil = new GSObjectUtil();
|
||||
|
||||
Map<String, File> files = gsObjectUtil.generateFileMap(expectedFile, pathToFolder);
|
||||
|
||||
String expectedRelativePathToFile = "folder/folder/empty.csv";
|
||||
|
||||
assertEquals(1, files.size());
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile));
|
||||
assertEquals(expectedFile.getAbsoluteFile(), files.get(expectedRelativePathToFile).getAbsoluteFile());
|
||||
}
|
||||
|
||||
@Test
|
||||
void folderWithOtherCustomPathTest(){
|
||||
Path pathToFolder = Paths.get("src", "test", "resources", "dirWithThreeFiles", "inner");
|
||||
String pathToGSFolder = "folder";
|
||||
File folder = new File(pathToFolder.toUri());
|
||||
GSObjectUtil gsObjectUtil = new GSObjectUtil();
|
||||
|
||||
Map<String, File> files = gsObjectUtil.generateFileMap(folder, pathToGSFolder);
|
||||
|
||||
String expectedRelativePathToFile = "folder/1.csv";
|
||||
File expectedFile = new File(pathToFolder + "/1.csv");
|
||||
|
||||
assertEquals(1, files.size());
|
||||
assertTrue(files.containsKey(expectedRelativePathToFile));
|
||||
assertEquals(expectedFile.getAbsoluteFile(), files.get(expectedRelativePathToFile).getAbsoluteFile());
|
||||
}
|
||||
}
|
||||
|
|
|
|
|
|
|
|
|
|
@@ -170,7 +170,7 @@
|
||||
<dependency>
|
||||
<groupId>commons-beanutils</groupId>
|
||||
<artifactId>commons-beanutils</artifactId>
|
||||
<version>1.8.0</version>
|
||||
<version>1.9.4</version>
|
||||
<scope>compile</scope>
|
||||
</dependency>
|
||||
<dependency>
|
||||
@@ -310,7 +310,7 @@
|
||||
<link>http://java.sun.com/j2se/1.5.0/docs/api/</link>
|
||||
<link>http://www.junit.org/junit/javadoc/</link>
|
||||
<link>
|
||||
http://jakarta.apache.org/commons/beanutils/commons-beanutils-1.7.0/docs/api/
|
||||
http://jakarta.apache.org/commons/beanutils/commons-beanutils-1.9.4/docs/api/
|
||||
</link>
|
||||
<link>
|
||||
http://jakarta.apache.org/commons/lang/api-2.2/
|
||||
|
||||
@@ -51,7 +51,8 @@ public abstract class AbstractJSONObjectStaticBuildersTestCase extends TestCase
|
||||
jsonConfig.setIgnoreDefaultExcludes( true );
|
||||
JSONObject json = JSONObject.fromObject( getSource(), jsonConfig );
|
||||
assertJSONObject( json, getProperties() );
|
||||
assertTrue( json.has( "class" ) );
|
||||
//see : https://github.com/apache/commons-beanutils/compare/BEANUTILS_1_9_3...commons-beanutils-1.9.4#diff-dbeaa70d3a09169fb5a1e42e5b319037R34-R43
|
||||
//assertTrue( json.has( "class" ) );
|
||||
assertTrue( !json.has( "pexcluded" ) );
|
||||
}
|
||||
|
||||
|
||||
@@ -199,7 +199,8 @@ public class TestJSONObject extends TestCase {
|
||||
jsonConfig.setIgnoreDefaultExcludes( true );
|
||||
jsonObject.element( "bean", new ObjectBean(), jsonConfig );
|
||||
JSONObject actual = jsonObject.getJSONObject( "bean" );
|
||||
Assertions.assertTrue( actual.has( "class" ) );
|
||||
//see : https://github.com/apache/commons-beanutils/compare/BEANUTILS_1_9_3...commons-beanutils-1.9.4#diff-dbeaa70d3a09169fb5a1e42e5b319037R34-R43
|
||||
//Assertions.assertTrue( actual.has( "class" ) );
|
||||
Assertions.assertTrue( !actual.has( "pexcluded" ) );
|
||||
}
|
||||
|
||||
@@ -258,7 +259,8 @@ public class TestJSONObject extends TestCase {
|
||||
jsonObject.element( "list", list, jsonConfig );
|
||||
JSONObject actual = jsonObject.getJSONArray( "list" )
|
||||
.getJSONObject( 0 );
|
||||
Assertions.assertTrue( actual.has( "class" ) );
|
||||
//see : https://github.com/apache/commons-beanutils/compare/BEANUTILS_1_9_3...commons-beanutils-1.9.4#diff-dbeaa70d3a09169fb5a1e42e5b319037R34-R43
|
||||
//Assertions.assertTrue( actual.has( "class" ) );
|
||||
Assertions.assertTrue( !actual.has( "pexcluded" ) );
|
||||
}
|
||||
|
||||
|
||||
@@ -13,9 +13,9 @@
|
||||
<optional>true</optional>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>dom4j</groupId>
|
||||
<groupId>org.dom4j</groupId>
|
||||
<artifactId>dom4j</artifactId>
|
||||
<version>1.6.1</version>
|
||||
<version>2.1.3</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-lang</groupId>
|
||||
|
||||
@@ -1,26 +1,64 @@
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.talend</groupId>
|
||||
<groupId>org.talend.libraries</groupId>
|
||||
<artifactId>mdm_transaction</artifactId>
|
||||
<name>mdm_transaction</name>
|
||||
<version>1.0.1</version>
|
||||
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<talend.nexus.url>https://artifacts-oss.talend.com</talend.nexus.url>
|
||||
</properties>
|
||||
|
||||
<distributionManagement>
|
||||
<snapshotRepository>
|
||||
<id>talend_nexus_deployment</id>
|
||||
<url>${talend.nexus.url}/nexus/content/repositories/TalendOpenSourceSnapshot/</url>
|
||||
<snapshots>
|
||||
<enabled>true</enabled>
|
||||
</snapshots>
|
||||
<releases>
|
||||
<enabled>false</enabled>
|
||||
</releases>
|
||||
</snapshotRepository>
|
||||
<repository>
|
||||
<id>talend_nexus_deployment</id>
|
||||
<url>${talend.nexus.url}/nexus/content/repositories/TalendOpenSourceRelease/</url>
|
||||
<snapshots>
|
||||
<enabled>false</enabled>
|
||||
</snapshots>
|
||||
<releases>
|
||||
<enabled>true</enabled>
|
||||
</releases>
|
||||
</repository>
|
||||
</distributionManagement>
|
||||
|
||||
<dependencies>
|
||||
<dependency>
|
||||
<groupId>commons-codec</groupId>
|
||||
<artifactId>commons-codec</artifactId>
|
||||
<version>1.7</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
<version>1.1</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-httpclient</groupId>
|
||||
<artifactId>commons-httpclient</artifactId>
|
||||
<version>3.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-codec</groupId>
|
||||
<artifactId>commons-codec</artifactId>
|
||||
<version>1.7</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-httpclient</groupId>
|
||||
<artifactId>commons-httpclient</artifactId>
|
||||
<version>3.0</version>
|
||||
<exclusions>
|
||||
<exclusion>
|
||||
<groupId>commons-codec</groupId>
|
||||
<artifactId>commons-codec</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>commons-logging</groupId>
|
||||
<artifactId>commons-logging</artifactId>
|
||||
</exclusion>
|
||||
<exclusion>
|
||||
<groupId>junit</groupId>
|
||||
<artifactId>junit</artifactId>
|
||||
</exclusion>
|
||||
</exclusions>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
@@ -49,5 +87,4 @@
|
||||
</testResource>
|
||||
</testResources>
|
||||
</build>
|
||||
<version>1</version>
|
||||
</project>
|
||||
@@ -2,9 +2,9 @@
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
|
||||
<groupId>org.talend.libraries</groupId>
|
||||
<artifactId>simpleexcel-2.2-20190722</artifactId>
|
||||
<version>6.0.0</version>
|
||||
<groupId>org.talend.components</groupId>
|
||||
<artifactId>simpleexcel</artifactId>
|
||||
<version>2.4-20200923</version>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<name>simpleexcel</name>
|
||||
@@ -13,7 +13,7 @@
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<talend.nexus.url>https://artifacts-oss.talend.com</talend.nexus.url>
|
||||
<java.source.version>1.6</java.source.version>
|
||||
<java.source.version>1.8</java.source.version>
|
||||
</properties>
|
||||
|
||||
<distributionManagement>
|
||||
@@ -43,48 +43,30 @@
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi</artifactId>
|
||||
<version>4.1.0</version>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-scratchpad</artifactId>
|
||||
<version>4.1.0</version>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<!-- https://mvnrepository.com/artifact/org.apache.poi/poi-ooxml -->
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-ooxml</artifactId>
|
||||
<version>4.1.0</version>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<!-- https://mvnrepository.com/artifact/org.apache.poi/poi-ooxml-schemas -->
|
||||
<dependency>
|
||||
<groupId>org.apache.poi</groupId>
|
||||
<artifactId>poi-ooxml-schemas</artifactId>
|
||||
<version>4.1.0</version>
|
||||
<version>4.1.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>log4j</groupId>
|
||||
<artifactId>log4j</artifactId>
|
||||
<version>1.2.17</version>
|
||||
</dependency>
|
||||
<!-- https://mvnrepository.com/artifact/org.apache.geronimo.specs/geronimo-stax-api_1.0_spec -->
|
||||
<dependency>
|
||||
<groupId>org.apache.geronimo.specs</groupId>
|
||||
<artifactId>geronimo-stax-api_1.0_spec</artifactId>
|
||||
<version>1.0</version>
|
||||
</dependency>
|
||||
<!-- https://mvnrepository.com/artifact/dom4j/dom4j -->
|
||||
<dependency>
|
||||
<groupId>dom4j</groupId>
|
||||
<artifactId>dom4j</artifactId>
|
||||
<version>1.6.1</version>
|
||||
</dependency>
|
||||
<!-- https://mvnrepository.com/artifact/org.apache.xmlbeans/xmlbeans -->
|
||||
<dependency>
|
||||
<groupId>org.apache.xmlbeans</groupId>
|
||||
<artifactId>xmlbeans</artifactId>
|
||||
<version>3.1.0</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<build>
|
||||
<resources>
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// ============================================================================
|
||||
//
|
||||
// Copyright (C) 2006-2019 Talend Inc. - www.talend.com
|
||||
// Copyright (C) 2006-2020 Talend Inc. - www.talend.com
|
||||
//
|
||||
// This source code is available under agreement available at
|
||||
// %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// ============================================================================
|
||||
//
|
||||
// Copyright (C) 2006-2019 Talend Inc. - www.talend.com
|
||||
// Copyright (C) 2006-2020 Talend Inc. - www.talend.com
|
||||
//
|
||||
// This source code is available under agreement available at
|
||||
// %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// ============================================================================
|
||||
//
|
||||
// Copyright (C) 2006-2019 Talend Inc. - www.talend.com
|
||||
// Copyright (C) 2006-2020 Talend Inc. - www.talend.com
|
||||
//
|
||||
// This source code is available under agreement available at
|
||||
// %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// ============================================================================
|
||||
//
|
||||
// Copyright (C) 2006-2019 Talend Inc. - www.talend.com
|
||||
// Copyright (C) 2006-2020 Talend Inc. - www.talend.com
|
||||
//
|
||||
// This source code is available under agreement available at
|
||||
// %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
// ============================================================================
|
||||
//
|
||||
// Copyright (C) 2006-2019 Talend Inc. - www.talend.com
|
||||
// Copyright (C) 2006-2020 Talend Inc. - www.talend.com
|
||||
//
|
||||
// This source code is available under agreement available at
|
||||
// %InstallDIR%\features\org.talend.rcp.branding.%PRODUCTNAME%\%PRODUCTNAME%license.txt
|
||||
|
||||
@@ -1,16 +1,15 @@
|
||||
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||
<modelVersion>4.0.0</modelVersion>
|
||||
<groupId>org.talend.libraries</groupId>
|
||||
<artifactId>talend-soap</artifactId>
|
||||
<version>2.1-20190716</version>
|
||||
<groupId>org.talend.components</groupId>
|
||||
<artifactId>components-soap</artifactId>
|
||||
<version>2.3-20200918</version>
|
||||
<packaging>jar</packaging>
|
||||
|
||||
<name>talend-soap</name>
|
||||
|
||||
<properties>
|
||||
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
||||
<cxf.version>3.1.1</cxf.version>
|
||||
<talend.nexus.url>https://artifacts-oss.talend.com</talend.nexus.url>
|
||||
</properties>
|
||||
|
||||
@@ -46,29 +45,24 @@
|
||||
<systemPath>${java.home}/lib/rt.jar</systemPath>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>jdom</groupId>
|
||||
<artifactId>jdom</artifactId>
|
||||
<version>1.1</version>
|
||||
<groupId>org.dom4j</groupId>
|
||||
<artifactId>dom4j</artifactId>
|
||||
<version>2.1.3</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>com.sun.xml.messaging.saaj</groupId>
|
||||
<artifactId>saaj-impl</artifactId>
|
||||
<version>1.3.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>javax.activation</groupId>
|
||||
<artifactId>activation</artifactId>
|
||||
<version>1.1</version>
|
||||
<groupId>com.sun.xml.messaging.saaj</groupId>
|
||||
<artifactId>saaj-impl</artifactId>
|
||||
<version>1.5.2</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>xerces</groupId>
|
||||
<artifactId>xercesImpl</artifactId>
|
||||
<version>2.6.2</version>
|
||||
<version>2.12.0</version>
|
||||
</dependency>
|
||||
<dependency>
|
||||
<groupId>commons-codec</groupId>
|
||||
<artifactId>commons-codec</artifactId>
|
||||
<version>1.9</version>
|
||||
<version>1.14</version>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
<build>
|
||||
@@ -108,4 +102,4 @@
|
||||
</plugin>
|
||||
</plugins>
|
||||
</build>
|
||||
</project>
|
||||
</project>
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user