@SuppressWarnings("unchecked")
    default <T extends StateStore> T getStateStore(final StoreBuilder<T> builder) {
        return (T) getStateStore(builder.name());
    }
Get a correctly typed state store, given a handle on the original builder.
streams/src/main/java/org/apache/kafka/streams/processor/internals/InternalProcessorContext.java