[drmaa-wg] Error Codes
Rajic, Hrabri
hrabri.rajic at intel.com
Mon Jan 10 10:02:04 CST 2005
Dan,
On a minor note, you could also leave DRMAA_ERRNO_NO_MEMORY_ERROR and
DRMAA_ERRNO_INVALID_ARGUMENT intact and chain them to the below
mentioned exceptions. It will make things cross language more
consistent.
It doesn't change much in practice, but it could make more formal people
happy.
-Hrabri
-----Original Message-----
From: owner-drmaa-wg at ggf.org [mailto:owner-drmaa-wg at ggf.org] On Behalf
Of Daniel Templeton
Sent: Friday, January 07, 2005 11:07 AM
To: DRMAA Working Group
Subject: [drmaa-wg] Error Codes
I just (almost) finished the 0.6 draft of the Java language binding. It
is now a stand-alone document. (36 pages!) In the course of having to
reread through everything and explain everything, I noticed that there
are two more error codes which I don't think we need in the Java
language binding. (We already skip the DRMAA_ERRNO_NO_MEMORY_ERROR sine
that's covered by the java.lang.OutOfMemoryError.)
The first is the DRMAA_ERRNO_INVALID_ARGUMENT. I think this error is
covered nicely by the java.lang.IllegalArgumentException and
java.lang.NullPointerException. Besides, I don't think it actually
applies. The INVALID_ARGUMENT is there to cover off-the-wall cases,
where a completely wrong argument value is passed in, such as passing a
pointer to a drmaa_job_template_t as the job id. Java is strongly
typed, so that can't happen. The only thing you can do is pass in null,
and that's what the NullPointerException is there for.
The second is the DRMAA_ERRNO_INVALID_ATTRIBUTE_FORMAT. It is used to
indicate that the format of the string doesn't match what the attribute
expects. In the Java language binding, we have strongly typed
properties, so it isn't possible to pass in a badly formatted attribute
value.
Comments? If not, I'm removing these two exceptions from the spec.
I have one more small section to finish, and then I will send out the
new draft. If everyone else happy with this draft, I think we can
relabel it 1.0.
Daniel
More information about the drmaa-wg
mailing list