Skip to content

CloseGateOutputSignal on empty buffer shouldn't throw an exception #98

@asubb

Description

@asubb

Sometimes, you may need to avoid starting writing to the file at the very beginning and send the CloseGateOutputSignal with the first sample. Currently it is unsupported, throws something like:

java.lang.IllegalStateException: [io.wavebeans.lib.io.FileWriterDelegate@fff7bc7] Attempting to finalize uninitialized buffer
	at io.wavebeans.lib.io.FileWriterDelegate.doFinalizeBuffer(FileWriterDelegate.kt:108)
	at io.wavebeans.lib.io.FileWriterDelegate.finalizeBuffer(FileWriterDelegate.kt:96)
	at io.wavebeans.lib.io.AbstractPartialWriter.write(AbstractWriter.kt:136)
	at io.wavebeans.execution.SingleThreadedOverseer$eval$$inlined$map$lambda$1.call(SingleThreadedOverseer.kt:35)
	at io.wavebeans.execution.SingleThreadedOverseer$eval$$inlined$map$lambda$1.call(SingleThreadedOverseer.kt:15)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:748)

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions