Bamboo email misuses multipart/alternative, html-formatting does not display in gmail

Bamboo automatically generates emails for build failures/successes. These emails use the multipart/alternative encoding in order to provide both plain-text and html-formatted versions of the same email content. However, the order of the parts is wrong – bamboo puts the html part first and the plain-text part second. This causes gmail to display only the plain-text part even though it is capable of displaying the html-formatted email.

Bamboo is not properly conforming to RFC2046:


In general, user agents that compose multipart/alternative entities must place the body parts in increasing order of preference, that is, with the preferred format last. For fancy text, the sending user agent should put the plainest format first and the richest format last. Receiving user agents should pick and display the last format they are capable of displaying.


1 answer

Thanks for reporting! Putting aside the RFC violation, Atlassian uses GMail for our company mail and we have no problems displaying Bamboo notification emails. We checked the code and it looks like we are putting plain text first then the html mime part.

What version of Bamboo are you using? It might be possible that this was the case for older Bamboo versions. Are you able to paste the raw contents of the email that isn't displaying correctly somewhere for us to look at?

I'm on Bamboo v3.2 build 2600 - 20 Jul 11.

We have the same problem -- Bamboo is putting the html part first and the text part second, causing only the text part to display in gmail. The odd thing is, the emails USED to display correctly as html, and then one day after an IT outage and subsequent server reboot they suddenly started displaying as text. This is with Bamboo 3.1.3 build 2415 - 16 Jun 2011.

The layout of the multipart Bamboo notification emails looks like this:

Content-Type: multipart/mixed; boundary="===============2871037132198455339=="

Content-Type: multipart/alternative;

Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 7bit
Content-Disposition: inline


Content-Type: text/html; charset=UTF-8
Content-Transfer-Encoding: 7bit


Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit


Content-Type: text/plain; charset="us-ascii"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Content-Disposition: inline



Suggest an answer

Log in or Join to answer
Community showcase
Renan Battaglin
Published May 18, 2017 in Bamboo

FAQ: How to Upgrade Bamboo Server

Bamboo 5.9 will no longer be supported after June 12, 2017. What does this mean? As part of our End of Life policy, Atlassian supports major versions for two years after the first major iteratio...

1,077 views 0 5
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot