list archives . users mailing list

Subject: Need help with ogsadai scripts

Date view Thread view Subject view Author view Attachment view

From: Shishir S. Bharathi (shishir@ISI.EDU)
Date: Mar 27, 2003 23:13

Hi,

        I recently posted a message asking how to include more than 1
statement in an ogsadai script. Well, I kinda had to figure out how to do
that for myself. But i now have several questions I'm hoping someone can
answer.

1.
I had to include a <Delivery> and <Execute> element for each <Statement>
that I had. So my script looks like
<Statement1>
<Delivery1>
<Execute1>
<Statement2>
<Delivery2>
<Execute2>
and so on.

See the attachment for an example

I tried out various combinations trying to make do with only one
<Delivery> and <Execute> but this does not seem to be possible.
With some cases, the script is executed but only one of the results show
up. In other cases, I get weird exceptions.

The Ogsadai Grid Data Service documentation says that an <Execute> will
result in the execution of all activities from the named statement upto
but not including the Execute element itself.
So why doesn't
<Statement1>
<Statement2>
<Statement3>
<Delivery>
<Execute 1>

or maybe
<Statement1>
<Delivery1>
<Statement2>
<Delivery2>
<Execute 1>

result in the execution of all the statements ?

2. Even when I got it to work, I couldn't use <UseParameter> in the
statement. This results in

        uk.org.ogsadai.wsdl.GridDataServiceSystemException:
     <description>SystemException whilst running script:
java.lang.NullPointerException</description>

Why is this ? (Using <UseParameter reference="table"/> in the example
script in statement s1 will cause this. But if I use it in statement s2
and not in s1, it works fine. Strange.)
Duplicating the list of <DefineParameter>s for each statement doesn't help
either. Doesn't seem to be the right way to do things anyway.

3. The above behavior has made me rethink how I want to use ogsadai
scripts in my application. I'm going to be running the same basic script
with different values many times. The GDS document says I can submit the
same script with different parameters. Can someone give me some examples
on how I can do this ?

4. I was also wondering if I could use the concept of PredefinedScript in
the GDS-Config to do something like this. Does anyone have information on
whether this is possible ?

Maybe the ogsadai team should consider including examples of these into
the documentation. Most uses of ogsadai will include use of more complex
scripts than the simple examples provided. And it does not seem easy to
figure out how to achieve that easily from the documentation.

Thanks in advance for anyone who might be able and willing to help.

Shishir



Date view Thread view Subject view Author view Attachment view