Skip to content

Commit

Permalink
[BACKLOG-38541] Code changes for moving 'Export repository to XML' Jo…
Browse files Browse the repository at this point in the history
…b step from core to plugin
  • Loading branch information
nawaz34-hitachivantara committed Sep 20, 2023
1 parent 828468b commit 79cec99
Show file tree
Hide file tree
Showing 23 changed files with 418 additions and 48 deletions.
13 changes: 13 additions & 0 deletions assemblies/plugins/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -76,6 +76,7 @@
<pdi-rest-plugin.version>9.6.0.0-SNAPSHOT</pdi-rest-plugin.version>
<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>
</properties>

<dependencies>
Expand Down Expand Up @@ -811,6 +812,18 @@
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.pentaho.di.plugins</groupId>
<artifactId>export-repository-plugins</artifactId>
<version>${export-repository-plugin.version}</version>
<type>zip</type>
<exclusions>
<exclusion>
<groupId>*</groupId>
<artifactId>*</artifactId>
</exclusion>
</exclusions>
</dependency>
</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 @@ -42,7 +42,6 @@
<job-entry id="COPY_MOVE_RESULT_FILENAMES"> <description>i18n:org.pentaho.di.job.entry:JobEntry.CopyMoveResultFilenames.TypeDesc</description> <classname>org.pentaho.di.job.entries.copymoveresultfilenames.JobEntryCopyMoveResultFilenames</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.FileManagement</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.CopyMoveResultFilenames.Tooltip</tooltip> <iconfile>ui/images/CMR.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Process+result+filenames</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="DELETE_FOLDERS"> <description>i18n:org.pentaho.di.job.entry:JobEntry.DeleteFolders.TypeDesc</description> <classname>org.pentaho.di.job.entries.deletefolders.JobEntryDeleteFolders</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.FileManagement</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.DeleteFolders.Tooltip</tooltip> <iconfile>ui/images/DSF.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Delete+folders</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="COLUMNS_EXIST"> <description>i18n:org.pentaho.di.job.entry:JobEntry.ColumnsExist.TypeDesc</description> <classname>org.pentaho.di.job.entries.columnsexist.JobEntryColumnsExist</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.Conditions</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.ColumnsExist.Tooltip</tooltip> <iconfile>ui/images/CEX.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Columns+exist+in+a+table</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="EXPORT_REPOSITORY"> <description>i18n:org.pentaho.di.job.entry:JobEntry.ExportRepository.TypeDesc</description> <classname>org.pentaho.di.job.entries.exportrepository.JobEntryExportRepository</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.Repository</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.ExportRepository.Tooltip</tooltip> <iconfile>ui/images/EREP.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Export+repository+to+XML+file</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="TRUNCATE_TABLES"> <description>i18n:org.pentaho.di.job.entry:JobEntry.TruncateTables.TypeDesc</description> <classname>org.pentaho.di.job.entries.truncatetables.JobEntryTruncateTables</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.Utility</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.TruncateTables.Tooltip</tooltip> <iconfile>ui/images/TRT.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Truncate+tables</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="SET_VARIABLES"> <description>i18n:org.pentaho.di.job.entry:JobEntry.SetVariables.TypeDesc</description> <classname>org.pentaho.di.job.entries.setvariables.JobEntrySetVariables</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.General</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.SetVariables.Tooltip</tooltip> <iconfile>ui/images/SVA.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Set+variables+%28job+entry%29</documentation_url> <cases_url/> <forum_url/> </job-entry>
<job-entry id="WAIT_FOR_SQL"> <description>i18n:org.pentaho.di.job.entry:JobEntry.WaitForSQL.TypeDesc</description> <classname>org.pentaho.di.job.entries.waitforsql.JobEntryWaitForSQL</classname> <category>i18n:org.pentaho.di.job:JobCategory.Category.Utility</category> <tooltip>i18n:org.pentaho.di.job.entry:JobEntry.WaitForSQL.Tooltip</tooltip> <iconfile>ui/images/WSQL.svg</iconfile> <documentation_url>http://wiki.pentaho.com/display/EAI/Wait+for+SQL</documentation_url> <cases_url/> <forum_url/> </job-entry>
Expand Down
1 change: 1 addition & 0 deletions plugins/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ __List of the current core plugins:__
* mondrianinput
* get-repository-names
* connected-to-repository
* export-repository

__Deprecated plugins:__

Expand Down
55 changes: 55 additions & 0 deletions plugins/export-repository/assemblies/plugin/pom.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,55 @@
<?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>export-repository-assemblies</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
</parent>

<artifactId>export-repository-plugins</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

<name>PDI Export Repository To XML Plugin</name>
<description></description>

<dependencies>
<dependency>
<groupId>org.pentaho.di.plugins</groupId>
<artifactId>export-repository-plugins-impl</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>org.pentaho.di.plugins</groupId>
<artifactId>export-repository-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>export-repository-plugins-impl,export-repository-plugins-ui</excludeArtifactIds>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>

</project>
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
<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>export-repository-plugin</id>
<formats>
<format>zip</format>
</formats>
<baseDirectory>export-repository-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>
</fileSets>

<dependencySets>
<dependencySet>
<outputDirectory>.</outputDirectory>
<includes>
<include>org.pentaho.di.plugins:export-repository-plugins-impl:jar</include>
<include>org.pentaho.di.plugins:export-repository-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/export-repository/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>export-repository</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
</parent>

<artifactId>export-repository-assemblies</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

<name>PDI Export Repository To XML Plugin</name>

<modules>
<module>plugin</module>
</modules>
</project>
58 changes: 58 additions & 0 deletions plugins/export-repository/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>export-repository</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
</parent>

<artifactId>export-repository-plugins-impl</artifactId>
<name>PDI Export Repository To XML Plugin 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-2017 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.exportrepository;

import org.pentaho.di.core.annotations.JobEntry;
import org.pentaho.di.job.entry.validator.AbstractFileValidator;
import org.pentaho.di.job.entry.validator.AndValidator;
import org.pentaho.di.job.entry.validator.JobEntryValidatorUtils;
Expand Down Expand Up @@ -78,6 +79,10 @@
* @since 04-06-2008
*
*/

@JobEntry(id = "EXPORT_REPOSITORY",name = "JobEntry.ExportRepository.Tooltip",description = "JobEntry.ExportRepository.TypeDesc",
image = "EREP.svg",categoryDescription = "i18n:org.pentaho.di.job:JobCategory.Category.Repository",documentationUrl = "http://wiki.pentaho.com/display/EAI/Export+repository+to+XML+file",
i18nPackageName = "i18n:org.pentaho.di.job.entry:JobEntry.ExportRepository")
public class JobEntryExportRepository extends JobEntryBase implements Cloneable, JobEntryInterface {
private static Class<?> PKG = JobEntryExportRepository.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 @@
#
#
#Tue Jun 17 21:29:10 CEST 2008
JobEntry.ExportRepository.Tooltip=Export repository to XML file
JobEntry.ExportRepository.TypeDesc=Export repository to XML file
JobExportRepository.Settings.Group.Label=Settings
JobExportRepository.Error.CanNotFindRep=Can not find
JobExportRepository.ListRepositories.Tooltip=Click here to list all defined repository in this system
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/export-repository/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>export-repository</artifactId>
<version>10.1.0.0-SNAPSHOT</version>
<packaging>pom</packaging>

<name>PDI Export Repository To XML Plugin</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 79cec99

Please sign in to comment.