private static Object ruleMutex = new Object();
public static void requestUpdate(PipeControlPoint pcp) {
+ if (!PipingRules.enabled)
+ return;
if (DEBUG) System.out.println("PipingRules request " + pcp);
synchronized (updateMutex) {
if (!requestUpdates.contains(pcp))
}
public static boolean update() throws Exception {
+ if (!PipingRules.enabled)
+ return false;
+
if (requestUpdates.size() == 0)
return false;
else if (us.end.equals(updated))
lengthChange = PathLegUpdateType.PREV;
}
+ if (us == null) {
+ System.out.println("Null update struct " + start);
+ return;
+ }
updatePathLeg(us, lengthChange);
}
// else if (us.end.equals(updated))
// lengthChange = PathLegUpdateType.PREV;
// }
+ if (us == null) {
+ System.out.println("Null update struct " + start);
+ return;
+ }
updatePathLeg(us, lengthChange);
}
PipeControlPoint pcp = pipeRun.getControlPoints().iterator().next();
while (pcp.getPrevious() != null) {
PipeControlPoint prev = pcp.getPrevious();
- if (prev.getPipeRun() != pipeRun)
- break;
+ if (prev.getPipeRun() != pipeRun && prev.getPipeRun() != null) { // bypass possible corruption
+ break;
+ }
pcp = prev;
}
if (pcp.isDualSub()) {
}
List<PipeControlPoint> runPcps = getControlPoints(pipeRun);
if (runPcps.size() != count) {
- System.out.println("Run " + pipeRun.getName() + " contains unconnected control points");
+ System.out.println("Run " + pipeRun.getName() + " contains unconnected control points, found " + runPcps.size() + " connected, " + pcps.size() + " total.");
+ for (PipeControlPoint pcp : pcps) {
+ if (!runPcps.contains(pcp)) {
+ System.out.println("Unconnected " + pcp + " " + pcp.getPipelineComponent());
+ }
+ }
}
for (PipeControlPoint pcp : pcps) {
+ if (pcp.getPipeRun() == null) {
+ System.out.println("PipeRun ref missing " + pcp + " " + pcp.getPipelineComponent());
+ }
if (!pcp.isDirected() && pcp.getNext() == null && pcp.getPrevious() == null)
- System.out.println("Orphan undirected " + pcp);
+ System.out.println("Orphan undirected " + pcp + " " + pcp.getPipelineComponent());
}
for (PipeControlPoint pcp : pcps) {
if (pcp.getParentPoint() == null) {