Sunoco LP (SUN 0.87%) primarily makes money from two sources. It operates 1,355 convenience stores and retail fuel sites, and it distributes motor fuel to 7,825 convenience stores, independent dealers, and commercial customers and distributors. While the retail segment was its biggest moneymaker in 2015, the segments were neck and neck last year. That said, the wholesale distribution business has pulled ahead in 2017 and will remain the company's biggest moneymaker for the foreseeable future since it recently announced the sale of the majority of its retail outlets to 7-Eleven. Here's a closer look at how this segment makes money and what Sunoco LP might do to grow its earnings in the future.

A closer look at the wholesale business

Sunoco LP's wholesale segment distributes motor fuel to 5,660 locations consisting of both third-party dealers and distributors under long-term supply agreements that provide it with a relatively predictable earnings stream. In addition, it supplies 2,165 commercial customers with fuel on a short-term or spot basis that have more earnings volatility depending on pricing. Overall, about 85% of the segment's revenue come from distributing motor fuel, with the rest derived from rent and other sources, including race fuel manufacturing, transmix production, and operating fuel terminals. Overall, the segment recorded $337 million of adjusted EBITDA during 2016 versus $328 million for the retail segment, which it earned by distributing 5.3 billion gallons of fuel, collecting an average margin of $0.098 per gallon

Fuel tanker truck delivering gasoline to a gas station.

Image source: Getty Images.

The segment is off to a mixed start in 2017. Adjusted EBITDA was $95 million during the first quarter, which while down from $103 million in the year-ago quarter, vastly outperformed the retail segment, which generated $60 million in adjusted EBITDA in the quarter. The decline in earnings from the wholesale segment came despite a 6.5% increase in volumes sold due to growth in the Southwest and the contribution of the wholesale fuel distribution and terminalling business it acquired from Emerge Energy Services (NYSE: EMES) last year. The culprit was the fact that the company only earned $0.106 per gallon on those volumes, down from $0.114 per gallon in the year-ago period due to lower spot market pricing.

The steady shift toward wholesale

Sunoco LP's strategic divestiture of the majority of its convenience stores to 7-Eleven was a significant step forward as it shifts the focus to its leading fuel supply business. Not only does that sale result in 1,110 convenience stores changing hands in exchange for $3.3 billion in cash but 7-Eleven signed a 15-year take-or-pay fuel supply agreement with Sunoco LP starting with 2.2 billion gallons per year. That contract increases the customer base of its wholesale segment to more than 8,900 locations and will provide the company with predictable cash flow for years to come.

In addition to that, Sunoco LP plans to sell about 200 of its remaining convenience stores in a separate process. Once that transaction is complete, the only remaining retail assets will be its integrated Aloha Petroleum business unit in Hawaii and the APlus franchisee-operated stores.

Aside from these transactions to shrink its retail segment, the other driver of the company's shift toward wholesale in recent years has been acquisitions made to grow that business. For example, it spent $178.5 million last year to acquire two transmix plants that can process 10,000 barrels per day and 800,000 barrels of storage capacity from Emerge Energy Services. Sunoco LP did so because these businesses were complementary to its core wholesale network and further diversified its income stream. In addition to that deal, the company made two retail-wholesale hybrid transactions last year, buying Denny Oil's convenience store assets and wholesale fuel business for $53 million and purchasing the Rattlers retail-wholesale business in June. Before that, it bought wholesale fuel distributor Alta East at the end of 2015 for $57 million.

Once Sunoco completes its retail divestitures, it will vastly improve its currently troubling financial profile, giving it the flexibility to pursue additional wholesale acquisitions. These future deals will likely expand its operations in core markets along the East Coast and Texas, as well as extend its reach into new geographies such as the West Coast. Meanwhile, the company will also likely look for transactions that diversify its revenue and provide new platforms for future growth, similar to the Emerge Energy Services deal, which gave it a toehold in the storage sector. Given the highly fragmented nature of the fuel distribution sector, the company should have plenty of opportunities as it seeks to consolidate the industry further.

Investor takeaway

Sunoco LP makes most of its money distributing gasoline to retail stores. Once the 7-Eleven deal goes through, the new Sunoco LP will sell 86% of its volumes under long-term fixed-fee contracts, which will give it a steady base of cash flow. That predictable cash flow stream will help support the company's ability to pay a sustainable distribution to investors, which it can grow by expanding the business via acquisitions. It's a formula the company hopes will lead to steady value creation in the years ahead.