Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-10302

Extract body from nested multiparts

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Resolved
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 2.17.3
    • Fix Version/s: 2.18.0
    • Component/s: camel-mail
    • Labels:
      None
    • Patch Info:
      Patch Available
    • Estimated Complexity:
      Unknown

      Description

      The camel-mail component currently handle mails with attachments where the mail body is a plain text message. In this case the MIME-Structure looks as follows:

      mulipart/mixed
      |- text/plain   -> body
      |- image/png    -> attachment[0]
      |- text/plain   -> attachment[1]
      

      However if the mail is e.g. sent by Outlook and the mail body contains formating and a picture, the resulting multipart structure might look like this

      multipart/mixed
      |- multipart/related
      |  |- multipart/alternative
      |  |  |- text/plain  -> body
      |  |  |- text/html
      |  |- image/png      -> attachment[0]
      |- text/plain        -> attachment[1]
      

      Without the patch, the attachments will be as expected, but the body will be the same as attachment[1] (or some bogus string if the mail does not contain a text attachment).

        Attachments

          Activity

            People

            • Assignee:
              siano Stephan Siano
              Reporter:
              siano Stephan Siano
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: