Browse Source
fix: use ceiling rounding for RabbitMQ message expiration TTL
pull/25113/head
maliming
2 weeks ago
No known key found for this signature in database
GPG Key ID: A646B9CB645ECEA4
1 changed files with
1 additions and
1 deletions
-
framework/src/Volo.Abp.BackgroundJobs.RabbitMQ/Volo/Abp/BackgroundJobs/RabbitMQ/JobQueue.cs
|
|
|
@ -179,7 +179,7 @@ public class JobQueue<TArgs> : IJobQueue<TArgs> |
|
|
|
if (delay.HasValue) |
|
|
|
{ |
|
|
|
routingKey = QueueConfiguration.DelayedQueueName; |
|
|
|
basicProperties.Expiration = ((long)delay.Value.TotalMilliseconds).ToString(CultureInfo.InvariantCulture); |
|
|
|
basicProperties.Expiration = Math.Max(1, (long)Math.Ceiling(delay.Value.TotalMilliseconds)).ToString(CultureInfo.InvariantCulture); |
|
|
|
} |
|
|
|
|
|
|
|
if (ChannelAccessor != null) |
|
|
|
|