private boolean isVersionedOrVersionedUpstream(final GraphNode startSeekingNode) {
        if (startSeekingNode.isOutputVersioned().isPresent()) {
            return startSeekingNode.isOutputVersioned().get();
        }

        return isVersionedUpstream(startSeekingNode);
    }
Seeks up the parent chain to determine whether the output of this node is versioned.
streams/src/main/java/org/apache/kafka/streams/kstream/internals/InternalStreamsBuilder.java