Hitachi Vantara Pentaho Community Forums
Results 1 to 9 of 9

Thread: kettle repository and Pentaho

  1. #1
    Join Date
    Jan 2006
    Posts
    313

    Default kettle repository and Pentaho

    I am struggling with the use of the kettle repository. I modified the settings.xml file so it uses the repository( rdbms). I still get this error below. How does this come?

    Is my xaction the same for repository and file based access? If not can you provide me with an example?


    15:31:30,937 ERROR [KettleComponent] Error Start: Pentaho 1.2.0 build 541 GA
    15:31:30,953 ERROR [KettleComponent] 63011484-89e6-11db-85dd-f779c9034506:COMPONENT:context-21178042-1165930853421:SampleTransformation.xaction Kettle.ERROR_0015 - Could not load transformation transformation-file from resource null
    java.lang.NullPointerException
    at org.pentaho.plugin.kettle.KettleComponent.executeAction(KettleComponent.java:251)
    at org.pentaho.plugin.ComponentBase.execute(ComponentBase.java:422)
    at org.pentaho.core.runtime.RuntimeContext.executeComponent(RuntimeContext.java:989)
    at org.pentaho.core.runtime.RuntimeContext.executeAction(RuntimeContext.java:961)
    at org.pentaho.core.runtime.RuntimeContext.performActions(RuntimeContext.java:877)
    at org.pentaho.core.runtime.RuntimeContext.executeLoop(RuntimeContext.java:833)
    at org.pentaho.core.runtime.RuntimeContext.executeSequence(RuntimeContext.java:739)
    at org.pentaho.core.runtime.RuntimeContext.executeSequence(RuntimeContext.java:655)
    at org.pentaho.core.solution.SolutionEngine.executeInternal(SolutionEngine.java:265)
    at org.pentaho.core.solution.SolutionEngine.execute(SolutionEngine.java:209)
    at org.pentaho.core.services.BaseRequestHandler.handleActionRequest(BaseRequestHandler.java:140)
    at org.pentaho.ui.servlet.ViewAction.doGet(ViewAction.java:153)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:697)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.pentaho.core.system.SystemStatusFilter.doFilter(SystemStatusFilter.java:53)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
    at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:432)
    at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
    at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
    at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
    at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
    at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
    at java.lang.Thread.run(Unknown Source)
    15:31:30,953 ERROR [KettleComponent] Error end:
    15:31:30,968 ERROR [RuntimeContext] 63011484-89e6-11db-85dd-f779c9034506:RUNTIME:context-21178042-1165930853421:SampleTransformation.xaction RuntimeContext.ERROR_0012 - ActionDefinition for KettleComponent did not execute successfully
    15:31:30,984 ERROR [SolutionEngine] 63011484-89e6-11db-85dd-f779c9034506:SOLUTION-ENGINE:SampleTransformation.xaction: SolutionEngine.ERROR_0007 - Action sequence execution failed
    Attached Files Attached Files
    Last edited by begunrom; 12-12-2006 at 10:53 AM.

  2. #2
    Join Date
    Nov 1999
    Posts
    9,729

    Cool Problem in KettleComponent

    Hi Gunther,

    I did a quick trace of this and the problem seems to be in the KettleComponent:

    Code:
                if (isDefinedInput(DIRECTORY)) {
                    String directoryName = getInputStringValue(DIRECTORY);
    
                    if (repository == null) {
                        return false;
                    }
    
                    if (isDefinedInput(TRANSFORMATION)) {
                        String transformationName = getInputStringValue(TRANSFORMATION);
                        transMeta = loadTransformFromRepository(directoryName, transformationName, repository, logWriter);
                        if (transMeta != null) {
                            transMeta.setArguments(parameters);
                        } else {
                            return false;
                        }
                    } else if (isDefinedInput(JOB)) {
                        String jobName = getInputStringValue(JOB);
                        jobMeta = loadJobFromRepository(directoryName, jobName, repository, logWriter);
                        if (jobMeta != null) {
                            jobMeta.setArguments(parameters);
                        } else {
                            return false;
                        }
                    }
    Apperently, it takes the DIRECTORY (directory), TRANS (transformation), JOB(job) information from the context, not the resources.

    I'll have the smart folks from Pentaho take a look at this ;-)

    All the best,

    Matt

  3. #3
    dmoran Guest

    Default

    Gunther,

    Sorry about the confusion. With the RDBMS repository you need to specify the directory and transform name in the action-definition. Unfortunately, if you are using the Design Studio (Action Sequence Editor) it only knows how to use file based transforms. This is a complete oversight and I have opened a JIRA case (PDS-231) on it. In the mean time you can use the XML tab and hand edit the XML.

    Code:
       <action-definition> 
          <component-name>KettleComponent</component-name>
          <action-type>Execute Kettle Transformation</action-type>
          <action-inputs/>
          <action-resources/>
          <action-outputs> 
            <transformation-output type="result-set" mapping="rule-result"/> 
          </action-outputs>
          <component-definition>
            <directory>/</directory>  
            <transform>CreateTimeDim</transform>  
            <importstep>XML Output</importstep>
          </component-definition> 
        </action-definition>
    If you want to use string input parameters to allow the transform to be passed in, then you can include the <directory> and <transform> tags in the <action-inputs> section.

    I have modified your .xaction and attached it to this post. Sorry but I am not in a position to try it out first. I assumed that your transform is in the top level "/" directory of the RDBMS.

    Let me know if you still have any problems - I should be able to test it out late tonight.

    Doug
    Attached Files Attached Files

  4. #4
    Join Date
    Jan 2006
    Posts
    313

    Default Reply to post 'kettle repository and Pentaho'

    Gentlemen,
    thanks for your prompt reply.

    The original problem has been solved. However, i made a typo error in the transformation name.

    I got a ERROR_0012 - ActionDefinition for KettleComponent did not execute successfully.

    No indication of the problem could be found.

    As this costed me a lot of time to find out what was wrong, i was hoping that you could add some extra logging.

    Version 1.2.0.541GA

  5. #5
    dmoran Guest

    Default

    Did you try the change I mentioned above? I think it will fix the error you are seeing now. If not, attach the server.log, it may help track down the issue. You are correct, the error message you are getting is a default one there should be more specific errors. I added this to the JIRA case. Matt had the correct code in the above post. The 3 "return false" lines should provide error messages and I believe one of these is where your trouble is. At a minimum you should have an action-input named "directory" and an action-input named "transformation"

    Thanks,
    Doug

  6. #6
    Join Date
    Jan 2006
    Posts
    313

    Default

    I included the xml in my current xaction (attached to the post).

    I do get further in the code.

    // OK, we have the information, let's load and execute the
    // transformation or job

    if (transMeta != null) {
    result = executeTransformation(transMeta, logWriter);
    }
    if (jobMeta != null) {
    result = executeJob(jobMeta, repository, logWriter);
    }

    } finally {
    logWriter.removeAppender(kettleUserAppender);
    if (repository != null) {
    if (debug)
    debug(Messages.getString("Kettle.DEBUG_DISCONNECTING")); //$NON-NLS-1$
    repository.disconnect();
    }
    }

    As transMeta=null, we do not start the transformation at all. Reason is unknown for me.

    The log say's :
    rg.pentaho.core.runtime.RuntimeContext)

    Debug: Starting execute of cmc/etl/SampleTransformation.xaction (org.pentaho.core.solution.SolutionEngine)
    Debug: Getting runtime context and data (org.pentaho.core.solution.SolutionEngine)
    Debug: Loading action sequence definition file (org.pentaho.core.solution.SolutionEngine)
    Debug: audit: instanceId=7c16f3c3-8ac9-11db-84f7-1567d39087d3, objectId=org.pentaho.core.runtime.RuntimeContext, messageType=action_sequence_start (org.pentaho.core.runtime.RuntimeContext)
    Debug: validateComponent validating component KettleComponent (org.pentaho.core.runtime.RuntimeContext)
    Debug: Validating component for action SampleTransformation.xaction (org.pentaho.plugin.kettle.KettleComponent)
    Debug: Executing action sequence (org.pentaho.core.runtime.RuntimeContext)
    Debug: Executing action definition: Iteration 0 (org.pentaho.core.runtime.RuntimeContext)
    Debug: audit: instanceId=7c16f3c3-8ac9-11db-84f7-1567d39087d3, objectId=KettleComponent, messageType=component_execution_started (org.pentaho.core.runtime.RuntimeContext)
    Debug: execute pre-audit (org.pentaho.core.runtime.RuntimeContext)
    Debug: Setting component log level to TRACE (org.pentaho.core.runtime.RuntimeContext)
    Debug: Initializing component (org.pentaho.core.runtime.RuntimeContext)
    Debug: executeComponent starting audited execute (org.pentaho.core.runtime.RuntimeContext)
    Debug: execute validation=true (org.pentaho.plugin.kettle.KettleComponent)
    Debug: Start of execute (org.pentaho.plugin.kettle.KettleComponent)
    Debug: creating meta-repository (org.pentaho.plugin.kettle.KettleComponent)
    Debug: populating meta-repository (org.pentaho.plugin.kettle.KettleComponent)
    Debug: Finding repository metadata (org.pentaho.plugin.kettle.KettleComponent)
    Debug: Getting repository instance (org.pentaho.plugin.kettle.KettleComponent)
    Debug: Connecting to repository (org.pentaho.plugin.kettle.KettleComponent)
    Debug: Finding directory (org.pentaho.plugin.kettle.KettleComponent)
    Debug: Disconnecting (org.pentaho.plugin.kettle.KettleComponent)
    Debug: executeComponent finished audited execute (org.pentaho.core.runtime.RuntimeContext)
    Error: RuntimeContext.ERROR_0012 - ActionDefinition for KettleComponent did not execute successfully (org.pentaho.core.runtime.RuntimeContext)
    Debug: audit: instanceId=7c16f3c3-8ac9-11db-84f7-1567d39087d3, objectId=org.pentaho.core.runtime.RuntimeContext, messageType=action_sequence_failed (org.pentaho.core.runtime.RuntimeContext)
    Error: SolutionEngine.ERROR_0007 - Action sequence execution failed (org.pentaho.core.solution.SolutionEngine)

    Server Version 1.2.0 build 541 GA

    the server.log is as follows.
    17:47:55,937 INFO [Kettle] Kettle - Reading repositories XML file: C:\Documents and Settings\test\.kettle\repositories.xml
    17:47:57,921 ERROR [RuntimeContext] ae89fdc4-8ac9-11db-84f7-1567d39087d3:RUNTIME:context-8004831-1166028475921:SampleTransformation.xaction RuntimeContext.ERROR_0012 - ActionDefinition for KettleComponent did not execute successfully
    17:47:57,921 ERROR [SolutionEngine] ae89fdc4-8ac9-11db-84f7-1567d39087d3:SOLUTION-ENGINE:SampleTransformation.xaction: SolutionEngine.ERROR_0007 - Action sequence execution failed
    Attached Files Attached Files

  7. #7
    Join Date
    Nov 2005
    Posts
    29

    Default

    I took a look at your action sequence and there were a couple of issues with it. Since you're trying to run the kettle transform from the kettle repository you no longer need the action resource so I removed it. Also, I noticed that the directory you're using is called "reporting". What should be here is the name of the directory within the kettle repository which should be an absolute path. I would expect to see something along the lines of "/reporting". If you saved the transform in the root of the kettle repository then the directory would be "/". Here's the action sequence with the resources removed. You should just have to correct the directory name.

    <?xml version="1.0" encoding="UTF-8"?>
    <action-sequence>
    <name>SampleTransformation.xaction</name>
    <title>%title</title>
    <version>1</version>
    <logging-level>TRACE</logging-level>
    <documentation>
    <author>Gretchen Moran</author>
    <description>%description</description>
    <help>%help</help>
    <result-type>rule</result-type>
    <icon>HelloETL.png</icon>
    </documentation>

    <inputs/>

    <outputs>
    <rule-result type="result-set"/>
    </outputs>

    <actions>
    <action-definition>
    <component-name>KettleComponent</component-name>
    <action-type>Execute Kettle Transformation</action-type>
    <action-inputs/>
    <action-outputs>
    <transformation-output type="result-set" mapping="rule-result"/>
    </action-outputs>
    <component-definition>
    <directory>reporting</directory>
    <transform>tzcrep003</transform>
    <importstep>XML Output</importstep>
    </component-definition>
    </action-definition>

    </actions>
    </action-sequence>

  8. #8
    Join Date
    Jan 2006
    Posts
    313

    Default

    Hi,

    I used the xactions as described above. I changed the directory to "/reporting", because the transformation i want to use is at /repository/tzcrep003 in the repository.

    Whe i run the xaction i get the following error:
    FailedError: Kettle.ERROR_0003 - The transformation name is not specified on an input or provided as a resource (org.pentaho.plugin.kettle.KettleComponent)Debug: Starting execute of cmc/etl/SampleTransformation.xaction (org.pentaho.core.solution.SolutionEngine)
    Debug: Getting runtime context and data (org.pentaho.core.solution.SolutionEngine)
    Debug: Loading action sequence definition file (org.pentaho.core.solution.SolutionEngine)
    Debug: audit: instanceId=a563dbb0-8e7e-11db-8dfc-c1adbe852acc, objectId=org.pentaho.core.runtime.RuntimeContext, messageType=action_sequence_start (org.pentaho.core.runtime.RuntimeContext)
    Debug: validateComponent validating component KettleComponent (org.pentaho.core.runtime.RuntimeContext)
    Debug: Validating component for action SampleTransformation.xaction (org.pentaho.plugin.kettle.KettleComponent)
    Error: Kettle.ERROR_0003 - The transformation name is not specified on an input or provided as a resource (org.pentaho.plugin.kettle.KettleComponent)
    Error: RuntimeContext.ERROR_0006 - Action components do not validate: SampleTransformation.xaction (org.pentaho.core.runtime.RuntimeContext)
    Error: SolutionEngine.ERROR_0006 - Action sequence validation failed (org.pentaho.core.solution.SolutionEngine)


    Server Version 1.2.0 build 557 GA

  9. #9
    Join Date
    Jan 2006
    Posts
    313

    Thumbs up

    I found some time today to debug the Kettle.ERROR_0003 I had.

    The tag transform

    <transform>tzcrep003</transform>

    Should be renamed to transformation

    <transformation>tzcrep003</transformation>

    This fixes the problem

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.