Kenneth Howe created GEODE-5581:
-----------------------------------
Summary: Gfsh command extensions should not expose internal APIs
Key: GEODE-5581
URL: https://issues.apache.org/jira/browse/GEODE-5581
Project: Geode
Issue Type: Improvement
Components: gfsh
Reporter: Kenneth Howe
Adding custom gfsh commands by extending the public API classes. currently
exposes internal APIs ({{ResultModel}} and {{CliFunctionResult}})
The example below is from one of the internal commands, but shows a typical
implementation that may be used to write custom Gfsh commands. {{GfshCommand}}
and {{SingleGfshCommand}} are documented as public APIs to make it easy to
implement Geode command line extensions.
{code:title=Command example, executing function on cluster members}
public class CreateGatewayReceiverCommand extends SingleGfshCommand {
...
public ResultModel createGatewayReceiver(@CliOption(key = {CliStrings.GROUP,
CliStrings.GROUPS},
...
List<CliFunctionResult> gatewayReceiverCreateResults =
executeAndGetFunctionResult(GatewayReceiverCreateFunction.INSTANCE,
gatewayReceiverFunctionArgs, membersToCreateGatewayReceiverOn);
{code}
--
This message was sent by Atlassian JIRA
(v7.6.3#76005)