If you mean that shorting the collector and emitter together operates the relay but putting a logic '1' on the MCU input doesn't operate it, the reason can only be that insufficient base current is flowing and the transistor VCE is not saturating. The 2N2222A is a low gain transistor, if your MCU has a 3.3V output, the most base current that can flow is (3.3 - 0.65) / 10,000 or 265uA. A typical Hfe of the 2N2222A is 40 so the most collector current (relay coil current) you will see is about 10.6mA (Ib * Hfe) which is probably too low.
Try dropping the base resistor to say 1K, it will still only draw a small current from the MCU but it will let you sink 10 times more current through the transistor.
Brian.