President Obama will attend an interfaith service in Boston on Thursday memorializing victims of Monday’s deadly terrorist attack.

The trip underlines the political maxim that the biggest threat to leaders is posed by unexpected events, for the bomber or bombers have thrown Obama off course at a crucial moment when gun control and immigration legislation — big second-term items — had arrived at the top of the legislative agenda.

At press time, it was revealed that a ricin-tainted letter was sent to Sen. Roger Wicker Roger Frederick WickerHillicon Valley: DOJ indicts Chinese, Malaysian hackers accused of targeting over 100 organizations | GOP senators raise concerns over Oracle-TikTok deal | QAnon awareness jumps in new poll Shakespeare Theatre Company goes virtual for 'Will on the Hill...or Won't They?' Republican Senators raise concerns over Oracle-TikTok deal MORE (R-Miss.).

ADVERTISEMENT

Allies of the president on immigration were forced this week to put off a press conference to highlight their bill, while on Democrats pushing the gun bill were scrambling to build support for the legislation’s centerpiece — tighter background checks on firearm purchases.

The efforts are two of Obama’s biggest priorities, and the gun legislation looks to be in particular trouble, with Democrats apparently short of the 60 votes they need for passage.

If the president was worried or distracted, however, he and his aides were doing everything they could to not show it.

Repeatedly on Tuesday, Obama sought to telegraph the message that his administration was fully in charge of developments in Boston, even as he kept his pace on other issues.

“To quote George W. Bush, ‘We can’t let the terrorists win,’” Democratic strategist Jamal Simmons said. “The president does have to pay attention to those legislative items and keep the ship of state sailing.”

Obama avoided canceling anything on his full schedule.

He addressed the public twice about Boston within 20 hours of the attack and met throughout the day with top national security aides and Cabinet secretaries. His press office and Flickr account distributed photos that underlined the perception of a president in control.

A White House official said Obama continued to receive updates overnight on the investigation and would meet with Attorney General Eric Holder Eric Himpton HolderThe Hill's Campaign Report: Trump's rally risk | Biden ramps up legal team | Biden hits Trump over climate policy Biden campaign forming 'special litigation' team ahead of possible voting battle Pompeo, Engel poised for battle in contempt proceedings MORE, FBI Director Robert Mueller and homeland security adviser Lisa Monaco for a briefing Wednesday morning.

At the same time, Obama maintained a business-as-usual approach.

Keeping to his schedule, Obama hosted Crown Prince Mohammed bin Zayed al Nahyan of the United Arab Emirates for a discussion on the NATO missions in Afghanistan and Libya, as well as NASCAR champion Brad Keselowski.

Obama even suggested that canceling the meeting would be a victory for the terrorists. But the fact that it was necessary for him to do so was a demonstration of how much the national conversation has changed since the first blast detonated at 2:50 p.m. on Monday.

“Obviously our minds right now are very much with our fellow Americans,” he said with the NASCAR champ. “We don’t let such cowardly acts get in the way of our lives.”

Obama added a meeting Tuesday afternoon on immigration with Sens. John McCain John Sidney McCainKelly's lead widens to 10 points in Arizona Senate race: poll COVID response shows a way forward on private gun sale checks Trump pulls into must-win Arizona trailing in polls MORE (R-Ariz.) and Charles Schumer Chuck SchumerDemocrats scramble on COVID-19 relief amid division, Trump surprise Pelosi, Schumer 'encouraged' by Trump call for bigger coronavirus relief package Schumer, Sanders call for Senate panel to address election security MORE (D-N.Y.), two sponsors of the bill introduced Tuesday.

Vice President Biden went to the Capitol Hill dedication of a room named for Gabe Zimmerman, an aide to former Rep. Gabrielle Giffords (R-Ariz.). Zimmerman died in the 2011 Tucson, Ariz., mass shooting, and the vice president’s attendance was seen as a chance to lobby lawmakers on the gun control bill.

The White House announced Obama would dine on Wednesday with a dozen Democratic senators.

“Presidents always have to be ready to deal with incidents like the one that happened yesterday in Boston. It’s part of their job description,” Democratic strategist Tad Devine said. “But at a time of intense legislative activity, he also needs to make sure that momentum continues. They have to stay on the front burner while he deals with the course of events. He can’t be distracted.”

Democratic allies say that Obama has been tested in this way before. During his first presidential run in 2008, Obama opted to continue campaigning despite the economic collapse on Wall Street. In his reelection bid, he juggled coordinating the response to Hurricane Sandy with the requirements of the campaign trail.

“It’s walking a tightrope, but I think the president and his team have demonstrated in the past that they’re certainly up to the challenge,” Democratic strategist Doug Thornell said.

The deadly terrorist attack could pose a threat to Obama’s second-term agenda if it undermines him with the public. The attack on Boston is the first terrorist attack on U.S. soil since 13 people were killed in a 2009 shooting spree at Fort Hood in Texas.

Until a suspect is identified, the potential federal responses — and political consequences — are unknowable.

Yet it is also a chance for Obama to lead.

“This is going to be a large-scale investigation that involves local, state and federal investigators, and there are going to be a lot of things that come out that aren’t accurate,” Thornell said. “I think the most important thing is to do what they’ve been doing: don’t allow misinformation to fester and they’re as clear and concise with what they know as they can be.”

For now, Obama’s political rivals are giving him a wide berth. Speaker John Boehner John Andrew BoehnerLongtime House parliamentarian to step down Five things we learned from this year's primaries Bad blood between Pelosi, Meadows complicates coronavirus talks MORE (R-Ohio) told reporters Tuesday he was “confident that we’ll get to the bottom of it.”

This story was updated at 9:03 a.m.