Moved the LDAP-specific transaction support classes from ldap.transaction.core to ldap.transaction.

This commit is contained in:
Ulrik Sandberg
2007-04-10 14:53:20 +00:00
parent f9989bfa4a
commit 890607b1bf
39 changed files with 73 additions and 56 deletions

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;
import javax.naming.directory.Attributes;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;
import javax.naming.directory.Attributes;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.directory.DirContext;

View File

@@ -13,10 +13,12 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.directory.DirContext;
import org.springframework.ldap.transaction.core.TransactionAwareContextSourceProxy;
/**
* Helper interface to be able to get hold of the target DirContext from proxies
* created by {@link TransactionAwareContextSourceProxy}.

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import java.lang.reflect.InvocationHandler;
import java.lang.reflect.InvocationTargetException;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;
import javax.naming.directory.ModificationItem;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import java.util.HashSet;
import java.util.Set;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import org.springframework.transaction.compensating.CompensatingTransactionOperationExecutor;
import org.springframework.transaction.compensating.CompensatingTransactionOperationManager;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;
import javax.naming.directory.Attributes;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;
import javax.naming.directory.Attributes;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;

View File

@@ -14,7 +14,7 @@
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import java.lang.reflect.InvocationTargetException;
import java.lang.reflect.Method;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;

View File

@@ -13,7 +13,7 @@
* See the License for the specific language governing permissions and
* limitations under the License.
*/
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;

View File

@@ -17,6 +17,7 @@ package org.springframework.ldap.transaction.core;
import org.springframework.jdbc.datasource.DataSourceTransactionManager;
import org.springframework.ldap.core.ContextSource;
import org.springframework.ldap.transaction.TempEntryRenamingStrategy;
import org.springframework.transaction.TransactionDefinition;
import org.springframework.transaction.TransactionException;
import org.springframework.transaction.TransactionSuspensionNotSupportedException;

View File

@@ -16,6 +16,8 @@
package org.springframework.ldap.transaction.core;
import org.springframework.ldap.core.ContextSource;
import org.springframework.ldap.transaction.TempEntryRenamingStrategy;
import org.springframework.ldap.transaction.UnbindOperationExecutor;
import org.springframework.transaction.TransactionDefinition;
import org.springframework.transaction.TransactionException;
import org.springframework.transaction.compensating.CompensatingTransactionOperationExecutor;

View File

@@ -21,6 +21,8 @@ import javax.naming.directory.DirContext;
import org.apache.commons.logging.Log;
import org.apache.commons.logging.LogFactory;
import org.springframework.ldap.core.ContextSource;
import org.springframework.ldap.transaction.DirContextHolder;
import org.springframework.ldap.transaction.TempEntryRenamingStrategy;
import org.springframework.transaction.TransactionDefinition;
import org.springframework.transaction.TransactionException;
import org.springframework.transaction.support.DefaultTransactionStatus;

View File

