importpentahopentaho-spoon

Pentaho File Repository Moves Jobs & Transformations to root


I created a new file repository, and then moved my project files into the root folder using a file manager. I then connected to my file repository and opened(Ctrl-O) my job & transformation files(in a folder/), then tried to run them, which threw the error below:

org.pentaho.di.core.exception.KettleXMLException: 
Unable to load the job from XML file [F:/user/root/job.kjb]

Unable to read file [file:///F:/user/root/job.kjb]
Could not read from "file:///F:/user/root/job.kjb" because it is not a file.


    at org.pentaho.di.job.JobMeta.<init>(JobMeta.java:738)
    at org.pentaho.di.job.JobMeta.<init>(JobMeta.java:710)
    at org.pentaho.di.job.JobMeta.<init>(JobMeta.java:685)
    at org.pentaho.di.repository.filerep.KettleFileRepository.loadJob(KettleFileRepository.java:949)
    at org.pentaho.di.ui.spoon.job.JobGraph.startJob(JobGraph.java:3466)
    at org.pentaho.di.ui.spoon.delegates.SpoonJobDelegate.executeJob(SpoonJobDelegate.java:1403)
    at org.pentaho.di.ui.spoon.Spoon.executeJob(Spoon.java:8486)
    at org.pentaho.di.ui.spoon.Spoon.executeFile(Spoon.java:8445)
    at org.pentaho.di.ui.spoon.Spoon.runFile(Spoon.java:8410)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.pentaho.ui.xul.impl.AbstractXulDomContainer.invoke(AbstractXulDomContainer.java:313)
    at org.pentaho.ui.xul.impl.AbstractXulComponent.invoke(AbstractXulComponent.java:157)
    at org.pentaho.ui.xul.impl.AbstractXulComponent.invoke(AbstractXulComponent.java:141)
    at org.pentaho.ui.xul.jface.tags.JfaceMenuitem.access$100(JfaceMenuitem.java:43)
    at org.pentaho.ui.xul.jface.tags.JfaceMenuitem$1.run(JfaceMenuitem.java:106)
    at org.eclipse.jface.action.Action.runWithEvent(Action.java:498)
    at org.eclipse.jface.action.ActionContributionItem.handleWidgetSelection(ActionContributionItem.java:545)
    at org.eclipse.jface.action.ActionContributionItem.access$2(ActionContributionItem.java:490)
    at org.eclipse.jface.action.ActionContributionItem$5.handleEvent(ActionContributionItem.java:402)
    at org.eclipse.swt.widgets.EventTable.sendEvent(Unknown Source)
    at org.eclipse.swt.widgets.Display.sendEvent(Unknown Source)
    at org.eclipse.swt.widgets.Widget.sendEvent(Unknown Source)
    at org.eclipse.swt.widgets.Display.runDeferredEvents(Unknown Source)
    at org.eclipse.swt.widgets.Display.readAndDispatch(Unknown Source)
    at org.pentaho.di.ui.spoon.Spoon.readAndDispatch(Spoon.java:1366)
    at org.pentaho.di.ui.spoon.Spoon.waitForDispose(Spoon.java:7984)
    at org.pentaho.di.ui.spoon.Spoon.start(Spoon.java:9245)
    at org.pentaho.di.ui.spoon.Spoon.main(Spoon.java:692)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke(Method.java:498)
    at org.pentaho.commons.launcher.Launcher.main(Launcher.java:92)
Caused by: org.pentaho.di.core.exception.KettleXMLException: 
Unable to read file [file:///F:/user/root/job.kjb]
Could not read from "file:///F:/user/root/job.kjb" because it is not a file.

    at org.pentaho.di.core.xml.XMLHandler.loadXMLFile(XMLHandler.java:561)
    at org.pentaho.di.core.xml.XMLHandler.loadXMLFile(XMLHandler.java:540)
    at org.pentaho.di.job.JobMeta.<init>(JobMeta.java:726)
    ... 35 more
Caused by: org.apache.commons.vfs2.FileNotFoundException: Could not read from "file:///F:/user/root/job.kjb" because it is not a file.
    at org.apache.commons.vfs2.provider.AbstractFileObject.getInputStream(AbstractFileObject.java:1309)
    at org.apache.commons.vfs2.provider.DefaultFileContent.getInputStream(DefaultFileContent.java:411)
    at org.pentaho.di.core.vfs.KettleVFS.getInputStream(KettleVFS.java:270)
    at org.pentaho.di.core.xml.XMLHandler.loadXMLFile(XMLHandler.java:559)
    ... 37 more
Caused by: java.io.FileNotFoundException: F:\user\root\job.kjb (The system cannot find the file specified)
    at java.io.FileInputStream.open0(Native Method)
    at java.io.FileInputStream.open(FileInputStream.java:195)
    at java.io.FileInputStream.<init>(FileInputStream.java:138)
    at org.apache.commons.vfs2.provider.local.LocalFile.doGetInputStream(LocalFile.java:241)
    at org.apache.commons.vfs2.provider.AbstractFileObject.getInputStream(AbstractFileObject.java:1301)
    ... 40 more

I then saved(Ctrl-S) the file(s) and then they ran, however, they were also moved to the root/ from root/folder. Why & How to resolve?


Solution

  • I was able to resolve the issue by using Save As... option and save the files in place as opposed to Save as that for some reason saves them(in fact even moves them) to root even though I was given the option to select them in the open menu provided by the repository itself, in the folder where I've first put them in.