So what is the stress in the place where the two materials connect. It all depends on what material you care about. There is a discontinuity in the stress, but you don't care about the stress in an imaginary gap, you care about the stress in the material.