IAAMS (I am a Materials Scientist) and fatigue failure occurs by first, crack formation at some point of high stress concentration, second, crack propagation, where this crack advances little by little with each cycle, and finally failure when this crack has reached the critical size. Critical crack size depends on whether the crack is on the surface or on the interior of the material, the fracture toughness of the material, the direction the crack is oriented relative to the direction of the applied stress and the magnitude of the applied stress.
In order to combat this problem of failure, the shape of the part can be designed in such a way to minimize fatigue crack initiation sites. In general, this will mean making the part smoother with fewer sharp edges. Stress concentration goes up in areas with a small radius of curvature. The parts could made more resistant to fatigue by introducing compressive plastic deformation at the surface by shot-peening. Or it could be carburized to introduce carbon into the outer surface. This also results in a harder surface that makes the piece more resistant to fatigue failure.