Skip to content

Commit

Permalink
Add push_headers for push queues
Browse files Browse the repository at this point in the history
  • Loading branch information
alex-litvak committed Dec 18, 2015
1 parent 0cdb757 commit 8d20b65
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
9 changes: 8 additions & 1 deletion src/IronSharp.IronMQ/MessageOptions.cs
@@ -1,4 +1,5 @@
using IronSharp.Core;
using System.Collections.Generic;
using IronSharp.Core;
using Newtonsoft.Json;

namespace IronSharp.IronMQ
Expand Down Expand Up @@ -29,6 +30,12 @@ public class MessageOptions : IInspectable
/// </summary>
[JsonProperty("timeout", DefaultValueHandling = DefaultValueHandling.Ignore)]
public int? Timeout { get; set; }

/// <summary>
/// When message is sent to a push queue these headers will be passed to subscribers
/// </summary>
[JsonProperty("push_headers", DefaultValueHandling = DefaultValueHandling.Ignore)]
public Dictionary<string, string> PushHeaders { get; set; }

/// <summary>
/// When message is reserved this property stores actual reservation_id. This id can be used
Expand Down
1 change: 1 addition & 0 deletions src/IronSharp.IronMQ/QueueMessage.cs
Expand Up @@ -15,6 +15,7 @@ public QueueMessage(string body, MessageOptions options = null)
Delay = options.Delay;
ExpiresIn = options.ExpiresIn;
Timeout = options.Timeout;
PushHeaders = options.PushHeaders;
}

protected QueueMessage()
Expand Down

0 comments on commit 8d20b65

Please sign in to comment.