STREAMS-157 | Modified the way that IDs are set so that we are more tolerant to null values, which can be necessary