fix(ext/signals): don't run exit hooks at non-exit times (#31269)
when we changed the otel exit handler to call shutdown instead of flush,
it exposed another bug where we are calling exit handlers multiple times
for the 3 signals we have defined. this meant that we would shut down
otel before the program finished running.
Fixes: https://github.com/denoland/deno/issues/31242