public void delClusterSchema() { final TransMeta transMeta = (TransMeta) selectionObjectParent; final ClusterSchema clusterSchema = (ClusterSchema) selectionObject; delegates.clusters.delClusterSchema( transMeta, clusterSchema ); }
public void editClusterSchema() { final TransMeta transMeta = (TransMeta) selectionObjectParent; final ClusterSchema clusterSchema = (ClusterSchema) selectionObject; delegates.clusters.editClusterSchema( transMeta, clusterSchema ); }
/** * This creates a new clustering schema, edits it and adds it to the transformation metadata if its name is not a * duplicate of any of existing */ public void newClusteringSchema( TransMeta transMeta ) { delegates.clusters.newClusteringSchema( transMeta ); }
if ( isDuplicate( clusterSchemas, clusterSchema ) ) { new ErrorDialog( spoon.getShell(), getMessage( "Spoon.Dialog.ErrorSavingCluster.Title" ), getMessage( "Spoon.Dialog.ErrorSavingCluster.Message", clusterSchema.getName() ), new KettleException( getMessage( "Spoon.Dialog.ErrorSavingCluster.NotUnique" ) ) ); return; showSaveError( clusterSchema, e ); refreshTree();
public void editClusterSchema( TransMeta transMeta, ClusterSchema clusterSchema ) { ClusterSchemaDialog dialog = new ClusterSchemaDialog( spoon.getShell(), clusterSchema, transMeta.getClusterSchemas(), transMeta.getSlaveServers() ); if ( dialog.open() ) { if ( spoon.rep != null && clusterSchema.getObjectId() != null ) { try { saveSharedObjectToRepository( clusterSchema, null ); } catch ( KettleException e ) { showSaveError( clusterSchema, e ); } } sharedObjectSyncUtil.synchronizeClusterSchemas( clusterSchema ); refreshTree(); } }
private void showSaveError( ClusterSchema clusterSchema, KettleException e ) { new ErrorDialog( spoon.getShell(), getMessage( "Spoon.Dialog.ErrorSavingCluster.Title" ), getMessage( "Spoon.Dialog.ErrorSavingCluster.Message", clusterSchema.getName() ), e ); }
public SharedObjectSyncUtil( Spoon spoon ) { this.spoonDelegates = spoon.delegates; this.spoon = spoon; spoonDelegates.db.setSharedObjectSyncUtil( this ); spoonDelegates.slaves.setSharedObjectSyncUtil( this ); spoonDelegates.clusters.setSharedObjectSyncUtil( this ); spoonDelegates.partitions.setSharedObjectSyncUtil( this ); }
public void delClusterSchema( TransMeta transMeta, ClusterSchema clusterSchema ) { try { int idx = transMeta.getClusterSchemas().indexOf( clusterSchema ); transMeta.getClusterSchemas().remove( idx ); if ( spoon.rep != null && clusterSchema.getObjectId() != null ) { // remove the partition schema from the repository too... spoon.rep.deleteClusterSchema( clusterSchema.getObjectId() ); if ( sharedObjectSyncUtil != null ) { sharedObjectSyncUtil.deleteClusterSchema( clusterSchema ); } } refreshTree(); } catch ( KettleException e ) { new ErrorDialog( spoon.getShell(), BaseMessages.getString( PKG, "Spoon.Dialog.ErrorDeletingPartitionSchema.Title" ), BaseMessages .getString( PKG, "Spoon.Dialog.ErrorDeletingPartitionSchema.Message" ), e ); } }
public SpoonDelegates( Spoon spoon ) { tabs = new SpoonTabsDelegate( spoon ); tree = new SpoonTreeDelegate( spoon ); slaves = new SpoonSlaveDelegate( spoon ); steps = new SpoonStepsDelegate( spoon ); db = new SpoonDBDelegate( spoon ); clusters = new SpoonClustersDelegate( spoon ); partitions = new SpoonPartitionsDelegate( spoon ); update( spoon ); }
delegates.clusters.editClusterSchema( (TransMeta) parent, (ClusterSchema) selection );