@@ -15,6 +15,8 @@
*/
package org.springframework.ldap.transaction.core;
import org.springframework.ldap.transaction.DirContextHolder;
/**
* Transaction object for ContextSourceTransactionManager. Keeps a reference to
* the {@link DirContextHolder} associated with the current transaction.

View File

@@ -22,6 +22,7 @@ import javax.naming.Name;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapRdn;
import org.springframework.ldap.core.LdapRdnComponent;
import org.springframework.ldap.transaction.TempEntryRenamingStrategy;
/**
* Default implementation of {@link TempEntryRenamingStrategy}. This

View File

@@ -22,6 +22,7 @@ import javax.naming.Name;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapRdn;
import org.springframework.ldap.core.LdapRdnComponent;
import org.springframework.ldap.transaction.TempEntryRenamingStrategy;
/**
* A {@link TempEntryRenamingStrategy} that moves the entry to a different

View File

@@ -21,6 +21,9 @@ import javax.naming.directory.DirContext;
import org.springframework.ldap.NamingException;
import org.springframework.ldap.core.ContextSource;
import org.springframework.ldap.transaction.DirContextHolder;
import org.springframework.ldap.transaction.DirContextProxy;
import org.springframework.ldap.transaction.TransactionUtils;
import org.springframework.transaction.support.TransactionSynchronizationManager;
/**

View File

@@ -22,6 +22,8 @@ import java.lang.reflect.Method;
import javax.naming.directory.DirContext;
import org.springframework.ldap.core.ContextSource;
import org.springframework.ldap.transaction.DirContextHolder;
import org.springframework.ldap.transaction.TransactionUtils;
/**
* Proxy implementation for DirContext, making sure that the instance is not

View File

@@ -9,8 +9,8 @@ import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.ContextSource;
import org.springframework.ldap.transaction.core.DirContextHolder;
import org.springframework.ldap.transaction.core.TransactionUtils;
import org.springframework.ldap.transaction.DirContextHolder;
import org.springframework.ldap.transaction.TransactionUtils;
import org.springframework.transaction.compensating.CompensatingTransactionOperationManager;
import org.springframework.transaction.support.TransactionSynchronizationManager;

View File

@@ -1,4 +1,4 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.directory.BasicAttributes;
@@ -7,7 +7,7 @@ import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.BindOperationExecutor;
import org.springframework.ldap.transaction.BindOperationExecutor;
public class BindOperationExecutorTest extends TestCase {
private MockControl ldapOperationsControl;

View File

@@ -1,4 +1,4 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.directory.BasicAttributes;
@@ -7,8 +7,8 @@ import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.BindOperationExecutor;
import org.springframework.ldap.transaction.core.BindOperationRecorder;
import org.springframework.ldap.transaction.BindOperationExecutor;
import org.springframework.ldap.transaction.BindOperationRecorder;
import org.springframework.transaction.compensating.CompensatingTransactionOperationExecutor;
public class BindOperationRecorderTest extends TestCase {

View File

@@ -1,16 +1,16 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.BindOperationRecorder;
import org.springframework.ldap.transaction.core.LdapCompensatingTransactionOperationFactory;
import org.springframework.ldap.transaction.core.ModifyAttributesOperationRecorder;
import org.springframework.ldap.transaction.core.RebindOperationRecorder;
import org.springframework.ldap.transaction.core.RenameOperationRecorder;
import org.springframework.ldap.transaction.core.TempEntryRenamingStrategy;
import org.springframework.ldap.transaction.core.UnbindOperationRecorder;
import org.springframework.ldap.transaction.BindOperationRecorder;
import org.springframework.ldap.transaction.LdapCompensatingTransactionOperationFactory;
import org.springframework.ldap.transaction.ModifyAttributesOperationRecorder;
import org.springframework.ldap.transaction.RebindOperationRecorder;
import org.springframework.ldap.transaction.RenameOperationRecorder;
import org.springframework.ldap.transaction.TempEntryRenamingStrategy;
import org.springframework.ldap.transaction.UnbindOperationRecorder;
import org.springframework.transaction.compensating.CompensatingTransactionOperationRecorder;
public class LdapCompensatingTransactionOperationFactoryTest extends TestCase {

View File

@@ -1,4 +1,4 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.Name;
import javax.naming.directory.ModificationItem;
@@ -6,7 +6,7 @@ import javax.naming.directory.ModificationItem;
import org.easymock.MockControl;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.ModifyAttributesOperationExecutor;
import org.springframework.ldap.transaction.ModifyAttributesOperationExecutor;
import junit.framework.TestCase;

View File

@@ -1,4 +1,4 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.NamingException;
import javax.naming.directory.Attribute;
@@ -14,8 +14,8 @@ import org.easymock.MockControl;
import org.springframework.ldap.core.AttributesMapper;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.ModifyAttributesOperationExecutor;
import org.springframework.ldap.transaction.core.ModifyAttributesOperationRecorder;
import org.springframework.ldap.transaction.ModifyAttributesOperationExecutor;
import org.springframework.ldap.transaction.ModifyAttributesOperationRecorder;
import org.springframework.transaction.compensating.CompensatingTransactionOperationExecutor;
public class ModifyAttributesOperationRecorderTest extends TestCase {

View File

@@ -1,4 +1,4 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.directory.BasicAttributes;
@@ -7,7 +7,7 @@ import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.RebindOperationExecutor;
import org.springframework.ldap.transaction.RebindOperationExecutor;
public class RebindOperationExecutorTest extends TestCase {

View File

@@ -1,4 +1,4 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import javax.naming.directory.BasicAttributes;
@@ -7,9 +7,9 @@ import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.RebindOperationExecutor;
import org.springframework.ldap.transaction.core.RebindOperationRecorder;
import org.springframework.ldap.transaction.core.TempEntryRenamingStrategy;
import org.springframework.ldap.transaction.RebindOperationExecutor;
import org.springframework.ldap.transaction.RebindOperationRecorder;
import org.springframework.ldap.transaction.TempEntryRenamingStrategy;
import org.springframework.transaction.compensating.CompensatingTransactionOperationExecutor;
public class RebindOperationRecorderTest extends TestCase {

View File

@@ -1,9 +1,9 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import org.easymock.MockControl;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.RenameOperationExecutor;
import org.springframework.ldap.transaction.RenameOperationExecutor;
import junit.framework.TestCase;

View File

@@ -1,11 +1,11 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.RenameOperationExecutor;
import org.springframework.ldap.transaction.core.RenameOperationRecorder;
import org.springframework.ldap.transaction.RenameOperationExecutor;
import org.springframework.ldap.transaction.RenameOperationRecorder;
import org.springframework.transaction.compensating.CompensatingTransactionOperationExecutor;
public class RenameOperationRecorderTest extends TestCase {

View File

@@ -1,11 +1,11 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.UnbindOperationExecutor;
import org.springframework.ldap.transaction.UnbindOperationExecutor;
public class UnbindOperationExecutorTest extends TestCase {
private MockControl ldapOperationsControl;

View File

@@ -1,13 +1,13 @@
package org.springframework.ldap.transaction.core;
package org.springframework.ldap.transaction;
import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.DistinguishedName;
import org.springframework.ldap.core.LdapOperations;
import org.springframework.ldap.transaction.core.TempEntryRenamingStrategy;
import org.springframework.ldap.transaction.core.UnbindOperationExecutor;
import org.springframework.ldap.transaction.core.UnbindOperationRecorder;
import org.springframework.ldap.transaction.TempEntryRenamingStrategy;
import org.springframework.ldap.transaction.UnbindOperationExecutor;
import org.springframework.ldap.transaction.UnbindOperationRecorder;
import org.springframework.transaction.compensating.CompensatingTransactionOperationExecutor;
public class UnbindOperationRecorderTest extends TestCase {

View File

@@ -6,10 +6,10 @@ import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.ContextSource;
import org.springframework.ldap.transaction.DirContextHolder;
import org.springframework.ldap.transaction.TempEntryRenamingStrategy;
import org.springframework.ldap.transaction.core.ContextSourceTransactionManager;
import org.springframework.ldap.transaction.core.ContextSourceTransactionObject;
import org.springframework.ldap.transaction.core.DirContextHolder;
import org.springframework.ldap.transaction.core.TempEntryRenamingStrategy;
import org.springframework.ldap.transaction.core.TransactionAwareContextSourceProxy;
import org.springframework.transaction.TransactionDefinition;
import org.springframework.transaction.compensating.CompensatingTransactionOperationManager;

View File

@@ -22,6 +22,7 @@ import junit.framework.TestCase;
import org.easymock.MockControl;
import org.springframework.ldap.core.ContextSource;
import org.springframework.ldap.transaction.DirContextProxy;
/**
* Tests for {@link TransactionAwareContextSourceProxy}.