[cddlm] issue on a component property value

Jun Tatemura tatemura at sv.nec-labs.com
Tue Apr 18 16:57:43 CDT 2006


Dear team,

In the F2F discussion with OGSA team, we had a
question on our specs. We promised that we will discuss
in the WG.

[Q] Can a component have a parameter such that
(1) sometimes the user want to specify a value
but (2) sometimes the user want the component
to specify the value dynamically (as a default value).

In fact, it is not obvious from the current component
model or CDL.

A default value of a component property can be introduced,
for example, as param2 in the following component
description, Component1. If the user extends this
template without specifying a value on param2, 100 is
used as a default value.
However, how can a dynamic value be default?

<Component1>
 <cmp:CommandPath .../>
 <cmp:CodeBase .../>
 <param1 cdl:lazy="true"/>
 <param2>100</param2>
<Component1>

For a dynamic value, we use @cdl:lazy.
When param1 is assigned by the component,
we should specify @cdl:lazy so that any reference to
this property is resolved at run time.

However, specifying @cdl:lazy at a property
does not mean that the component MUST/SHOULD assign a value to
the property. It does not mean that the user MUST NOT/SHOULD NOT
assign a value either. In fact, CDL does not have any notion on
a role who assigns values (such as users, systems, components,
etc).

For CDL, it is fine if the user assign the value to a property
with @cdl:lazy. CDL only cares when a reference to the property
is resolved. In this sense, the question to the answer can be
'yes' - the user can assign the value to the above param1.
But we do not know whether the value is used by the component
(or just ignored).
In CDL, we cannot say if a component allows the user to
specify a specific property.

In fact, in the early design discussion, we were discussing
@cdl:use="readonly" for that purpose:
 <param1 cdl:lazy="true" cdl:use="readonly" />
For some reason (I don't remember), we have removed this from
the spec.
This means that (1) any reference to this property
is resolved at run time (2) you cannot override this property
by inheritance -- in a component model, this means that
the value can be assigned only by the component (the user is
not allowed to assign the value)

A possible solution would be one of the following:

[1] CDL-level solution:
add "readonly" as a value of @cdl:use
[2] Component-level solution:
extend the component model specification so that
one can specify how a property is used by a component.
[3] Application-level solution:
just let it unspecified (as is) and think this as a semantic
level matter the component model does not care.





More information about the cddlm-wg mailing list