Filaments commonly form on the surface of the sun. They are made of ionized plasma suspend above the sun in loops of its magnetic field. Usually the material is drawn back into the sun by its own gravity, but sometimes they will break off and fly into space.
This is called a coronal mass ejection. If a CME collides with the Earth, it will cause beautiful auroras as the plasma is channeled into the atmosphere by the Earths magnetic field. It can also (rarely) cause power failures, destroy satellites, and fry computer chips.
The filament is part of the natural activity of our star. It has the potential to be dangerous, but the odds are very low.