Initial preparations for InputStream