“We face the threats from rising powers — China, India, others — that we have to always have sufficient force protection out there in the Pacific to make sure they know we’re never going anywhere,” Mr. Panetta said during a visit to a shipyard in Groton, Conn., where he toured a submarine, the Mississippi, in the final stages of construction.