[ 
https://issues.apache.org/jira/browse/CASSANDRA-7563?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14218503#comment-14218503
 ] 

Tyler Hobbs commented on CASSANDRA-7563:
----------------------------------------

bq. The protocol version stuff got a bit bigger than I expected. But the new 
tests in UFTest pass. These test execution using executeInternal and using 
protocol version 2 + 3 via the Java Driver.

Looks good!

bq. I tried to make the new tests a bit more readable - hope it looks better 
now.

Thanks, this is definitely easier to read.

bq. Calling a UDF with a null value in a collection does not work - the Java 
Driver does not support that. Added a test for that (but with @Ignore 
annotation.

Sorry, I meant testing where the entire collection is null/empty.  For example, 
something like {{SELECT myfunc(mycollection) FROM ...}} where {{mycollection}} 
may be null/empty.

Some more review comments:

JavaSourceUDFFactory:
* Can you add quick docs explaining argDataTypes, returnDataType vs 
javaParamTypes, javaReturnType
* The example generated function for generateExecuteMethod() needs to be 
updated for protocolVersion in a couple of places

ScriptBasedUDF:
* Directly return {{decompose()}} result at the end of {{execute()}}

UDFunction:
* Can you add basic javadocs on type-related methods plus {{compose()}} and 
{{decompose()}}

UFTest:
* You mentioned that you had test coverage for various changes to UDTs used by 
functions, but I only see one that covers adding a field.  Can you add coverage 
for the other cases?  With the existing test, what happens if the UDT is 
altered and the function isn't replaced?  Make sure to cover failure scenarios 
in the tests.

It's getting close! Thanks for your hard work :)

> UserType, TupleType and collections in UDFs
> -------------------------------------------
>
>                 Key: CASSANDRA-7563
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-7563
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: Robert Stupp
>            Assignee: Robert Stupp
>             Fix For: 3.0
>
>         Attachments: 7563-7740.txt, 7563.txt, 7563v2.txt, 7563v3.txt, 
> 7563v4.txt
>
>
> * is Java Driver as a dependency required ?
> * is it possible to extract parts of the Java Driver for UDT/TT/coll support ?
> * CQL {{DROP TYPE}} must check UDFs
> * must check keyspace access permissions (if those exist)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to