IBM Sterling Transformation Extender

Sterling Transformation Extender

Come for answers, stay for best practices. All we're missing is you.


#Sterling
#Supplychain
 View Only
  • 1.  Java - Custom Functions

    Posted 10/15/08 07:54 PM

    Originally posted by: SystemAdmin


    I'm trying to explore some of the functionality of WTX 8.1. I'd like to implement my own custom function, but I have no experience with C/C++. The example in the Info Center mentions Java (JNI), and I'm much more comfortable with Java.

    I've got the functional lib directory set up as described, but now I'm not sure how to add my java code. Do I just drop the .class file in that directory? What type of make/build/compile process do I have to go through to use a java class?
    #IBMSterlingTransformationExtender
    #IBM-Websphere-Transformation-Extender
    #DataExchange


  • 2.  Re: Java - Custom Functions

    Posted 10/16/08 02:56 PM

    Originally posted by: SystemAdmin


    you just drop the class file in mercator install directory. you need to close and open the map designed. In map designer you find the your functions from java class.
    #IBM-Websphere-Transformation-Extender
    #DataExchange
    #IBMSterlingTransformationExtender


  • 3.  Re: Java - Custom Functions

    Posted 10/16/08 04:54 PM

    Originally posted by: SystemAdmin


    I'm sorry, but I'm not sure I understand what is meant by "find the ... functions from java class."

    When I use the Rules -> Insert Function menu, there is no option to select the functions from the java class.

    Even in Design mode, there's no option to specify java or c/c++. It looks like WTX generates a directory in the WTXinstalldir/function_libs for the new function. This includes .mak files. Do I somehow need to modify these for java? I wouldn't think so?

    If I'm asking elementary questions, please tell me what I need to be searching on. At this point, though, I'm not sure how to proceed.
    #IBMSterlingTransformationExtender
    #IBM-Websphere-Transformation-Extender
    #DataExchange


  • 4.  Re: Java - Custom Functions

    Posted 10/16/08 11:28 PM

    Originally posted by: SystemAdmin


    WTX generates a template in directory WTXinstalldir/function_libs which helps creating custom functions faster.

    I guess the function logic should be written in C and build to create a DLL.Map designer will be able to use the above DLL file. JNI just helps to interface DLL with java environment.
    #DataExchange
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender


  • 5.  Re: Java - Custom Functions

    Posted 10/20/08 07:34 AM

    Originally posted by: SystemAdmin


    Java is not supported through Custom functions directly. C/C++ is only supported for customer functions. There are two options
    1. Write a JNI layer to invoke java from the C/C++ module
    2. In 8.2, JEXIT supports invoking java classes from a Map.
    #DataExchange
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender


  • 6.  Re: Java - Custom Functions

    Posted 10/20/08 10:47 AM

    Originally posted by: SystemAdmin


    Thank you for the information on the Java Native Interface. In my case, it will probably be more work to learn how to do the JNI code than to just write my functions in C++.

    I guess I'll have to dig out my C++ book from college.
    #DataExchange
    #IBM-Websphere-Transformation-Extender
    #IBMSterlingTransformationExtender