Package org.pentaho.di.shared
Class SharedObjectUtil
java.lang.Object
org.pentaho.di.shared.SharedObjectUtil
Utilities for dealing with Shared Objects
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic Map<org.pentaho.di.shared.SharedObjectsIO.SharedObjectType, Map<String, SharedObjectUtil.ComparedState>> collectChangedSharedObjects(AbstractMeta sourceMeta, org.pentaho.di.core.bowl.Bowl targetBowl, IRepositoryImporter importer) Collects the changes that would be made by moveAllSharedObjects().static <T extends org.pentaho.di.shared.SharedObjectInterface<T> & org.pentaho.di.repository.RepositoryElementInterface>
Map<String, SharedObjectUtil.ComparedState> collectChangedSharedObjects(SharedObjectsManagementInterface<T> sourceManager, SharedObjectsManagementInterface<T> targetManager, IRepositoryImporter importer) static <T extends org.pentaho.di.shared.SharedObjectInterface<T> & org.pentaho.di.repository.RepositoryElementInterface>
voidcopyAll(SharedObjectsManagementInterface<T> sourceManager, SharedObjectsManagementInterface<T> targetManager, boolean overwrite) Copies all the shared objects from the source manager to the target manager.static voidcopySharedObjects(org.pentaho.di.core.bowl.Bowl sourceBowl, AbstractMeta targetMeta, boolean onlyUsedDbs) Copies shared objects from the source bowl to the target AbstractMeta if they aren't already there.static voidcopyUsedDbConnections(org.pentaho.di.core.bowl.Bowl sourceBowl, AbstractMeta targetMeta) static <T extends org.pentaho.di.shared.SharedObjectInterface<T> & org.pentaho.di.repository.RepositoryElementInterface>
voidmoveAll(SharedObjectsManagementInterface<T> sourceManager, SharedObjectsManagementInterface<T> targetManager) Moves all shared objects from the source manager to the target manager, overwriting existing objects (case insensitive)static voidmoveAllSharedObjects(AbstractMeta sourceMeta, org.pentaho.di.core.bowl.Bowl targetBowl) Moves all shared objects from the source to the target, overwriting on conflict (case insensitive)static voidpatchDatabaseConnections(org.pentaho.di.core.bowl.Bowl bowl, AbstractMeta meta) updates all the database connections from the bowl in the meta.static voidstripObjectIds(AbstractMeta meta) Remove ObjectIds from all the Local objects.static <T extends org.pentaho.di.shared.SharedObjectInterface<T> & org.pentaho.di.repository.RepositoryElementInterface>
voidstripObjectIds(SharedObjectsManagementInterface<T> manager)
-
Constructor Details
-
SharedObjectUtil
public SharedObjectUtil()
-
-
Method Details
-
copyUsedDbConnections
public static void copyUsedDbConnections(org.pentaho.di.core.bowl.Bowl sourceBowl, AbstractMeta targetMeta) throws org.pentaho.di.core.exception.KettleException - Throws:
org.pentaho.di.core.exception.KettleException
-
patchDatabaseConnections
public static void patchDatabaseConnections(org.pentaho.di.core.bowl.Bowl bowl, AbstractMeta meta) throws org.pentaho.di.core.exception.KettleException updates all the database connections from the bowl in the meta. Updates ObjectIds before import to the repository. Call after moveAllSharedObjects.- Parameters:
bowl-meta-- Throws:
org.pentaho.di.core.exception.KettleException
-
stripObjectIds
public static void stripObjectIds(AbstractMeta meta) throws org.pentaho.di.core.exception.KettleException Remove ObjectIds from all the Local objects. Use before serializing to some format that should not contain object ids from the repository.- Parameters:
meta-- Throws:
org.pentaho.di.core.exception.KettleException