They prevent, or slow down erosion, and stop long shore drift. This, however, can have bad knock-on effects somewhere near.
A groyne is a rigid hydraulic structure built from an ocean shore (in coastal engineering) or from a bank (in rivers) that interrupts water flow and limits the movement of sediment. In the ocean, groynes create beaches, or avoid having them washed away by long shore drift. In a river, groynes prevent erosion and ice-jamming, which in turn aids navigation. Ocean groynes run generally perpendicular to the shore, extending from the upper foreshore or beach into the water. All of a groyne may be under water, in which case it is a submerged groyne. The areas between groups of groynes are groyne fields. Groynes are generally made of wood, concrete, or rock piles, and placed in groups. They are often used in tandem with seawalls. Groynes, however, may cause a shoreline to be perceived as unnatural.