I\'m currently working on a REST service allowing to control and monitor some physical devices.
The corresponding REST API is largely based on principles and ideas you c
ServiceStack.Webhooks is a new framework for easily adding webhooks to your services, no matter what architectural pattern you want to use. You can just build your own plugin.
I believe you are approaching the solution from the wrong end. You could definitely use ServiceStack to make the Web Hook calls - preferably in JSON.
What you really should be looking into is Message Queues, as they exhibit all the characteristics you would require to implement Web Hook calls (durability, message purging policies, message filtering, delivering policies, routing policies, queuing criteria)
Read more about the properties of message queues on Wikipedia
The workflow an event would follow up to the point where a Web Hook is called:
So now you have a basic notification system that should ensure a message gets delivered at least once.
Here's a great article detailing how to use TTL (Time To Live) to retry messages at intervals
I would take a somewhat different approach:
Example Workflow: WebHookQueue with Max Retries: 2, TTL: 1 day
Example message: {'event_type': 'Email_Reply', 'callback_url': '...', 'reply_level': 0, 'queued_at': '2013-09-25T22:00:00Z', data: 'json encoded'}
Message -> WebHookQueue (fail) -> WebHookQueue (fail) -> WebHookRetryQueue (incr. reply_level=1 + enqueue) -> WebHookRetryLvl1Queue (5 mins-expire) -> WebHookQueue (fail) -> WebHookQueue (fail) -> WebHookRetryQueue (incr. reply_level=2 + enqueue) -> WebHookRetryLvl2Queue (15 mins-expire) -> WebHookQueue (fail) -> WebHookQueue (fail) -> WebHookRetryQueue (drop message)
Edit
Click here to look at simple example using a WebHookQueue and a WebHookRetryQueue using message level TTL's of RabbitMQ. Due to the message level TTL's; it's not necessary to create different Retry Level queues - which might be necessary for less featured message queues.
If you had to implement such a queue with the ability to expire individual messages (not via purging policies) or schedule messages ahead of time with the option to reschedule/expire - you would most likely have had to opt for Database based queuing.
Here's a great article on CodeProject on building such a high performance queue for MSSQL Server (portable to other databases such as MySql/Postgresql/Mongodb/Couchbase etc. with effort)
Hope you found this information useful.