X-Git-Url: http://git.argeo.org/?a=blobdiff_plain;f=runtime%2Forg.argeo.slc.core%2Fsrc%2Fmain%2Fjava%2Forg%2Fargeo%2Fslc%2Fcore%2Fexecution%2FDefaultExecutionFlowDescriptorConverter.java;h=b2b613494c5c5d90be063d418b0290236447db90;hb=af874b12bcb864e1ee2b48e8d6e1fea3a584c53d;hp=8f13609dc8054fc88f26e3969594cb58a888b679;hpb=33972c9ec9c250bb6119648971f9bac7e0e11705;p=gpl%2Fargeo-slc.git diff --git a/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/DefaultExecutionFlowDescriptorConverter.java b/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/DefaultExecutionFlowDescriptorConverter.java index 8f13609dc..b2b613494 100644 --- a/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/DefaultExecutionFlowDescriptorConverter.java +++ b/runtime/org.argeo.slc.core/src/main/java/org/argeo/slc/core/execution/DefaultExecutionFlowDescriptorConverter.java @@ -27,6 +27,9 @@ public class DefaultExecutionFlowDescriptorConverter implements ExecutionFlowDescriptorConverter, ApplicationContextAware { public final static String REF_VALUE_TYPE_BEAN_NAME = "beanName"; + /** Workaround for https://www.spartadn.com/bugzilla/show_bug.cgi?id=206 */ + private final static String REF_VALUE_IS_FROZEN = "__frozen"; + private final static Log log = LogFactory .getLog(DefaultExecutionFlowDescriptorConverter.class); @@ -38,7 +41,13 @@ public class DefaultExecutionFlowDescriptorConverter implements Map convertedValues = new HashMap(); if (values != null) { - for (String key : values.keySet()) { + values: for (String key : values.keySet()) { + ExecutionSpecAttribute attribute = executionFlowDescriptor + .getExecutionSpec().getAttributes().get(key); + + if (attribute.getIsFrozen()) + continue values; + Object value = values.get(key); if (value instanceof PrimitiveValue) { PrimitiveValue primitiveValue = (PrimitiveValue) value; @@ -95,8 +104,12 @@ public class DefaultExecutionFlowDescriptorConverter implements // all necessary information is in the spec } } else if (attribute instanceof RefSpecAttribute) { - values.put(key, buildRefValue((RefSpecAttribute) attribute, - executionFlow, key)); + if (attribute.getIsFrozen()) { + values.put(key, new RefValue(REF_VALUE_IS_FROZEN)); + } else + values.put(key, buildRefValue( + (RefSpecAttribute) attribute, executionFlow, + key)); } else { throw new SlcException("Unkown spec attribute type " + attribute.getClass());