To protect their space assets from excessive radiation, NASA and other organizations research the fundamental processes behind space weather such as CMEs, integrating them into research models, which are run continuously at the Community-Coordinated Modeling Center (CCMC) at NASA Goddard.
When CMEs occur on the sun, models are generated with the best event information available at the time and propagated forward to estimate regions in the solar system that might be affected. The models take about an hour or two to run. The CMEs themselves usually take one or two days to reach other planets or spacecraft.
The March 5 CME moved towards Mars and the STEREO-B spacecraft (blue spacecraft icon). This allowed mission operators to take steps to protect STEREO-B as well as spacecraft operating around and on Mars.