1
0
mirror of synced 2024-11-16 06:43:51 +00:00
Tapeti/Tapeti/IPublisher.cs

20 lines
589 B
C#

using System.Threading.Tasks;
using RabbitMQ.Client;
namespace Tapeti
{
// Note: Tapeti assumes every implementation of IPublisher can also be cast to an IInternalPublisher.
// The distinction is made on purpose to trigger code-smells in non-Tapeti code when casting.
public interface IPublisher
{
Task Publish(object message);
}
public interface IInternalPublisher : IPublisher
{
Task Publish(object message, IBasicProperties properties);
Task PublishDirect(object message, string queueName, IBasicProperties properties);
}
}