Hello @kienerj,
Java nodes can check for flow variable existence. Check here for more:
Hope it help!
Br, Ivan