re: Design-for-Test for UDF facility

When this code gets to code review with tests one of the key things will be 
that we get decent diagnostics from this for all the things users can do wrong 
in creating the UDF jar, such as not having it be found, not having all the 
classes in it, not having them named right or derived properly, etc. etc. First 
cut is errors should be throwing a Daffodil-defined exception object, which 
encapsulates whatever exception object the actual underlying UDF reflection 
code or Service API call throws.


Regression testing this UDF facility will require some trickery, as some tests 
will not be ordinary JUnit-style tests, as incorrectly-constructed jars have to 
be created and used.


I recommend that we add some "official" UDFs to daffodil that are always part 
of the standard build, not because they are useful, but because they allow us 
to test the UDF system.


An important test case is also to define such a UDF which throws an exception, 
so that we can have tests that verify the exception is properly caught and 
reported.

________________________________
From: Kilo, Olabusayo <ok...@tresys.com>
Sent: Friday, September 6, 2019 10:30 AM
To: dev@daffodil.apache.org <dev@daffodil.apache.org>
Subject: [DISCUSS] User Defined Functions Capability

I'm requesting a discussion on the addition of the User Defined Functions 
capability to daffodil. The proposal referenced below provides a possible 
solution for Daffodil to be able to process and use User Defined Functions 
referenced in the DFDL Schema.

The original request can be found at 
https://issues.apache.org/jira/browse/DAFFODIL-2186 and the proposal can be 
found 
https://cwiki.apache.org/confluence/display/DAFFODIL/Proposal%3A+User+Defined+Functions.

Reply via email to