Skip to content

Commit

Permalink
[BACKLOG-38621] Code Changes for moving ftp-delete job from core to p…
Browse files Browse the repository at this point in the history
…lugin.
  • Loading branch information
ssindhu23 committed Sep 20, 2023
1 parent 63821ed commit 29ce6db
Show file tree
Hide file tree
Showing 24 changed files with 429 additions and 6 deletions.
1 change: 1 addition & 0 deletions assemblies/plugins/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -73,6 +73,7 @@
<get-repository-names-plugin.version>${project.version}</get-repository-names-plugin.version>
<connected-to-repository-plugin.version>${project.version}</connected-to-repository-plugin.version>
<export-repository-plugin.version>${project.version}</export-repository-plugin.version>
<ftp-delete-plugin.version>${project.version}</ftp-delete-plugin.version>
</properties>

<dependencies>
Expand Down
1 change: 0 additions & 1 deletion engine/src/main/resources/kettle-job-entries.xml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@
<job-entry id="FTPS_PUT"> <description>i18n:org.pentaho.di.job.entry:JobEntry.FTPSPut.TypeDesc</description> <classname>org.pentaho.di.job.entries.ftpsput.JobEntryFTPSPUT</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.FileTransfer</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.FTPSPut.Tooltip</tooltip> <iconfile>ui/images/PFTPS.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Upload+files+to+FTPS</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="SFTP"> <description>i18n:org.pentaho.di.job.entry:JobEntry.SFTP.TypeDesc</description> <classname>org.pentaho.di.job.entries.sftp.JobEntrySFTP</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.FileTransfer</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.SFTP.Tooltip</tooltip> <iconfile>ui/images/GSFTP.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Get+a+file+with+SFTP</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="SFTPPUT"> <description>i18n:org.pentaho.di.job.entry:JobEntry.SFTPPut.TypeDesc</description> <classname>org.pentaho.di.job.entries.sftpput.JobEntrySFTPPUT</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.FileTransfer</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.SFTPPut.Tooltip</tooltip> <iconfile>ui/images/PSFTP.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Put+a+file+with+SFTP</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="FTP_DELETE"> <description>i18n:org.pentaho.di.job.entry:JobEntry.FTPDELETE.TypeDesc</description> <classname>org.pentaho.di.job.entries.ftpdelete.JobEntryFTPDelete</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.FileTransfer</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.FTPDELETE.Tooltip</tooltip> <iconfile>ui/images/FTPD.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/FTP+Delete</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="TABLE_EXISTS"> <description>i18n:org.pentaho.di.job.entry:JobEntry.TableExists.TypeDesc</description> <classname>org.pentaho.di.job.entries.tableexists.JobEntryTableExists</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.Conditions</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.TableExists.Tooltip</tooltip> <iconfile>ui/images/TEX.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Table+Exists+%28Job+Entry%29</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="FILE_EXISTS"> <description>i18n:org.pentaho.di.job.entry:JobEntry.FileExists.TypeDesc</description> <classname>org.pentaho.di.job.entries.fileexists.JobEntryFileExists</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.Conditions</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.FileExists.Tooltip</tooltip> <iconfile>ui/images/FEX.svg</iconfile> <documentation_url>Products/File_Exists_(Job_Entry)</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="EVAL"> <description>i18n:org.pentaho.di.job.entry:JobEntry.Evaluation.TypeDesc</description> <classname>org.pentaho.di.job.entries.eval.JobEntryEval</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.Scripting</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.Evaluation.Tooltip</tooltip> <iconfile>ui/images/SCR_mod.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Evaluating+conditions+in+The+JavaScript+job+entry</documentation_url> <cases_url/> <forum_url/> </job-entry>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -86,8 +86,6 @@ JobEntry.CopyMoveResultFilenames.TypeDesc=Process result filenames
JobEntry.CopyMoveResultFilenames.Tooltip=Copy, move or delete result filenames
JobEntry.XMLWellFormed.TypeDesc=Check if XML file is well formed
JobEntry.XMLWellFormed.Tooltip=Check if one or several XML files is/are well formed
JobEntry.FTPDELETE.TypeDesc=FTP delete
JobEntry.FTPDELETE.Tooltip=Delete files in a remote host
JobEntry.DeleteFolders.TypeDesc=Delete folders
JobEntry.DeleteFolders.Tooltip=Delete specified folders.\nAttention : if a the folder contains files, PDI will delete them all!
JobEntry.ColumnsExist.TypeDesc=Columns exist in a table
Expand Down
1 change: 1 addition & 0 deletions plugins/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ __List of the current core plugins:__
* get-repository-names
* connected-to-repository
* export-repository
* ftp-delete

