Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions RabbitMq/Fallback.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,10 +2,24 @@

namespace OldSound\RabbitMqBundle\RabbitMq;

/**
* Fallback producer for sandbox mode.
*/
class Fallback implements ProducerInterface
{
/**
* {@inheritDoc}
*/
public function publish($msgBody, $routingKey = '', $additionalProperties = array())
{
return false;
}

/**
* {@inheritDoc}
*/
public function setContentType($contentType)
{
}
}

8 changes: 8 additions & 0 deletions RabbitMq/ProducerInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -12,4 +12,12 @@ interface ProducerInterface
* @param array $additionalProperties
*/
public function publish($msgBody, $routingKey = '', $additionalProperties = array());

/**
* Set message content type
*
* @param string $contentType
*/
public function setContentType($contentType);
}