Diagram shows the main forces in a trigger mechanism. Once the force exerted from the red arrows exceeds the flexural resistance of the spring section, the sear is broken and bolt released.
The spring works for trigger pull resistance, and also as a resetting mechanism for both links once broken.