Package org.elasticsearch.cli
Class LoggingAwareMultiCommand
- java.lang.Object
-
- org.elasticsearch.cli.Command
-
- org.elasticsearch.cli.MultiCommand
-
- org.elasticsearch.cli.LoggingAwareMultiCommand
-
- All Implemented Interfaces:
java.io.Closeable
,java.lang.AutoCloseable
- Direct Known Subclasses:
KeyStoreCli
,ShardToolCli
,TranslogToolCli
public abstract class LoggingAwareMultiCommand extends MultiCommand
A multi-command that is aware of logging. This class should be preferred over the baseMultiCommand
class for any CLI tools that depend on core Elasticsearch as they could directly or indirectly touch classes that touch logging and as such logging needs to be configured.
-
-
Field Summary
-
Fields inherited from class org.elasticsearch.cli.MultiCommand
subcommands
-
Fields inherited from class org.elasticsearch.cli.Command
description, parser
-
-
Constructor Summary
Constructors Constructor Description LoggingAwareMultiCommand(java.lang.String description)
Construct the command with the specified command description.
-
Method Summary
-
Methods inherited from class org.elasticsearch.cli.MultiCommand
close, execute, printAdditionalHelp
-
Methods inherited from class org.elasticsearch.cli.Command
addShutdownHook, exit, main
-
-
-
-
Constructor Detail
-
LoggingAwareMultiCommand
public LoggingAwareMultiCommand(java.lang.String description)
Construct the command with the specified command description. This command will have logging configured without reading Elasticsearch configuration files.- Parameters:
description
- the command description
-
-