I can speak for the most common commercial models (the 7x7s, A3xxs and the like) via an engineer friend. All of these models flush into a tank which is emptied on the turnaround.
For Vulcans, I can speak with first hand experience. Each crew member had a stainless steel "pee tube", a funnel, which fed into a rubber bladder. They are emptied and cleaned during the after flight inspection.
I was changing a radio under the rear crew table where the electronics, navigator and radar operator sat. This involved squeezing down behind the seats to lie under the table, disconnecting and unfastening the radio, hauling onto your chest then pushing it up onto one of the seats and reversing the process to get out from under the table.
As I pushed the radio up onto the seat, I knocked one of the pee tubes and bladders out of it's clip holder which then emptied the contents onto me and the radio.
The bladder had not been emptied - and the aircraft had been in the hangar for 3 weeks!
Of course, it was my job to clean up the mess - lots of french chalk as urine is very corrosive to airframes.
The radio also needed writing up so I tagged it as "suspect urine ingress".
The same radio came back to me with a tag attached saying (and this might work only for non-American English speakers) - "are you taking the p*ss?".