[drmaa-wg] Error Codes

Daniel Templeton Dan.Templeton at Sun.COM
Fri Jan 7 11:07:23 CST 2005


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