What: Shares of Chicago Bridge and Iron Company N.V. (CBI) jumped as much as 19% today after the company said that it was selling its nuclear business to Westinghouse Electric Company.

So what: The deal will sell Chicago Bridge and Iron's nuclear construction business, but keep some of the maintenance operations in-house. Westinghouse will pay $229 million in cash, expected as completion installments, for the business, and importantly, indemnify CB&I for "previous, current and future liabilities associated with the AP1000 nuclear projects". CB&I expects to take a $1.0 billion to $1.2 billion loss on the transaction, including $904 million in the third quarter.  

Now what: This shows just how big a headache the nuclear business has become for CB&I, that it would essentially give it away in return for indemnification. Westinghouse was the designer of the AP1000 nuclear reactors that have caused so many problems for the company, and now utilities will essentially have a one-stop shop for design and construction for those reactors.

At the end, even a huge loss on this sale had investors cheering, and long term, this should provide some stability to CB&I. It rarely happens, but this deal seems like a win-win for everyone involved.