Extra settlers and workers get stored in the nearest barbarian camp. Letting them get captured is like putting them in cryogenic storage with no maintenance fees.
Extra military units? No such thing in my games. They are scouting, healing, relocating, or fighting. There is no other option.