IBM webMethods Hybrid Integration

IBM webMethods Hybrid Integration

Join this online group to communicate across IBM product users and experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
  • 1.  TN export flow analysis

    Posted Thu April 02, 2009 06:26 PM

    Hi.

    I am currently developing a flow service that will be able to process a xml string with a TN export of the Processing rules.

    I am already able to list all the TN rules by Name, but when I am getting the Document Type ID I get either a null value, or a Document Type: %/document/IDataXMLCoder/record/idatacodable/list/record/array/value%

    The the value exists and is not null/empty.

    Can anyone help?


    #B2B-Integration
    #Integration-Server-and-ESB
    #webMethods


  • 2.  RE: TN export flow analysis

    Posted Fri April 03, 2009 02:15 PM

    Can you please throw some light on what exactly you want to achieve?


    #webMethods
    #Integration-Server-and-ESB
    #B2B-Integration


  • 3.  RE: TN export flow analysis

    Posted Thu April 09, 2009 02:38 PM

    Hi.

    I wanted to do a service that would take as an input a XML string (with the TN export of Processing rules).
    The service would parse the XML to find rules that had diferent Ids but were doing the same thing.

    I started by transforming the XMLstring onto a Node and to a document.
    Retrieve all rules by service called.
    For each service I verify which rules call that service.

    I get a report such as:

    Service: PackageA.FolderA.SubfolderA:ServiceA

    • is used by TN rule: TNRule01
    • is used by TN rule: TNRule02

    From here I would like to be able to check if the TN rules are duplicate, meaning have the same sender/reciever…

    This is no longer urgent as I have already done it by hand…
    But it would be nice to have a service to compare rules for possible duplicates.


    #Integration-Server-and-ESB
    #B2B-Integration
    #webMethods


  • 4.  RE: TN export flow analysis

    Posted Thu April 09, 2009 10:37 PM

    HI,

    We have used the following java service to retrive data from TN export. The below service accepts the TN export file name, and gives an output , and Idata named data. This data is the same as the input to the service wm.tn:importData.

    Basically our idea of doing this was to create an automated backup every week. We use the wm.tn:exportData, and save the IDataBinCoder class to write the data to file (THis is same as doing an export from TN)

    // pipeline
    IDataCursor pipelineCursor = pipeline.getCursor();
    String fileName = IDataUtil.getString( pipelineCursor, “fileName” );
    pipelineCursor.destroy();

    String successFlag=“false”;
    String errorMessage=null;
    IData data = IDataFactory.create();
    try
    {
    File f = new File(fileName);
    IDataBinCoder coder = new IDataBinCoder();
    data = coder.readFromFile(f);
    successFlag=“true”;
    }
    catch(Exception ex)
    {
    successFlag=“false”;
    errorMessage=ex.toString();
    }

    // pipeline
    IDataCursor pipelineCursor_1 = pipeline.getCursor();
    IDataUtil.put( pipelineCursor_1, “data”, data );
    IDataUtil.put( pipelineCursor_1, “successFlag”, successFlag );
    IDataUtil.put( pipelineCursor_1, “errorMessage”, errorMessage );
    pipelineCursor_1.destroy();

    REgards,
    Pradeep


    #webMethods
    #B2B-Integration
    #Integration-Server-and-ESB


  • 5.  RE: TN export flow analysis

    Posted Wed April 15, 2009 10:35 AM

    Hi.
    Just tried your java code, but I am getting the error:
    java:48: cannot find symbol
    symbol : class IDataBinCoder

    What do I need to import?

    Thanks!


    #Integration-Server-and-ESB
    #B2B-Integration
    #webMethods


  • 6.  RE: TN export flow analysis

    Posted Mon April 20, 2009 10:16 AM

    com.wm.util.coder.IDataBinCoder

    Regards,

    Tijs


    #B2B-Integration
    #Integration-Server-and-ESB
    #webMethods