DAVIS, Calif. (AP) — A 22-year-old police officer on the job only a few weeks was shot and killed by a suspect who opened fire as she was investigating a three-car crash, authorities in Northern California said.

The suspect, who has not been identified, was later found dead inside a home with a self-inflicted gunshot wound following a short standoff with officers, the Davis Police Department said.

Police said Officer Natalie Corona was shot after responding alone to a traffic accident shortly before 7 p.m. Thursday in the city west of Sacramento. Corona was taken to UC Davis Medical Center in Sacramento, where she later died.

Police have not determined what prompted the attack.

Following the shooting, police issued a citywide shelter in place order as officers from throughout the region searched for the suspect. Officers then spent hours trying to coax the suspect out of a home about a block from the shooting scene, using floodlights and commands on loudspeakers for him to emerge with his hands up. At one point they sent in a robot and ignited flash bang grenades, the Sacramento Bee reported.

Officials announced early Friday he had been found dead inside.

Corona, whose father spent 26 years as a Colusa County Sheriff's deputy, graduated from the Sacramento Police Department's training academy in July and completed her field training just before Christmas, officials said.

She was the first Davis officer killed in the line of duty in 60 years.

"She was a rising star in the department," Davis Police Chief Darren Pytel said. "She just worked like you can't believe."

Before she entered the academy, the Davis Police Department ran out of funding for the paid position she had been in. She didn't care; she showed up to work as a volunteer, Pytel said.

Corona is the second officer killed in California in the past two and a half weeks.

Cpl. Ronil Singh, 33, of the Newman Police Department was shot to death Dec. 26 after he stopped a suspected drunk driver.

Gustavo Arriaga Perez, also 33, was charged with the murder. Authorities said Perez Arriaga was in the country illegally and was preparing to flee to Mexico when he was arrested. That killing rekindled a debate over California's sanctuary law that limits cooperation by local officials with federal immigration authorities.