Custom component with dynamic configuration like jira, jdbc or azurestorage in talend

徘徊边缘 提交于 2019-12-25 09:42:28

问题


I want to create a Talend component with dynamic configuration. I tried various sources to achieve that but no luck, apprach I tried previously but I could not able to link the component with plug-in, it always gives the error

failed to load component

then I am trying to create plugins like azure storage I cloned the repo from talend components with dynamic configuraion I developed the new component like azure storage and tried to register in

C:\Users\sandy\Documents\talend\TOS_BD-20161216_1026-V6.3.1\features\org.talend.tos.components.feature_6.3.1.20161216_1026/feature.xml by adding

 <plugin
          id="rg.talend.components.mycomp"
          download-size="0"
          install-size="0"
          version="0.14.0"
          unpack="false"/>

then create a component and installed to Talend. just like other components, Jira, azure, and JDBC, but no luck it didn't show anything that I setup in the code. if anyone has any idea how I can achieve


回答1:


I have found the solution in the Talend git repository, you can create the custom component by following the steps below

  1. setup the maven and java on your machine
  2. go to your workspace and run the following command

    mvn org.apache.maven.plugins:maven-archetype-plugin:2.4:generate -DarchetypeGroupId=org.talend.components -DarchetypeArtifactId=input-component-archetypes -DarchetypeVersion=0.20.0-SNAPSHOT  -DarchetypeRepository=https://artifacts-oss.talend.com/nexus/content/repositories/TalendOpenSourceRelease/
    
  3. meanwhile you are command is running it will ask you few questions like name of the component and version etc.

  4. once you have done with command, it will generate an input component template for you

  5. in the command there is DarchetypeVersion version you can change if you need the different version

     -DarchetypeVersion=0.20.0-SNAPSHOT 
    

    in my case I am using the

     -DarchetypeVersion=0.16.0-SNAPSHOT 
    
  6. now just find the POM.XML file of the component and run the command

      mvn install
    
  7. This command will compile the source code and generate few jar file with different classifiers. jar and bundle
  8. during the compile process you can have errors, for now remove the test classes.
  9. once the source code is compiled, copy the bundle jar file to Talend root->plugins
  10. Restart the Talend Studio
  11. after restarting the Talend search your component in the palette


来源:https://stackoverflow.com/questions/43452212/custom-component-with-dynamic-configuration-like-jira-jdbc-or-azurestorage-in-t

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!