geode-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Dan Smith (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (GEODE-394) Casting FunctionContext to RegionFunctionContext is an ugly API
Date Mon, 04 Jan 2016 21:02:39 GMT

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

Dan Smith commented on GEODE-394:
---------------------------------

See the linked wiki page for details on the API changes needed.

> Casting FunctionContext to RegionFunctionContext is an ugly API
> ---------------------------------------------------------------
>
>                 Key: GEODE-394
>                 URL: https://issues.apache.org/jira/browse/GEODE-394
>             Project: Geode
>          Issue Type: Improvement
>          Components: functions
>            Reporter: Dan Smith
>            Assignee: Dan Smith
>
> If a function is invoked on a region, it's common to try to get at the local data set
for the function.
> The API do this is is pretty ugly. It should be cleaned up
> {code}
> RegionFunctionContext ctx = (RegionFunctionContext) context;
> Region data = PartitionRegionHelper.getLocalDataForContext(ctx);
> {code}
> Instead of this, functions that are invoked on regions should probably implement a different
interface that gets passed the local data they are interested in.



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

Mime
View raw message