__Deprecated plugins:__

Expand Down
58 changes: 58 additions & 0 deletions plugins/ftp-delete/assemblies/plugin/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.pentaho.di.plugins</groupId>
<artifactId>ftp-delete-assemblies</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
</parent>


<artifactId>ftp-delete-plugins</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

<name>PDI FTP Delete Plugins Distribution</name>
<description></description>
<properties>
<resources.directory>${project.basedir}/src/main/resources</resources.directory>
</properties>
<dependencies>
<dependency>
<groupId>org.pentaho.di.plugins</groupId>
<artifactId>ftp-delete-plugins-impl</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.pentaho.di.plugins</groupId>
<artifactId>ftp-delete-plugins-ui</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>

<build>
<plugins>
<plugin>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>add-libs</id>
<phase>generate-resources</phase>
<goals>
<goal>copy-dependencies</goal>
</goals>
<configuration>
<outputDirectory>${project.build.directory}/assembly/lib</outputDirectory>
<includeScope>compile</includeScope>
<excludeArtifactIds>ftp-delete-plugins-impl,ftp-delete-plugins-ui</excludeArtifactIds>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>

</project>
41 changes: 41 additions & 0 deletions plugins/ftp-delete/assemblies/plugin/src/assembly/assembly.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
<assembly xmlns="http://maven.apache.org/ASSEMBLY/2.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/ASSEMBLY/2.0.0 http://maven.apache.org/xsd/assembly-2.0.0.xsd">
<id>ftp-delete-plugin</id>
<formats>
<format>zip</format>
</formats>
<baseDirectory>ftp-delete-plugins</baseDirectory>

<files>
<file>
<source>${project.basedir}/src/main/resources/version.xml</source>
<outputDirectory>.</outputDirectory>
<filtered>true</filtered>
</file>
</files>

<fileSets>
<!-- the staging dir -->
<fileSet>
<directory>${project.build.directory}/assembly</directory>
<outputDirectory>.</outputDirectory>
</fileSet>

<fileSet>
<directory>${resources.directory}</directory>
<outputDirectory>.</outputDirectory>
<filtered>true</filtered>
</fileSet>
</fileSets>

<dependencySets>
<dependencySet>
<outputDirectory>.</outputDirectory>
<includes>
<include>org.pentaho.di.plugins:ftp-delete-plugins-impl:jar</include>
<include>org.pentaho.di.plugins:ftp-delete-plugins-ui:jar</include>
</includes>
<useProjectArtifact>false</useProjectArtifact>
</dependencySet>
</dependencySets>
</assembly>
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
<?xml version="1.0" encoding="UTF-8"?>
<version>${project.version}</version>
22 changes: 22 additions & 0 deletions plugins/ftp-delete/assemblies/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.pentaho.di.plugins</groupId>
<artifactId>ftp-delete</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
</parent>

<artifactId>ftp-delete-assemblies</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

<name>PDI FTP Delete Plugins Assemblies</name>

<modules>
<module>plugin</module>
</modules>
</project>
58 changes: 58 additions & 0 deletions plugins/ftp-delete/impl/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.pentaho.di.plugins</groupId>
<artifactId>ftp-delete</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
</parent>

<artifactId>ftp-delete-plugins-impl</artifactId>
<name>PDI FTP Delete Plugins Impl</name>

<dependencies>
<dependency>
<groupId>pentaho-kettle</groupId>
<artifactId>kettle-core</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>pentaho-kettle</groupId>
<artifactId>kettle-engine</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.healthmarketscience.jackcess</groupId>
<artifactId>jackcess</artifactId>
<scope>compile</scope>
</dependency>

<!-- Test dependencies -->
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-all</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.hamcrest</groupId>
<artifactId>hamcrest-core</artifactId>
<version>1.3</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>pentaho-kettle</groupId>
<artifactId>kettle-core</artifactId>
<classifier>tests</classifier>
<scope>test</scope>
</dependency>
<dependency>
<groupId>pentaho-kettle</groupId>
<artifactId>kettle-engine</artifactId>
<classifier>tests</classifier>
<scope>test</scope>
</dependency>
</dependencies>
</project>
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
*
* Pentaho Data Integration
*
* Copyright (C) 2002-2022 by Hitachi Vantara : http://www.pentaho.com
* Copyright (C) 2002-2023 by Hitachi Vantara : http://www.pentaho.com
*
*******************************************************************************
*
Expand All @@ -22,6 +22,7 @@

package org.pentaho.di.job.entries.ftpdelete;

