The Feynman diagram for the decay $\phi \to K^+K^-$ usually depicts two gluons. (This can be seen e.g. on Wikipedia).
Why do we need two gluons, instead of just one?
Physics Stack Exchange is a question and answer site for active researchers, academics and students of physics. It only takes a minute to sign up.Sign up to join this community
When one draws Feynman diagrams, one has to use correctly all the conservation laws. In the decay diagrams you show they are there: energy, momentum, strangeness, charge, they are all conserved by the input and output particles.
In this imagined by you case
the up- antiup pair appear out of nothing, i.e. there is no energy and momentum conservation in their creation. It will become an allowed diagram if the gluon exchanges a gluon with the pair, one of the large number of exchanges allowed by the strong interactions ( as discussed in the comments that disappeared).
If you are thinking of the figure in your question, (which is missing the antiparticle signs) to eliminate one of the gluons and take (for example) the anti-up to match with the s quark , it is again energy/momentum but in terms of probabilities, the unti-up would have to have the correct energy momentum vector to match the mass of the $K^-$ with the s quark, very improbable.