/** * {@inheritDoc} */ @Override public void moveAndRename( MoveAndRenameOperationContext opContext ) throws LdapException { synchronized ( lock ) { super.moveAndRename( opContext ); dirty = true; rewritePartitionData( opContext.getTransaction() ); } }
/** * {@inheritDoc} */ @Override public void moveAndRename( MoveAndRenameOperationContext moveAndRenameContext ) throws LdapException { PartitionTxn partitionTxn = moveAndRenameContext.getTransaction(); Dn oldDn = moveAndRenameContext.getDn(); String id = getEntryId( partitionTxn, oldDn ); super.moveAndRename( moveAndRenameContext ); // Get the modified entry and store it in the context for post usage Entry modifiedEntry = fetch( moveAndRenameContext.getTransaction(), id, moveAndRenameContext.getNewDn() ); moveAndRenameContext.setModifiedEntry( modifiedEntry ); try { entryMoved( partitionTxn, oldDn, modifiedEntry, id ); } catch ( Exception e ) { throw new LdapOperationErrorException( e.getMessage(), e ); } }
/** * {@inheritDoc} */ public void moveAndRename( MoveAndRenameOperationContext moveAndRenameContext ) throws LdapException { boolean cascade = moveAndRenameContext.hasRequestControl( Cascade.OID ); CoreSession session = moveAndRenameContext.getSession(); LookupOperationContext lookupContext = new LookupOperationContext( session, moveAndRenameContext.getDn(), SchemaConstants.ALL_ATTRIBUTES_ARRAY ); lookupContext.setPartition( this ); lookupContext.setTransaction( moveAndRenameContext.getTransaction() ); Entry entry = session.getDirectoryService().getPartitionNexus().lookup( lookupContext ); synchronizer.moveAndRename( moveAndRenameContext, entry, cascade ); wrapped.moveAndRename( moveAndRenameContext ); updateSchemaModificationAttributes( moveAndRenameContext ); }
SchemaConstants.ALL_USER_ATTRIBUTES_ARRAY ); lookupContext.setPartition( moveAndRenameContext.getPartition() ); lookupContext.setTransaction( moveAndRenameContext.getTransaction() );
searchOperationContext.setAliasDerefMode( AliasDerefMode.NEVER_DEREF_ALIASES ); searchOperationContext.setPartition( moveAndRenameContext.getPartition() ); searchOperationContext.setTransaction( moveAndRenameContext.getTransaction() ); getOperationalModsForReplace( oldDn, newName, subentry, candidate ) ); newModifyContext.setPartition( moveAndRenameContext.getPartition() ); newModifyContext.setTransaction( moveAndRenameContext.getTransaction() ); nexus.modify( newModifyContext );