minor fixes

fix IndexOutOfBoundsException
fix ingestFirehose