Cleanup STREAMS-70

Additional tests
Additional logging
Fix to prepare statement for compatibility with runtime-pig