protected final ChainingClassLoader chainingClassLoader; @Option(name = "--dump-config", description = "Show the effective Graylog configuration and exit") protected boolean dumpConfig = false; @Option(name = "--dump-default-config", description = "Show the default configuration and exit") protected boolean dumpDefaultConfig = false; @Option(name = {"-d", "--debug"}, description = "Run Graylog in debug mode") private boolean debug = false; @Option(name = {"-f", "--configfile"}, description = "Configuration file for Graylog") private String configFile = "/etc/graylog/server/server.conf";
public class JournalShow extends AbstractJournalCommand { @Option(name = {"-s", "--show-segments"}, description = "Show detail information for all segments") private boolean showSegmentDetails = false;
@Command(name = "truncate", description = "Truncates the journal to a given offset") public class JournalTruncate extends AbstractJournalCommand { @Option(name = {"-o", "--offset"}, description = "Truncate journal up to this offset, no remaining offset will be larger than the given offset.") @Required private long offset = Long.MIN_VALUE; public JournalTruncate() { super("truncate-journal"); } @Override protected void runCommand() { try { final long logEndOffset = journal.getLogEndOffset(); if (offset > logEndOffset) { System.err.println("Truncating journal to " + offset + " has no effect as the largest offset in the log is " + (logEndOffset - 1) + "."); } else { journal.truncateTo(offset); } } catch (IllegalArgumentException e) { System.err.println("Illegal offset value " + offset); } } }
@Option(name = {"-l", "--local"}, description = "Run Graylog in local mode. Only interesting for Graylog developers.") private boolean local = false;
@Option( name = CONFIGURATION_FILE_OPTION_NAME, description = "A file specifying configs for Ksql and its underlying Kafka Streams " @Option( name = {USERNAME_OPTION, USERNAME_SHORT_OPTION}, description = private String userName; @Option( name = {PASSWORD_OPTION, PASSWORD_SHORT_OPTION}, description = private String password; @Option( name = STREAMED_QUERY_ROW_LIMIT_OPTION_NAME, description = "An optional maximum number of rows to read from streamed queries") @Option( name = STREAMED_QUERY_TIMEOUT_OPTION_NAME, description = "An optional time limit (in milliseconds) for streamed queries") @Option( name = OUTPUT_FORMAT_OPTION_NAME, description = "The output format to use "
private String propertiesFile; @Option( name = "--queries-file", description = "Path to the query file on the local machine.")
@Command(name = "logs", description = "Retrieves the logs") public class Logs { public static enum Format { Text, Xml, Json } @Option(name = { "-f", "--format" }, title = "Format", description = "Sets the desired output format") public Format format = Format.Text; }
@Command(name = "ArgsMergeOverride") public class ArgsMergeUndeclaredOverride extends ArgsMergeAddition { /** * This is an illegal override because we failed to specify this is an override */ @Option(name = "--hidden", description = "A now visible option") private boolean hidden = false; }
@Command(name = "ArgsMergeNarrowingTypeChange") public class ArgsMergeNarrowingTypeChange extends ArgsMergeTypeParent { @Option(name = "--test", arity = 1, override = true) public C test; }
@Command(name = "Arity1") public class Arity1 { @Option(arity = 1, name = "-inspect", description = "") public boolean inspect; }
@Command(name = "ArgsMergeWideningTypeChange") public class ArgsMergeWideningTypeChange extends ArgsMergeTypeParent { /** * This is an illegal override as it involves a widening type conversion */ @Option(name = "--test", arity = 1, override = true) public A test; }
@Command(name = "ArgsMergeChangeRestrictions") public class ArgsMergeChangeRestrictions extends ArgsMergeInheritRestrictions { @Option(name = "--required") @Unrestricted public String requiredOption; }
@Command(name = "show", description = "Gives some information about the remote <name>") public static class RemoteShow extends GitCommand { @Option(name = "-n", description = "Do not query remote heads") public boolean noQuery; @Arguments(description = "Remote to show") public String remote; }
@Command(name = "ArgsDefaultOption") public class ArgsDefaultOption { @Option(name = "--test", arity = 1) @Required @DefaultOption public String arg; }
@Command(name = "ArgsDefaultOption") public class ArgsDefaultOptionBadArity { @Option(name = "--test", arity = 2) @Required @DefaultOption public List<String> arg; }