You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cassandra.apache.org by "Zachary Kurey (JIRA)" <ji...@apache.org> on 2015/06/03 01:52:49 UTC

[jira] [Commented] (CASSANDRA-9409) Ensure that UDF and UDAs are keyspace-isolated

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

Zachary Kurey commented on CASSANDRA-9409:
------------------------------------------

Is it expected that built in functions cannot be resolved by a UDA unless we specify the system keyspace?  For example:
{code}
CREATE AGGREGATE if not exists ks.my_agg(int) 
SFUNC ks.adder
STYPE int
FINALFUNC intasblob
;
{code}

Gives me me the error:
{quote}Final function ks.intasblob(int) does not exist or is not a scalar function{quote}  
Prefixing with 'system.' fixes the issue.  But I was expecting it to resolve as if I were using a built in function elsewhere.


> Ensure that UDF and UDAs are keyspace-isolated
> ----------------------------------------------
>
>                 Key: CASSANDRA-9409
>                 URL: https://issues.apache.org/jira/browse/CASSANDRA-9409
>             Project: Cassandra
>          Issue Type: Bug
>            Reporter: Aleksey Yeschenko
>            Assignee: Robert Stupp
>              Labels: qa-resolved
>             Fix For: 2.2.0 rc1
>
>         Attachments: 9409-with-system.txt, 9409.txt
>
>
> In table columns we don't allow to use UDTs from other keyspaces.
> We should also make sure that the following is *not* allowed:
> - UDFs taking UDTs from other keyspaces as arguments or return types
> - UDAs using UDFs from other keyspaces as its subfunctions
> The only exception should be made for {{system}} keyspace. UDAs and UDFs from any keyspace should be able to reference and reuse those.
> Having no dependencies between keyspaces makes this consistent with the way we treat UDTs, which is important, but also simplifies auth in multi-tenant environments, and is also crucial to upcoming 3.X strongly consistent schema work (the ability to treat keyspace as a unit of change and not having to worry about cross-keyspace dependencies).
> P.S. Should *probably* still allow using other keyspaces UDFs and UDAs in {{SELECT}} statements. Strict isolation in schema dependencies is what matters to me here.



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