0

I am trying to send an Email through Iron.io service. Everything is working as expected except that if the body of the message is big I get this error.

Is there a way to bypass this limitation and fix the problem?

My Stack Trace Exception

[2014-06-11 17:48:07] local.ERROR: exception 'Http_Exception' with message 'http error: 400 | {"msg":"Message must be no more than 64kB"}' in /var/www/lbook/vendor/iron-io/iron_core/IronCore.class.php:264

0 /var/www/lbook/vendor/iron-io/iron_core/IronCore.class.php(256): IronCore->reportHttpError(400, '{"msg":"Message...')

1 /var/www/lbook/vendor/iron-io/iron_core/IronCore.class.php(230): IronCore->callWithRetries()

2 /var/www/lbook/vendor/iron-io/iron_mq/IronMQ.class.php(272): IronCore->apiCall('POST', 'projects/535a62...', Array)

3 /var/www/lbook/vendor/laravel/framework/src/Illuminate/Queue/IronQueue.php(81): IronMQ->postMessage('appdev', 'eyJpdiI6IjgzQVp...', Array)

4 /var/www/lbook/vendor/laravel/framework/src/Illuminate/Queue/IronQueue.php(66): Illuminate\Queue\IronQueue->pushRaw('{"job":"mailer@...', NULL)

5 [internal function]: Illuminate\Queue\IronQueue->push('mailer@handleQu...', Array, NULL)

George D.
  • 1,630
  • 4
  • 23
  • 41
  • Not familiar, but looking at the message constraints chart at http://dev.iron.io/mq/reference/environment/ it would seem as though 64kb is the limit. Not sure if it's possible but if it was necessary to increase this, the only way to get it done would be to call them and have them set it higher for you. – user1669496 Jun 11 '14 at 17:05

1 Answers1

0

64KB is the maximum total message size allowed on that platform.

You could

  1. gzip the message body or
  2. just send the data to be able to recreate the message, and not the entire thing or
  3. save the email into a database or elsewhere, and send an ID/reference for the worker to pickup and fetch
Alister Bulman
  • 34,482
  • 9
  • 71
  • 110