Update of /cvsroot/springnet/Spring.Net/src/Spring/Spring.Data/Transaction/Interceptor
In directory sc8-pr-cvs8.sourceforge.net:/tmp/cvs-serv12444
Modified Files:
MethodMapTransactionAttributeSource.cs
NameMatchTransactionAttributeSource.cs
Log Message:
SPRNET-955 : Provide better error message if dbprovider name is not found in thread local storage when using MultiDelegatingDbProvider
SPRNET-956 - Provide better error message if assembly name is not provided when specying method signature for MethodMapTransactionAttributeSource
misc code cleanup.
Index: MethodMapTransactionAttributeSource.cs
===================================================================
RCS file: /cvsroot/springnet/Spring.Net/src/Spring/Spring.Data/Transaction/Interceptor/MethodMapTransactionAttributeSource.cs,v
retrieving revision 1.14
retrieving revision 1.15
diff -C2 -d -r1.14 -r1.15
*** MethodMapTransactionAttributeSource.cs 27 May 2008 19:06:57 -0000 1.14
--- MethodMapTransactionAttributeSource.cs 29 May 2008 17:26:41 -0000 1.15
***************
*** 114,118 ****
--- 114,124 ----
public void AddTransactionalMethod( string name, ITransactionAttribute attribute )
{
+ AssertUtils.ArgumentNotNull(name, "name");
int lastCommaIndex = name.LastIndexOf( "," );
+ if (lastCommaIndex == -1)
+ {
+ throw new ArgumentException("'" + name + "'" +
+ " is not a valid method name, missing AssemblyName. Format is FQN.MethodName, AssemblyName.");
+ }
string fqnWithMethod = name.Substring(0, lastCommaIndex);
Index: NameMatchTransactionAttributeSource.cs
===================================================================
RCS file: /cvsroot/springnet/Spring.Net/src/Spring/Spring.Data/Transaction/Interceptor/NameMatchTransactionAttributeSource.cs,v
retrieving revision 1.8
retrieving revision 1.9
diff -C2 -d -r1.8 -r1.9
*** NameMatchTransactionAttributeSource.cs 27 May 2008 19:06:57 -0000 1.8
--- NameMatchTransactionAttributeSource.cs 29 May 2008 17:26:41 -0000 1.9
***************
*** 41,44 ****
--- 41,45 ----
/// Logger available to subclasses, static for optimal serialization
/// </summary>
+ [NonSerialized()]
protected static readonly ILog log = LogManager.GetLogger(typeof(NameMatchTransactionAttributeSource));
|