import org.pentaho.di.core.annotations.JobEntry;
import org.pentaho.di.job.entry.validator.AndValidator;
import org.pentaho.di.job.entry.validator.JobEntryValidatorUtils;

Expand Down Expand Up @@ -76,6 +77,12 @@
* @since 05-11-2003
*
*/
@JobEntry( id = "FTP_DELETE", name = "JobEntry.FTPDELETE.TypeDesc",
i18nPackageName = "org.pentaho.di.job.entries.ftpdelete",
description = "JobEntry.FTPDELETE.Tooltip",
categoryDescription = "i18n:org.pentaho.di.job:JobCategory.Category.FileTransfer",
image = "ui/images/FTPD.svg",
documentationUrl = "http://wiki.pentaho.com/display/EAI/FTP+Delete" )
public class JobEntryFTPDelete extends JobEntryBase implements Cloneable, JobEntryInterface {
private static Class<?> PKG = JobEntryFTPDelete.class; // for i18n purposes, needed by Translator2!!

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@
#
#
#Thu May 15 20:31:26 CEST 2008
JobEntry.FTPDELETE.TypeDesc=FTP delete
JobEntry.FTPDELETE.Tooltip=Delete files in a remote host
JobEntryFTPDelete.Started=Started FTP job to {0}
JobFTPDelete.Server.Label=FTP server name / IP address\:
JobFTPDelete.FolderExists.OK=Folder {0} exists in the remote host.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
*
* Pentaho Data Integration
*
* Copyright (C) 2002-2018 by Hitachi Vantara : http://www.pentaho.com
* Copyright (C) 2002-2023 by Hitachi Vantara : http://www.pentaho.com
*
*******************************************************************************
*
Expand Down
118 changes: 118 additions & 0 deletions plugins/ftp-delete/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,118 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd"
xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<modelVersion>4.0.0</modelVersion>

<parent>
<groupId>org.pentaho.di.plugins</groupId>
<artifactId>pdi-plugins</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
</parent>

<artifactId>ftp-delete</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

<name>PDI FTP Delete Plugins</name>
<description>This plugin is for pentaho Data integration (ETL) a.k.a kettle</description>
<url>http://www.pentaho.com/</url>

<modules>
<module>impl</module>
<module>ui</module>
<module>assemblies</module>
</modules>

<licenses>
<license>
<name>Apache License, Version 2.0</name>
<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
<comments>A business-friendly OSS license</comments>
</license>
</licenses>

<properties>
<org.eclipse.swt.version>4.6</org.eclipse.swt.version>
<jface.version>3.3.0-I20070606-0010</jface.version>
<pdi.version>10.1.0.0-SNAPSHOT</pdi.version>
</properties>

<dependencyManagement>
<dependencies>
<dependency>
<groupId>pentaho-kettle</groupId>
<artifactId>kettle-engine</artifactId>
<version>${pdi.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>pentaho-kettle</groupId>
<artifactId>kettle-core</artifactId>
<version>${pdi.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>pentaho-kettle</groupId>
<artifactId>kettle-ui-swt</artifactId>
<version>${pdi.version}</version>
<scope>provided</scope>
</dependency>

<!-- SWT is required to compile,inorder to work with architecture -->
<dependency>
<groupId>org.eclipse.swt</groupId>
<artifactId>org.eclipse.swt.gtk.linux.x86_64</artifactId>
<version>${org.eclipse.swt.version}</version>
<scope>provided</scope>
<exclusions>
<exclusion>
<artifactId>*</artifactId>
<groupId>*</groupId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.eclipse</groupId>
<artifactId>jface</artifactId>
<version>${jface.version}</version>
<scope>provided</scope>
<exclusions>
<exclusion>
<artifactId>*</artifactId>
<groupId>*</groupId>
</exclusion>
</exclusions>
</dependency>
<!--test dependencies-->
<dependency>
<groupId>pentaho-kettle</groupId>
<artifactId>kettle-core</artifactId>
<version>${pdi.version}</version>
<classifier>tests</classifier>
<scope>test</scope>
</dependency>
<dependency>
<groupId>pentaho-kettle</groupId>
<artifactId>kettle-engine</artifactId>
<version>${pdi.version}</version>
<classifier>tests</classifier>
<scope>test</scope>
</dependency>

<dependency>
<groupId>com.healthmarketscience.jackcess</groupId>
<artifactId>jackcess</artifactId>
<version>1.2.6</version>
<scope>compile</scope>
<exclusions>
<exclusion>
<artifactId>*</artifactId>
<groupId>*</groupId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
</dependencyManagement>
</project>
Loading

0 comments on commit 29ce6db

Please sign in to comment.