This repository has been archived by the owner on Dec 15, 2022. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 13
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding database replacement and a series of bug fixes
- Loading branch information
Matt Casters
committed
Nov 24, 2016
1 parent
fabac90
commit 06e65c2
Showing
13 changed files
with
244 additions
and
158 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
43 changes: 43 additions & 0 deletions
43
src/org/pentaho/di/dataset/TransUnitTestDatabaseReplacement.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
package org.pentaho.di.dataset; | ||
|
||
import org.pentaho.metastore.persist.MetaStoreAttribute; | ||
|
||
/** | ||
* This class simply replaces all occurrences of a certain database connection with another one. It allows developers to point to a test database for lookup data and database related steps like database lookup, dimension lookup and so on. | ||
* | ||
* @author matt | ||
* | ||
*/ | ||
public class TransUnitTestDatabaseReplacement { | ||
|
||
@MetaStoreAttribute(key = "original_connection") | ||
private String originalDatabaseName; | ||
|
||
@MetaStoreAttribute(key = "replacement_connection") | ||
private String replacementDatabaseName; | ||
|
||
public TransUnitTestDatabaseReplacement(String originalDatabaseName, String replacementDatabaseName) { | ||
this(); | ||
this.originalDatabaseName = originalDatabaseName; | ||
this.replacementDatabaseName = replacementDatabaseName; | ||
} | ||
|
||
public TransUnitTestDatabaseReplacement() { | ||
} | ||
|
||
public String getOriginalDatabaseName() { | ||
return originalDatabaseName; | ||
} | ||
|
||
public void setOriginalDatabaseName(String originalDatabaseName) { | ||
this.originalDatabaseName = originalDatabaseName; | ||
} | ||
|
||
public String getReplacementDatabaseName() { | ||
return replacementDatabaseName; | ||
} | ||
|
||
public void setReplacementDatabaseName(String replacementDatabaseName) { | ||
this.replacementDatabaseName = replacementDatabaseName; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.