SunEdison, once a poster child of the clean energy boom, filed for bankruptcy on Thursday due to a severe cash crunch.

It's a stunning reversal for SunEdison (SUNE), a solar and wind company that was worth almost $10 billion less than a year ago. But the company was hit by financial troubles in recent months caused by a mountain of debt taken on during better times.

SunEdison hopes to clean up its balance sheet through a Chapter 11 restructuring. The solar company secured $300 million in financing to keep the business afloat. The new funds will allow SunEdison to continue ongoing projects, pay wages and benefits.

The decision to file for bankruptcy was a "difficult but important step to address our immediate liquidity issues," SunEdison CEO Ahmad Chatila said in a statement.

As recently as last July, SunEdison was still flying high, with its shares trading above $33. They began to collapse soon after and are today worth just 34 cents. Trading was halted Thursday minutes before the bankruptcy filing.

Related: Largest U.S. coal company files for bankruptcy

Companies in the solar industry have been hurt by the depressed price of fossil fuels like oil and natural gas, which make renewable energy more expensive by comparison. The Guggenheim Solar ETF (TAN) has lost 50% of its value over the past year.

Rumors had been swirling in recent weeks that SunEdison could be headed for a trip to bankruptcy court. The company enjoyed rapid growth, in part thanks to aggressive use of debt and creative ways to obtain financing. SunEdison had piled up nearly $10 billion in debt as of the end of 2015.

SunEdison has been an aggressive user of "yieldcos," companies created to own and operate power plants. These entities buy power plants from their parent companies, providing fresh money that can then be plowed into new projects.

SunEdison's publicly-traded yieldcos, TerraForm Power (TERP) and TerraForm Global (GLBL), are not part of the bankruptcy filing. However, shares of each have plunged this year.

Related: Solar energy jobs double in 5 years

There is also controversy surrounding SunEdison management. The Department of Justice and the Securities and Exchange Commission are investigating whether SunEdison management misled the public over the company's dire financial straits, the Wall Street Journal reported.

The SEC declined to comment, while the DOJ said as a matter of policy it neither confirms nor denies the existence of an investigation. Representatives from SunEdison did not respond to CNNMoney's request for comment.

Earlier this month SunEdison's independent directors concluded management had an "overly optimistic culture" caused in part by a lack of sufficient controls around forecasting efforts and wrongdoing by a former non-executive who was fired. However, the review did not find fraud or willful misconduct by management.