X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=blobdiff_plain;f=bundles%2Forg.simantics.project%2Fsrc%2Forg%2Fsimantics%2Fproject%2Fmanagement%2FPlatformUtil.java;h=a8916251e07c738413866bde501a42b3e7c3eec6;hb=refs%2Fchanges%2F93%2F1593%2F4;hp=ac08db001142e0b7b8b4131f101bb7e3c0f90d69;hpb=0dfe4ea2175a61a41ffa1e32b64a143076a7d362;p=simantics%2Fplatform.git diff --git a/bundles/org.simantics.project/src/org/simantics/project/management/PlatformUtil.java b/bundles/org.simantics.project/src/org/simantics/project/management/PlatformUtil.java index ac08db001..a8916251e 100644 --- a/bundles/org.simantics.project/src/org/simantics/project/management/PlatformUtil.java +++ b/bundles/org.simantics.project/src/org/simantics/project/management/PlatformUtil.java @@ -315,7 +315,11 @@ public class PlatformUtil { AtomicReference problem = new AtomicReference<>(); Collection gbundles = Arrays.stream(getBundles()) - .parallel() + // #7806: Due to databoard Binding/Serializer construction process thread-unsafety + // not even the DataContainer.readHeader invocations can run in parallel, most likely + // due to recurring serializer construction for Variant datatypes. + // Therefore, we must disable parallel loading for now. + //.parallel() .map(b -> { try { return problem.get() == null ? getGraph(b) : null; @@ -388,8 +392,10 @@ public class PlatformUtil { private static GraphBundleEx tryGetOnDemandGraph(Bundle bundle, URL url) throws IOException { try { Integer cachedHash = readCachedHash(url); - if (cachedHash == null) + if (cachedHash == null) { + LOGGER.info("No cached hash for " + bundle); return null; + } Supplier graphSource = () -> { try { @@ -439,7 +445,7 @@ public class PlatformUtil { // For an unknown reason this is totally broken when running the TestSCLOsgi // in the SDK Tycho build. It returns incomplete results because the // ReadableByteChannel used by ByteFileReader starts returning 0 unexpectedly. -// try (TransferableGraphFileReader reader = new TransferableGraphFileReader(is)) { +// try (TransferableGraphFileReader reader = new TransferableGraphFileReader(is)) { // return reader.readTG(); // } return DataContainers.readFile(new DataInputStream(is), handlers);