Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I've faced an issue when I wanted to check my custom component in the new versions of Talend (6.5.1 & 7.0.1 M2) Actually, what I see that the component's definition part is not added to the classpath of the job thus it cannot be used. It worked well with 6.4.1.
It's possible to reproduce this issue if you create the sample component based on the documentation.
mvn org.apache.maven.plugins:maven-archetype-plugin:2.4:generate -DarchetypeGroupId=org.talend.components -DarchetypeArtifactId=input-component-archetypes -DarchetypeVersion=0.19.9 -DarchetypeRepository=https://artifacts-oss.talend.com/nexus/content/repositories/TalendOpenSourceRelease/
Expected: When checking the generated code for the job you shouldn't see unresolved types for the component definition classes
Error when the code is generated for the job (run the job) Multiple markers at this line - org.talend.components.file cannot be resolved to a type - org.talend.components.file cannot be resolved to a type
Workaround:
- Add both definition and runtime of the custom component to the job's classpath.
The same issue occurs in v7.0.1 M2 as well. Not to mention that the "tLogRow" is not included in TOS_ESB-20171219_1109-V7.0.1M2 bundle, was it intentionally removed?
Note that the custom component just works fine with Talend Studio (DI / ESB) 6.4.1 without any manual configuration on the classpath.
My question: Did something change in the deploy process for 6.5.1 that the documentation does not cover?
I haven't find related questions issues on the community site yet 😕
Environment:
Thanks,
Zoltán
Hi Zoltán,
Sorry for this late reply and thank you for your Kudo.
What you read in the comment of the jira was actually an assumption of one of our developers and was put to start a discussion within the team. Sorry for this confusion.
Our developer says this issue is linked closely with the default Studio behavior, to the extent of how the Maven offline mode generally works. With the offline mode on by default, the Studio looks at the lastUpdate tag of the maven-metadata-local.xml file of your component and fetch it only when that date is earlier than what the Studio has at the lastUpdate tag in any of the maven-metadata-local.xml files of its existing components. This also explains why this issue can be resolved by clearing the Mave offline check box.
So if you always change the lastUpdate tag of the maven-metadata-local.xml file of your component to a date earlier than that of the Studio when you create your component, this should prevent this issue from coming back.
Thanks,
Yudong
Hi Yudong,
Thanks for getting back to me.
To be honest, it doesn't explain why it worked for v6.4.1 in Maven Offline mode. The maven-metadata-local.xml is auto generated during the deploy phase to the local repository so I wouldn't alter that file manually.
Anyways, it would be great to update the documentation and add these instructions in Developing a component using Talend Component Kit as well for the version as of TOS 6.5.1.
Thanks for your help!
Best,
Zoltán