activemq-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tab...@apache.org
Subject svn commit: r1066519 - in /activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src: main/csharp/Transactions/RecoveryFileLogger.cs test/csharp/NetTxConnectionFactoryTest.cs
Date Wed, 02 Feb 2011 16:31:22 GMT
Author: tabish
Date: Wed Feb  2 16:31:22 2011
New Revision: 1066519

URL: http://svn.apache.org/viewvc?rev=1066519&view=rev
Log:
https://issues.apache.org/jira/browse/AMQNET-290

Ensure that paths configured in the uri string are not escaped when applied to the logger
object.  Add test cases to cover this.

Modified:
    activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/Transactions/RecoveryFileLogger.cs
    activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/NetTxConnectionFactoryTest.cs

Modified: activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/Transactions/RecoveryFileLogger.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/Transactions/RecoveryFileLogger.cs?rev=1066519&r1=1066518&r2=1066519&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/Transactions/RecoveryFileLogger.cs
(original)
+++ activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/Transactions/RecoveryFileLogger.cs
Wed Feb  2 16:31:22 2011
@@ -16,6 +16,7 @@
  */
 
 using System;
+using System.Net;
 using System.IO;
 using System.Reflection;
 using System.Collections.Generic;
@@ -65,7 +66,7 @@ namespace Apache.NMS.ActiveMQ.Transactio
 
                 return this.location;
             }
-            set { this.location = value; }
+            set { this.location = Uri.UnescapeDataString(value); }
         }
 
         /// <summary>

Modified: activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/NetTxConnectionFactoryTest.cs
URL: http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/NetTxConnectionFactoryTest.cs?rev=1066519&r1=1066518&r2=1066519&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/NetTxConnectionFactoryTest.cs
(original)
+++ activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/test/csharp/NetTxConnectionFactoryTest.cs
Wed Feb  2 16:31:22 2011
@@ -222,6 +222,8 @@ namespace Apache.NMS.ActiveMQ.Test
         [Test]
         [TestCase("/var/log/nms/recovery/", true)]
         [TestCase("/var/temp/log/nms/recovery/", false)]
+        [TestCase("C:\\Transactions\\ReceoveryLogs", true)]
+        [TestCase("\\\\ServerName\\Transactions\\ReceoveryLogs", true)]
         public void TestConfigureRecoveryPolicyLogger(string location, bool autoCreate)
         {
             string testuri = string.Format("activemq:tcp://${{activemqhost}}:61616" +
@@ -248,8 +250,8 @@ namespace Apache.NMS.ActiveMQ.Test
                 Assert.AreEqual(autoCreate, logger.AutoCreateLocation);
             }
         }
-
-        [Test]
+				
+    	[Test]
         [TestCase("/var/log/nms/recovery/", true)]
         [TestCase("/var/temp/log/nms/recovery/", false)]
         public void TestConfigureRecoveryPolicyLoggerUsingDefaultLogger(string location,
bool autoCreate)



Mime
View raw message