Hitachi Vantara Pentaho Community Forums
Results 1 to 2 of 2

Thread: Getting full log content from within a job

  1. #1
    Join Date
    Apr 2014
    Posts
    6

    Question Getting full log content from within a job

    Hi,

    I want to parse and process all log entries from inside a job - including all its sub-jobs, sub-transformations, etc. More or less the full log I'd get as an output using the kitchen command line script parameter.

    What I've tried so far was using the UDJC step to get hold of the root job channel ID and then getting all its children like this:

    Code:
    // Get the root job log interface
    LoggingObjectInterface logObjInterface = getTrans().getParent();
    while (logObjInterface.getParent() != null) {
        logObjInterface = logObjInterface.getParent();
    }
    
    // Get all log events
    LoggingRegistry loggingRegistry = LoggingRegistry.getInstance();
    List childChannelIds = loggingRegistry.getLogChannelChildren(logObjInterface.getLogChannelId());
    List logEvents = KettleLogStore.getLogBufferFromTo(childChannelIds, true, 0, 999999);
    But this seems to only get "some" events (mostly from jobs, but no transformations at all), even though the API documenation for KettleLogStore.getLogBufferFromTo says: Get all the log lines for the specified parent log channel id (including all children)

    How can I get ALL the log entries, ideally as a String of the job I run, please?

    Thanks.

  2. #2
    Join Date
    Apr 2014
    Posts
    6

    Default

    Ok, just about any kind of info on how to get hold of the WHOLE Kettle log from inside a job/transformation would be greatly appreciated

    I might be on a completely wrong track here...

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.