Abstract. We consider a spatially inhomogeneous sine-Gordon equation with a time-periodic drive, modeling a microwave driven long Josephson junction with phase-shifts. Under appropriate conditions, Josephson junctions with phase-shifts can have a spatially nonuniform ground state. In recent reports [Phys. Rev. Lett. 98, 117006 (2007), arXiv:0903.1046, it is experimentally shown that a microwave drive can be used to measure the eigenfrequency of a junction's ground state. Such a microwave spectroscopy is based on the observation that when the frequency of the applied microwave is in the vicinity of the natural frequency of the ground state, the junction can switch to a resistive state, characterized by a non-zero junction voltage. It was conjectured that the process is analogous to the resonant phenomenon in a simple pendulum motion driven by a time periodic external force. In the case of long junctions with phase-shifts, it would be a resonance between the internal breathing mode of the ground state and the microwave field. Nonetheless, it was also reported that the microwave power needed to switch the junction into a resistive state depends on the magnitude of the eigenfrequency to be measured. Using multiple scale expansions, we show here that an infinitely long Josephson junction with phase-shifts cannot be switched to a resistive state by microwave field with frequency close to the system's eigenfrequency, provided that the applied microwave amplitude is small enough, which confirms the experimental observations. It is because higher harmonics with frequencies in the continuous spectrum are excited, in the form of continuous wave radiation. The breathing mode thus experiences radiative damping. In the absence of driving, the breathing mode decays at rates of at most O(t −1/4 ) and O(t −1/2 ) for junctions with a uniform and nonuniform ground state, respectively. The presence of applied microwaves balances the nonlinear damping, creating a stable breather mode oscillation. As a particular example, we consider the so-called 0 − π − 0 and 0 − κ Josephson junctions, respectively representing the two cases. We confirm our analytical results numerically. Using our numerical computations, we also show that there is a critical microwave amplitude at which the junction switches to the resistive state. Yet, it appears that the switching process is not necessarily caused by the breathing mode. We show a case where a junction switches to a resistive state due to the continuous wave background becoming modulationally unstable.