Class MetricCommand
- java.lang.Object
-
- org.apache.ignite.internal.management.api.CommandRegistryImpl<MetricCommandArg,Map<String,?>>
-
- org.apache.ignite.internal.management.metric.MetricCommand
-
- All Implemented Interfaces:
Command<MetricCommandArg,Map<String,?>>,CommandsRegistry<MetricCommandArg,Map<String,?>>,ComputeCommand<MetricCommandArg,Map<String,?>>
public class MetricCommand extends CommandRegistryImpl<MetricCommandArg,Map<String,?>> implements ComputeCommand<MetricCommandArg,Map<String,?>>
Command for printing metric values.
-
-
Field Summary
-
Fields inherited from interface org.apache.ignite.internal.management.api.Command
CMD_NAME_POSTFIX
-
-
Constructor Summary
Constructors Constructor Description MetricCommand()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Class<MetricCommandArg>argClass()Stringdescription()Command description.Collection<GridClientNode>nodes(Collection<GridClientNode> nodes, MetricCommandArg arg)voidprintResult(MetricCommandArg arg, Map<String,?> res, Consumer<String> printer)Prints command result to the user.Class<MetricTask>taskClass()-
Methods inherited from class org.apache.ignite.internal.management.api.CommandRegistryImpl
command, commands, register
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface org.apache.ignite.internal.management.api.Command
confirmationPrompt, deprecationMessage
-
Methods inherited from interface org.apache.ignite.internal.management.api.ComputeCommand
handleException
-
-
-
-
Method Detail
-
description
public String description()
Command description.- Specified by:
descriptionin interfaceCommand<MetricCommandArg,Map<String,?>>- Specified by:
descriptionin interfaceCommandsRegistry<MetricCommandArg,Map<String,?>>
-
argClass
public Class<MetricCommandArg> argClass()
- Specified by:
argClassin interfaceCommand<MetricCommandArg,Map<String,?>>- Specified by:
argClassin interfaceCommandsRegistry<MetricCommandArg,Map<String,?>>- Returns:
- Arguments class.
-
taskClass
public Class<MetricTask> taskClass()
- Specified by:
taskClassin interfaceComputeCommand<MetricCommandArg,Map<String,?>>- Returns:
- Task class.
-
nodes
public Collection<GridClientNode> nodes(Collection<GridClientNode> nodes, MetricCommandArg arg)
- Specified by:
nodesin interfaceComputeCommand<MetricCommandArg,Map<String,?>>- Parameters:
nodes- Live nodes.arg- Argument.- Returns:
- nodes to execute command on,
nullmeans default node must be used.
-
printResult
public void printResult(MetricCommandArg arg, Map<String,?> res, Consumer<String> printer)
Prints command result to the user.- Specified by:
printResultin interfaceComputeCommand<MetricCommandArg,Map<String,?>>- Parameters:
arg- Argument.res- Result.printer- Implementation specific printer.
-
-