@Override public ObjectId getJobId( String s, RepositoryDirectoryInterface repositoryDirectoryInterface ) throws KettleException { return getDelegate().getJobId( s, repositoryDirectoryInterface ); }
/** * Look up the references after import * * @param repository * the repository to reference. */ @Override public void lookupRepositoryReferences( Repository repository ) throws KettleException { // The correct reference is stored in the job name and directory attributes... // RepositoryDirectoryInterface repositoryDirectoryInterface = RepositoryImportLocation.getRepositoryImportLocation().findDirectory( directory ); jobObjectId = repository.getJobId( jobname, repositoryDirectoryInterface ); }
private JobMeta loadJob( Repository repository, String job ) throws KettleException { if ( repository == null ) { throw new KettleException( "Repository required." ); } else { synchronized ( repository ) { // With a repository we need to load it from /foo/bar/Transformation // We need to extract the folder name from the path in front of the // name... // String directoryPath; String name; int lastSlash = job.lastIndexOf( RepositoryDirectory.DIRECTORY_SEPARATOR ); if ( lastSlash < 0 ) { directoryPath = "/"; name = job; } else { directoryPath = job.substring( 0, lastSlash ); name = job.substring( lastSlash + 1 ); } RepositoryDirectoryInterface directory = repository.loadRepositoryDirectoryTree().findDirectory( directoryPath ); ObjectId jobID = repository.getJobId( name, directory ); JobMeta transJob = repository.loadJob( jobID, null ); return transJob; } } }
ObjectId jobID = repository.getJobId( name, directory ); if ( jobID == null ) { throw new KettleException( "Unable to find job '" + name + "' in directory :" + directory );
ObjectId id = rep.getJobId( name, repdir ); if ( id != null ) { System.out.println( "Renaming job [" + name + "] with ID = " + id );
ObjectId id = rep.getJobId( name, repdir ); if ( id != null ) {
ObjectId existintId = rep.getJobId( jobMeta.getName(), targetDirectory ); if ( existintId != null && askOverwrite ) { overwrite = feedback.jobOverwritePrompt( jobMeta );
existingId = rep.getJobId( meta.getName(), meta.getRepositoryDirectory() );