I am new in user of Talend open studio I want to find a way to add component like tinputfile or tligrow without the drag and drop tools , but with java code manually Help please Thank you very much
-
What do you want to do? Can You elaborate more please? – Viki888 Apr 20 '17 at 13:43
-
actually i want to create many tinputfile – hamza elhadj Apr 20 '17 at 15:15
-
i dont have a fixed number for them so i want to add them dynamically – hamza elhadj Apr 20 '17 at 15:16
-
What do you mean by dynamic? Do you mean that you have to read all the files that are located in a folder or directory? – Viki888 Apr 21 '17 at 06:54
3 Answers
I don't think it's possible (in fact I'm quite sure you cannot). When you drag&drop components you "generate" Java source code which is compiled later when you build the job (or run in the studio). How do you expect to change the byte code at run time?
TRF

- 791
- 4
- 9
-
Hi TRF thank you very much for your response i will try to find another process to do my task – hamza elhadj Apr 20 '17 at 19:36
Yes , it is possible to create your own Talend components . There is a very thorough, multi-part tutorial at http://powerupbi.com/talend/componentCreation_1.html
You can also view the source to existing components for an idea of how they are implemented and setup.
Perhaps study how tInputFile is built , make a copy, and extend to your purpose.
Alternatively, if all the files have the same schema and reside in the same directory, you may not need a custom component . Rather create a prenr job which gets a list of files in the directory and loops through each file name. For each file, it would call a sub job to read and process that file .

- 1,607
- 13
- 18
I have provided the all the steps by which you can create the custom component with Java only here is the link to my answer Custom component with dynamic configuration like jira, jdbc or azurestorage in talend

- 443
- 3
- 18