]> gerrit.simantics Code Review - simantics/platform.git/commitdiff
Finalizing improve startup time for fresh or rollback'd session 29/1629/5
authorTuukka Lehtonen <tuukka.lehtonen@semantum.fi>
Thu, 5 Apr 2018 13:33:58 +0000 (16:33 +0300)
committerTuukka Lehtonen <tuukka.lehtonen@semantum.fi>
Thu, 5 Apr 2018 13:33:58 +0000 (16:33 +0300)
Finally fixed the long-sought InputStream reading bug from
TransferableGraphFileReader.InputChannel.read(ByteBuffer).

The ByteFileReader implementation expected the provided
ReadableByteChannel to always provide a full buffer of data unless EOF
was encountered and the InputChannel.read implementation was not taking
care of that.

Also added simpler utilities for reading TG's from files/InputStreams
directly using static TransferableGraphFileReader.read(File/InputStream)
methods.

PlatformUtil.readTG can now finally use TransferableGraphFileReader for
maximal performance.

refs #7835

Change-Id: I170986bf271a409f9205fad808ae029becc1d3a4


No differences found