[kepler-dev] Adding a new director and actors to kepler/director and kepler/actors

Christopher Brooks cxh at eecs.berkeley.edu
Fri Jan 15 13:42:54 PST 2010


I want to add the ContinuousDirector to Kepler.
What do I do?


I did not find documentation about this, the closest is
https://kepler-project.org/developers/reference/adding-new-classes-jars-to-kepler
which is marked as private.

I see there is a directors repository:
bash-3.2$ ls kepler/directors
build.xml	kar		lib		resources

That directory has a kar directory that contains the kar files:

bash-3.2$ ls kepler/directors/kar
CTDirector.kar	DDFDirector.kar	DEDirector.kar	PNDirector.kar	SDFDirector.kar

How do I create a kar file such as these?
Instantiating the director using "Instantiate Attribute"
and then using "Save Archive (KAR)" creates a workflow that contains the
ContinuousDirector, but I want just the ContinuousDirector.

Do I need to create ContinuousDirector.kar by hand? (I suspect
that ContinuousDirector.kar will be created for me from the
files in the resources directory.)

I see that there is also a resources directory:
bash-3.2$ ls kepler/directors/resources
kar
bash-3.2$ ls kepler/directors/resources/kar
CTDirector	DDFDirector	DEDirector	PNDirector	SDFDirector
bash-3.2$ ls kepler/directors/resources/kar/CTDirector
CTDirector.xml	MANIFEST.MF

It looks like the contents of the kar file and the contents of the
resources directory are the same.
Why?

bash-3.2$ jar -tvf kepler/directors/kar/CTDirector.kar
      0 Thu Jan 14 13:38:38 PST 2010 META-INF/
    333 Thu Jan 14 13:38:36 PST 2010 META-INF/MANIFEST.MF
  12461 Thu Jul 23 13:48:38 PDT 2009 CTDirector.xml
    254 Tue Oct 20 17:17:36 PDT 2009 MANIFEST.MF
bash-3.2$ ls -l kepler/directors/resources/kar/CTDirector/
total 40
-rw-r--r--  1 cxh  staff  12461 Jul 23 13:48 CTDirector.xml
-rw-r--r--  1 cxh  staff    254 Oct 20 17:17 MANIFEST.MF

I guess the kar directory is created from the resources directory because
director/kar is not in svn:

bash-3.2$ svn info kar/CTDirector.kar
svn: 'kar' is not a working copy

In fact, the kar directory is listed in svn:ignore.

Looking at the kepler/directors/resources/kar/CTDirector.xml file, I
see that I could just try copying the file.

However, I have some questions:
1. CTDirector has an entityId:

<property name="entityId"  value="urn:lsid:kepler-project.org:director:4:1" class="org.kepler.moml.NamedObjId"/>
How do I update this?

2. I see that the class comment is included in the .xml file.
What happens when the class comment is updated in the java file?
Does the .xml file get automatically updated?

3. I see the .xml file has ports and parameters.  Do these get
automatically updated as the .java file changes?

Please forgive me if these questions are already answered on the website.
I could not find the answers in a cursory search.

_Christopher



-- 
Christopher Brooks, PMP                       University of California
CHESS Executive Director                      US Mail: 337 Cory Hall
Programmer/Analyst CHESS/Ptolemy/Trust        Berkeley, CA 94720-1774
ph: 510.643.9841 fax:510.642.2718	      (Office: 545Q Cory)
home: (F-Tu) 707.665.0131 cell: 707.332.0670


More information about the Kepler-dev mailing list