Author: jgomes
Date: Tue Aug 3 23:58:22 2010
New Revision: 982088
URL: http://svn.apache.org/viewvc?rev=982088&view=rev
Log:
Set the NMSTimeToLive after being unmarshalled.
Fixes [AMQNET-267]. (See https://issues.apache.org/activemq/browse/AMQNET-267)
Modified:
activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/Commands/ActiveMQMessage.cs
activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/vs2008-activemq.csproj
Modified:
activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/Commands/ActiveMQMessage.cs
URL:
http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/Commands/ActiveMQMessage.cs?rev=982088&r1=982087&r2=982088&view=diff
==============================================================================
---
activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/Commands/ActiveMQMessage.cs
(original)
+++
activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/src/main/csharp/Commands/ActiveMQMessage.cs
Tue Aug 3 23:58:22 2010
@@ -190,7 +190,15 @@ namespace Apache.NMS.ActiveMQ.Commands
/// </summary>
public TimeSpan NMSTimeToLive
{
- get { return timeToLive; }
+ get
+ {
+ if(Expiration > 0 &&
timeToLive.TotalMilliseconds <= 0.0)
+ {
+ timeToLive =
TimeSpan.FromMilliseconds(Expiration - Timestamp);
+ }
+
+ return timeToLive;
+ }
set
{
Modified:
activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/vs2008-activemq.csproj
URL:
http://svn.apache.org/viewvc/activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/vs2008-activemq.csproj?rev=982088&r1=982087&r2=982088&view=diff
==============================================================================
--- activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/vs2008-activemq.csproj
(original)
+++ activemq/activemq-dotnet/Apache.NMS.ActiveMQ/trunk/vs2008-activemq.csproj
Tue Aug 3 23:58:22 2010
@@ -2,7 +2,7 @@
<PropertyGroup>
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
<Platform Condition=" '$(Platform)' == '' ">AnyCPU</Platform>
- <ProductVersion>9.0.21022</ProductVersion>
+ <ProductVersion>9.0.30729</ProductVersion>
<SchemaVersion>2.0</SchemaVersion>
<ProjectGuid>{08321F42-4B3D-4815-B592-95962BAC3B9F}</ProjectGuid>
<OutputType>Library</OutputType>
@@ -60,6 +60,10 @@
<SpecificVersion>False</SpecificVersion>
<HintPath>lib\Apache.NMS\net-2.0\Apache.NMS.dll</HintPath>
</Reference>
+ <Reference Include="Ionic.Zlib, Version=1.9.1.5, Culture=neutral,
PublicKeyToken=edbe51ad942a3f5c, processorArchitecture=MSIL">
+ <SpecificVersion>False</SpecificVersion>
+ <HintPath>lib\DotNetZip\net-2.0\Ionic.Zlib.dll</HintPath>
+ </Reference>
<Reference Include="System" />
</ItemGroup>
<ItemGroup>