diff --git a/fcli-core/fcli-common/src/main/java/com/fortify/cli/common/output/cli/mixin/OutputHelperMixins.java b/fcli-core/fcli-common/src/main/java/com/fortify/cli/common/output/cli/mixin/OutputHelperMixins.java index 2cf33ee6bd..2c5fd714d7 100644 --- a/fcli-core/fcli-common/src/main/java/com/fortify/cli/common/output/cli/mixin/OutputHelperMixins.java +++ b/fcli-core/fcli-common/src/main/java/com/fortify/cli/common/output/cli/mixin/OutputHelperMixins.java @@ -106,7 +106,7 @@ public static class Delete extends TableNoQuery { public static final String CMD_NAME = "delete"; } - @Command(aliases = {"rm-template", "rmt"}) + @Command(aliases = {"rmt"}) public static class DeleteTemplate extends TableNoQuery { public static final String CMD_NAME = "delete-template"; } @@ -124,7 +124,7 @@ public static class List extends TableWithQuery { public static final String CMD_NAME = "list"; } - @Command(aliases = {"listdef", "lsd"}) + @Command(aliases = {"lsd"}) public static class ListDefinitions extends TableWithQuery { public static final String CMD_NAME = "list-definitions"; } @@ -138,7 +138,6 @@ public static class Get extends DetailsNoQuery { public static final String CMD_NAME = "get"; } - @Command(aliases = {"getdef"}) public static class GetDefinition extends DetailsNoQuery { public static final String CMD_NAME = "get-definition"; } @@ -159,6 +158,10 @@ public static class Set extends TableNoQuery { public static class Update extends TableNoQuery { public static final String CMD_NAME = "update"; } + + public static class UpdateTemplate extends TableNoQuery { + public static final String CMD_NAME = "update-template"; + } public static class Enable extends TableNoQuery { diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_common/output/cli/mixin/SSCOutputHelperMixins.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_common/output/cli/mixin/SSCOutputHelperMixins.java index b95f4e0465..3f132cdadd 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_common/output/cli/mixin/SSCOutputHelperMixins.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_common/output/cli/mixin/SSCOutputHelperMixins.java @@ -15,6 +15,7 @@ import com.fortify.cli.common.output.cli.mixin.IOutputHelper; import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins.DetailsNoQuery; +import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins.TableNoQuery; import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins.TableWithQuery; import picocli.CommandLine.Command; @@ -49,12 +50,11 @@ public static class ImportDebricked extends OutputHelperMixins.TableNoQuery { public static final String CMD_NAME = "import-debricked"; } - @Command(aliases = {"list-fs", "lsfs"}) + @Command(aliases = {"lsfs"}) public static class ListFilterSets extends TableWithQuery { public static final String CMD_NAME = "list-filtersets"; } - @Command(aliases = {"get-fs"}) public static class GetFilterSet extends DetailsNoQuery { public static final String CMD_NAME = "get-filterset"; } @@ -90,5 +90,34 @@ public static class VulnCount extends OutputHelperMixins.TableWithQuery { public static final String CMD_NAME = "count"; } - + @Command(aliases = {"lsa"}) + public static class ListActivities extends TableWithQuery { + public static final String CMD_NAME = "list-activities"; + } + + @Command(aliases = {"lse"}) + public static class ListEvents extends TableWithQuery { + public static final String CMD_NAME = "list-events"; + } + + @Command(aliases = {"lsj"}) + public static class ListJobs extends TableWithQuery { + public static final String CMD_NAME = "list-jobs"; + } + + public static class CancelJob extends TableNoQuery { + public static final String CMD_NAME = "cancel-job"; + } + + public static class UpdateJob extends TableNoQuery { + public static final String CMD_NAME = "update-job"; + } + + public static class GetJob extends DetailsNoQuery { + public static final String CMD_NAME = "get-job"; + } + + public static class UploadSeedBundle extends TableNoQuery { + public static final String CMD_NAME = "upload-seed-bundle"; + } } diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_common/session/helper/SSCSessionDescriptor.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_common/session/helper/SSCSessionDescriptor.java index 2c448286cf..e2dc0fc27a 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_common/session/helper/SSCSessionDescriptor.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_common/session/helper/SSCSessionDescriptor.java @@ -24,8 +24,8 @@ import com.fortify.cli.common.util.StringUtils; import com.fortify.cli.ssc.token.helper.SSCTokenCreateRequest; import com.fortify.cli.ssc.token.helper.SSCTokenCreateResponse; -import com.fortify.cli.ssc.token.helper.SSCTokenHelper; import com.fortify.cli.ssc.token.helper.SSCTokenCreateResponse.SSCTokenData; +import com.fortify.cli.ssc.token.helper.SSCTokenHelper; import lombok.Data; import lombok.EqualsAndHashCode; diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_main/cli/cmd/SSCCommands.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_main/cli/cmd/SSCCommands.java index 20c12cde14..ea76a91bac 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_main/cli/cmd/SSCCommands.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/_main/cli/cmd/SSCCommands.java @@ -14,23 +14,19 @@ import com.fortify.cli.common.cli.cmd.AbstractContainerCommand; import com.fortify.cli.ssc._common.session.cli.cmd.SSCSessionCommands; -import com.fortify.cli.ssc.activity_feed.cli.cmd.SSCActivityFeedCommands; import com.fortify.cli.ssc.alert.cli.cmd.SSCAlertCommands; import com.fortify.cli.ssc.app.cli.cmd.SSCAppCommands; import com.fortify.cli.ssc.appversion.cli.cmd.SSCAppVersionCommands; import com.fortify.cli.ssc.appversion_user.cli.cmd.SSCAppVersionUserCommands; import com.fortify.cli.ssc.artifact.cli.cmd.SSCArtifactCommands; import com.fortify.cli.ssc.attribute.cli.cmd.SSCAttributeCommands; -import com.fortify.cli.ssc.event.cli.cmd.SSCEventCommands; import com.fortify.cli.ssc.issue.cli.cmd.SSCIssueCommands; -import com.fortify.cli.ssc.issue_template.cli.cmd.SSCIssueTemplateCommands; -import com.fortify.cli.ssc.job.cli.cmd.SSCJobCommands; import com.fortify.cli.ssc.performance_indicator.cli.cmd.SSCPerformanceIndicatorCommands; import com.fortify.cli.ssc.plugin.cli.cmd.SSCPluginCommands; import com.fortify.cli.ssc.report.cli.cmd.SSCReportCommands; import com.fortify.cli.ssc.rest.cli.cmd.SSCRestCommands; import com.fortify.cli.ssc.role.cli.cmd.SSCRoleCommands; -import com.fortify.cli.ssc.seed_bundle.cli.cmd.SSCSeedBundleCommands; +import com.fortify.cli.ssc.system_state.cli.cmd.SSCSystemStateCommands; import com.fortify.cli.ssc.token.cli.cmd.SSCTokenCommands; import com.fortify.cli.ssc.user.cli.cmd.SSCUserCommands; @@ -49,22 +45,18 @@ // 'rest' has a different header ('Interact with' compared to most // other commands ('Manage'). SSCSessionCommands.class, - SSCActivityFeedCommands.class, SSCAlertCommands.class, SSCAppCommands.class, SSCAppVersionCommands.class, SSCAppVersionUserCommands.class, SSCArtifactCommands.class, SSCAttributeCommands.class, - SSCEventCommands.class, SSCIssueCommands.class, - SSCIssueTemplateCommands.class, - SSCJobCommands.class, SSCPerformanceIndicatorCommands.class, SSCPluginCommands.class, SSCReportCommands.class, SSCRoleCommands.class, - SSCSeedBundleCommands.class, + SSCSystemStateCommands.class, SSCTokenCommands.class, SSCUserCommands.class, SSCRestCommands.class, diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/activity_feed/cli/cmd/SSCActivityFeedCommands.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/activity_feed/cli/cmd/SSCActivityFeedCommands.java deleted file mode 100644 index a5e966bf18..0000000000 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/activity_feed/cli/cmd/SSCActivityFeedCommands.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright 2021, 2023 Open Text. - * - * The only warranties for products and services of Open Text - * and its affiliates and licensors ("Open Text") are as may - * be set forth in the express warranty statements accompanying - * such products and services. Nothing herein should be construed - * as constituting an additional warranty. Open Text shall not be - * liable for technical or editorial errors or omissions contained - * herein. The information contained herein is subject to change - * without notice. - *******************************************************************************/ -package com.fortify.cli.ssc.activity_feed.cli.cmd; - -import com.fortify.cli.common.cli.cmd.AbstractContainerCommand; - -import picocli.CommandLine.Command; - -@Command( - name = "activity-feed", - subcommands = { - SSCActivityFeedListCommand.class - } -) -public class SSCActivityFeedCommands extends AbstractContainerCommand { -} diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/appversion/cli/cmd/SSCAppVersionCreateCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/appversion/cli/cmd/SSCAppVersionCreateCommand.java index 2b35bfef92..2115d89706 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/appversion/cli/cmd/SSCAppVersionCreateCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/appversion/cli/cmd/SSCAppVersionCreateCommand.java @@ -35,8 +35,8 @@ import com.fortify.cli.ssc.appversion_user.helper.SSCAppVersionUserUpdateBuilder; import com.fortify.cli.ssc.attribute.cli.mixin.SSCAttributeUpdateMixin; import com.fortify.cli.ssc.attribute.helper.SSCAttributeUpdateBuilder; -import com.fortify.cli.ssc.issue_template.cli.mixin.SSCIssueTemplateResolverMixin; -import com.fortify.cli.ssc.issue_template.helper.SSCIssueTemplateDescriptor; +import com.fortify.cli.ssc.issue.cli.mixin.SSCIssueTemplateResolverMixin; +import com.fortify.cli.ssc.issue.helper.SSCIssueTemplateDescriptor; import kong.unirest.HttpRequest; import kong.unirest.UnirestInstance; diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/appversion/cli/cmd/SSCAppVersionUpdateCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/appversion/cli/cmd/SSCAppVersionUpdateCommand.java index 0f8ccf5c2f..e055b1944d 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/appversion/cli/cmd/SSCAppVersionUpdateCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/appversion/cli/cmd/SSCAppVersionUpdateCommand.java @@ -31,8 +31,8 @@ import com.fortify.cli.ssc.appversion_user.helper.SSCAppVersionUserUpdateBuilder; import com.fortify.cli.ssc.attribute.cli.mixin.SSCAttributeUpdateMixin; import com.fortify.cli.ssc.attribute.helper.SSCAttributeUpdateBuilder; -import com.fortify.cli.ssc.issue_template.cli.mixin.SSCIssueTemplateResolverMixin; -import com.fortify.cli.ssc.issue_template.helper.SSCIssueTemplateDescriptor; +import com.fortify.cli.ssc.issue.cli.mixin.SSCIssueTemplateResolverMixin; +import com.fortify.cli.ssc.issue.helper.SSCIssueTemplateDescriptor; import kong.unirest.HttpRequest; import kong.unirest.UnirestInstance; diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/event/cli/cmd/SSCEventCommands.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/event/cli/cmd/SSCEventCommands.java deleted file mode 100644 index f61f833bb6..0000000000 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/event/cli/cmd/SSCEventCommands.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright 2021, 2023 Open Text. - * - * The only warranties for products and services of Open Text - * and its affiliates and licensors ("Open Text") are as may - * be set forth in the express warranty statements accompanying - * such products and services. Nothing herein should be construed - * as constituting an additional warranty. Open Text shall not be - * liable for technical or editorial errors or omissions contained - * herein. The information contained herein is subject to change - * without notice. - *******************************************************************************/ -package com.fortify.cli.ssc.event.cli.cmd; - -import com.fortify.cli.common.cli.cmd.AbstractContainerCommand; - -import picocli.CommandLine.Command; - -@Command( - name = "event", - subcommands = { - SSCEventListCommand.class - } -) -public class SSCEventCommands extends AbstractContainerCommand { -} diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueCommands.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueCommands.java index 77f520cac0..0f663c1211 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueCommands.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueCommands.java @@ -19,6 +19,12 @@ @Command( name = "issue", aliases = "vulnerability", subcommands = { + SSCIssueTemplateCreateCommand.class, + SSCIssueTemplateDeleteCommand.class, + SSCIssueTemplateDownloadCommand.class, + SSCIssueTemplateGetCommand.class, + SSCIssueTemplateListCommand.class, + SSCIssueTemplateUpdateCommand.class, SSCIssueFilterSetGetCommand.class, SSCIssueFilterSetListCommand.class, SSCIssueFilterGetCommand.class, diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateCreateCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateCreateCommand.java similarity index 91% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateCreateCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateCreateCommand.java index 8fd6681dda..83f440e0b6 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateCreateCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateCreateCommand.java @@ -10,11 +10,12 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.issue_template.cli.cmd; +package com.fortify.cli.ssc.issue.cli.cmd; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.node.ObjectNode; import com.fortify.cli.common.cli.mixin.CommonOptionMixins; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; import com.fortify.cli.common.output.transform.IActionCommandResultSupplier; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCJsonNodeOutputCommand; @@ -27,9 +28,9 @@ import picocli.CommandLine.Mixin; import picocli.CommandLine.Option; -@Command(name = OutputHelperMixins.Create.CMD_NAME) +@Command(name = OutputHelperMixins.CreateTemplate.CMD_NAME) @CommandGroup("template") public class SSCIssueTemplateCreateCommand extends AbstractSSCJsonNodeOutputCommand implements IActionCommandResultSupplier { - @Getter @Mixin private OutputHelperMixins.Create outputHelper; + @Getter @Mixin private OutputHelperMixins.CreateTemplate outputHelper; @Option(names={"--name","-n"}, required = true) private String issueTemplateName; @Mixin private CommonOptionMixins.RequiredFile fileMixin; @Option(names={"--description","-d"}, required = false, defaultValue = "") diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateDeleteCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateDeleteCommand.java similarity index 82% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateDeleteCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateDeleteCommand.java index 33fa729884..4d98abe223 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateDeleteCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateDeleteCommand.java @@ -10,15 +10,16 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.issue_template.cli.cmd; +package com.fortify.cli.ssc.issue.cli.cmd; import com.fasterxml.jackson.databind.JsonNode; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; import com.fortify.cli.common.output.transform.IActionCommandResultSupplier; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCJsonNodeOutputCommand; import com.fortify.cli.ssc._common.rest.SSCUrls; -import com.fortify.cli.ssc.issue_template.cli.mixin.SSCIssueTemplateResolverMixin; -import com.fortify.cli.ssc.issue_template.helper.SSCIssueTemplateDescriptor; +import com.fortify.cli.ssc.issue.cli.mixin.SSCIssueTemplateResolverMixin; +import com.fortify.cli.ssc.issue.helper.SSCIssueTemplateDescriptor; import kong.unirest.UnirestInstance; import lombok.Getter; @@ -26,9 +27,9 @@ import picocli.CommandLine.Command; import picocli.CommandLine.Mixin; -@Command(name = OutputHelperMixins.Delete.CMD_NAME) +@Command(name = OutputHelperMixins.DeleteTemplate.CMD_NAME) @CommandGroup("template") public class SSCIssueTemplateDeleteCommand extends AbstractSSCJsonNodeOutputCommand implements IActionCommandResultSupplier { - @Getter @Mixin private OutputHelperMixins.Delete outputHelper; + @Getter @Mixin private OutputHelperMixins.DeleteTemplate outputHelper; @CommandLine.Mixin private SSCIssueTemplateResolverMixin.PositionalParameterSingle issueTemplateResolver; @Override diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateDownloadCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateDownloadCommand.java similarity index 86% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateDownloadCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateDownloadCommand.java index f515f42a0a..36cfb2d684 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateDownloadCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateDownloadCommand.java @@ -10,19 +10,20 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.issue_template.cli.cmd; +package com.fortify.cli.ssc.issue.cli.cmd; import java.io.File; import com.fasterxml.jackson.databind.JsonNode; import com.fortify.cli.common.cli.mixin.CommonOptionMixins; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; import com.fortify.cli.common.output.transform.IActionCommandResultSupplier; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCJsonNodeOutputCommand; import com.fortify.cli.ssc._common.rest.transfer.SSCFileTransferHelper; import com.fortify.cli.ssc._common.rest.transfer.SSCFileTransferHelper.ISSCAddDownloadTokenFunction; -import com.fortify.cli.ssc.issue_template.cli.mixin.SSCIssueTemplateResolverMixin; -import com.fortify.cli.ssc.issue_template.helper.SSCIssueTemplateDescriptor; +import com.fortify.cli.ssc.issue.cli.mixin.SSCIssueTemplateResolverMixin; +import com.fortify.cli.ssc.issue.helper.SSCIssueTemplateDescriptor; import kong.unirest.UnirestInstance; import lombok.Getter; @@ -30,9 +31,9 @@ import picocli.CommandLine.Command; import picocli.CommandLine.Mixin; -@Command(name = OutputHelperMixins.Download.CMD_NAME) +@Command(name = OutputHelperMixins.DownloadTemplate.CMD_NAME) @CommandGroup("template") public class SSCIssueTemplateDownloadCommand extends AbstractSSCJsonNodeOutputCommand implements IActionCommandResultSupplier { - @Getter @Mixin private OutputHelperMixins.Download outputHelper; + @Getter @Mixin private OutputHelperMixins.DownloadTemplate outputHelper; @Mixin private CommonOptionMixins.OptionalFile fileMixin; @CommandLine.Mixin diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateGetCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateGetCommand.java similarity index 81% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateGetCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateGetCommand.java index 1fdcb3604f..b7676d24f3 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateGetCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateGetCommand.java @@ -10,21 +10,22 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.issue_template.cli.cmd; +package com.fortify.cli.ssc.issue.cli.cmd; import com.fasterxml.jackson.databind.JsonNode; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCJsonNodeOutputCommand; -import com.fortify.cli.ssc.issue_template.cli.mixin.SSCIssueTemplateResolverMixin; +import com.fortify.cli.ssc.issue.cli.mixin.SSCIssueTemplateResolverMixin; import kong.unirest.UnirestInstance; import lombok.Getter; import picocli.CommandLine.Command; import picocli.CommandLine.Mixin; -@Command(name = OutputHelperMixins.Get.CMD_NAME) +@Command(name = OutputHelperMixins.GetTemplate.CMD_NAME) @CommandGroup("template") public class SSCIssueTemplateGetCommand extends AbstractSSCJsonNodeOutputCommand { - @Getter @Mixin private OutputHelperMixins.Get outputHelper; + @Getter @Mixin private OutputHelperMixins.GetTemplate outputHelper; @Mixin private SSCIssueTemplateResolverMixin.PositionalParameterSingle issueTemplateResolver; @Override diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateListCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateListCommand.java similarity index 90% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateListCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateListCommand.java index 1fa15c81a1..db32ba93e7 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateListCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateListCommand.java @@ -10,8 +10,9 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.issue_template.cli.cmd; +package com.fortify.cli.ssc.issue.cli.cmd; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; import com.fortify.cli.common.rest.query.IServerSideQueryParamGeneratorSupplier; import com.fortify.cli.common.rest.query.IServerSideQueryParamValueGenerator; @@ -27,9 +28,9 @@ import picocli.CommandLine.Command; import picocli.CommandLine.Mixin; -@Command(name = OutputHelperMixins.List.CMD_NAME) +@Command(name = OutputHelperMixins.ListTemplates.CMD_NAME) @CommandGroup("template") public class SSCIssueTemplateListCommand extends AbstractSSCBaseRequestOutputCommand implements IServerSideQueryParamGeneratorSupplier { - @Getter @Mixin private OutputHelperMixins.List outputHelper; + @Getter @Mixin private OutputHelperMixins.ListTemplates outputHelper; @Mixin private SSCQParamMixin qParamMixin; @Getter private IServerSideQueryParamValueGenerator serverSideQueryParamGenerator = new SSCQParamGenerator() .add("id", SSCQParamValueGenerators::plain) diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateUpdateCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateUpdateCommand.java similarity index 85% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateUpdateCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateUpdateCommand.java index ac78b053d0..4537d33ed8 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateUpdateCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/cmd/SSCIssueTemplateUpdateCommand.java @@ -10,18 +10,19 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.issue_template.cli.cmd; +package com.fortify.cli.ssc.issue.cli.cmd; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.node.ObjectNode; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; import com.fortify.cli.common.output.transform.IActionCommandResultSupplier; import com.fortify.cli.common.util.StringUtils; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCJsonNodeOutputCommand; import com.fortify.cli.ssc._common.rest.SSCUrls; -import com.fortify.cli.ssc.issue_template.cli.mixin.SSCIssueTemplateResolverMixin; -import com.fortify.cli.ssc.issue_template.helper.SSCIssueTemplateDescriptor; -import com.fortify.cli.ssc.issue_template.helper.SSCIssueTemplateHelper; +import com.fortify.cli.ssc.issue.cli.mixin.SSCIssueTemplateResolverMixin; +import com.fortify.cli.ssc.issue.helper.SSCIssueTemplateDescriptor; +import com.fortify.cli.ssc.issue.helper.SSCIssueTemplateHelper; import kong.unirest.UnirestInstance; import lombok.Getter; @@ -29,9 +30,9 @@ import picocli.CommandLine.Mixin; import picocli.CommandLine.Option; -@Command(name = OutputHelperMixins.Update.CMD_NAME) +@Command(name = OutputHelperMixins.UpdateTemplate.CMD_NAME) @CommandGroup("template") public class SSCIssueTemplateUpdateCommand extends AbstractSSCJsonNodeOutputCommand implements IActionCommandResultSupplier { - @Getter @Mixin private OutputHelperMixins.Update outputHelper; + @Getter @Mixin private OutputHelperMixins.UpdateTemplate outputHelper; @Mixin private SSCIssueTemplateResolverMixin.PositionalParameterSingle issueTemplateResolver; @Option(names={"--name","-n"}, required = false) private String name; diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/mixin/SSCIssueTemplateResolverMixin.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/mixin/SSCIssueTemplateResolverMixin.java similarity index 87% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/mixin/SSCIssueTemplateResolverMixin.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/mixin/SSCIssueTemplateResolverMixin.java index a39ca1e86a..43311d0c4c 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/mixin/SSCIssueTemplateResolverMixin.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/cli/mixin/SSCIssueTemplateResolverMixin.java @@ -10,12 +10,12 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.issue_template.cli.mixin; +package com.fortify.cli.ssc.issue.cli.mixin; import com.fortify.cli.common.cli.util.EnvSuffix; import com.fortify.cli.common.util.StringUtils; -import com.fortify.cli.ssc.issue_template.helper.SSCIssueTemplateDescriptor; -import com.fortify.cli.ssc.issue_template.helper.SSCIssueTemplateHelper; +import com.fortify.cli.ssc.issue.helper.SSCIssueTemplateDescriptor; +import com.fortify.cli.ssc.issue.helper.SSCIssueTemplateHelper; import kong.unirest.UnirestInstance; import lombok.Getter; @@ -40,12 +40,12 @@ public SSCIssueTemplateDescriptor getIssueTemplateDescriptorOrDefault(UnirestIns } public static class OptionalOption extends AbstractSSCIssueTemplateResolverMixin { - @Option(names="--issue-template", required = false, descriptionKey = "fcli.ssc.issue-template.resolver.nameOrId") + @Option(names="--issue-template", required = false, descriptionKey = "fcli.ssc.issue.template.resolver.nameOrId") @Getter private String issueTemplateNameOrId; } public static class PositionalParameterSingle extends AbstractSSCIssueTemplateResolverMixin { - @EnvSuffix("ISSUE_TEMPLATE") @Parameters(index = "0", arity = "1", descriptionKey = "fcli.ssc.issue-template.resolver.nameOrId") + @EnvSuffix("ISSUE_TEMPLATE") @Parameters(index = "0", arity = "1", descriptionKey = "fcli.ssc.issue.template.resolver.nameOrId") @Getter private String issueTemplateNameOrId; } } diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueGroupDescriptor.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueGroupDescriptor.java index 82a44388b4..6dff1abddc 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueGroupDescriptor.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueGroupDescriptor.java @@ -12,9 +12,12 @@ *******************************************************************************/ package com.fortify.cli.ssc.issue.helper; -import com.formkiq.graalvm.annotations.*; -import com.fortify.cli.common.json.*; -import lombok.*; +import com.formkiq.graalvm.annotations.Reflectable; +import com.fortify.cli.common.json.JsonNodeHolder; + +import lombok.Data; +import lombok.EqualsAndHashCode; +import lombok.NoArgsConstructor; @Reflectable @NoArgsConstructor @Data @EqualsAndHashCode(callSuper=true) diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueGroupHelper.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueGroupHelper.java index f906ca5df0..544f0b19de 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueGroupHelper.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueGroupHelper.java @@ -12,12 +12,14 @@ *******************************************************************************/ package com.fortify.cli.ssc.issue.helper; +import java.util.HashMap; +import java.util.Map; + import com.fasterxml.jackson.databind.JsonNode; -import com.fortify.cli.common.json.*; -import com.fortify.cli.ssc._common.rest.*; -import kong.unirest.*; +import com.fortify.cli.common.json.JsonHelper; +import com.fortify.cli.ssc._common.rest.SSCUrls; -import java.util.*; +import kong.unirest.UnirestInstance; public final class SSCIssueGroupHelper { private final Map descriptorsByGuid = new HashMap<>(); diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/helper/SSCIssueTemplateDescriptor.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueTemplateDescriptor.java similarity index 96% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/helper/SSCIssueTemplateDescriptor.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueTemplateDescriptor.java index 2fcdefb967..af59e62628 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/helper/SSCIssueTemplateDescriptor.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueTemplateDescriptor.java @@ -10,7 +10,7 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.issue_template.helper; +package com.fortify.cli.ssc.issue.helper; import com.formkiq.graalvm.annotations.Reflectable; import com.fortify.cli.common.json.JsonNodeHolder; diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/helper/SSCIssueTemplateHelper.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueTemplateHelper.java similarity index 98% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/helper/SSCIssueTemplateHelper.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueTemplateHelper.java index db4b631294..e4b3a4b055 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/helper/SSCIssueTemplateHelper.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue/helper/SSCIssueTemplateHelper.java @@ -10,7 +10,7 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.issue_template.helper; +package com.fortify.cli.ssc.issue.helper; import java.util.HashMap; import java.util.Map; diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateCommands.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateCommands.java deleted file mode 100644 index 3b7133200a..0000000000 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/issue_template/cli/cmd/SSCIssueTemplateCommands.java +++ /dev/null @@ -1,31 +0,0 @@ -/******************************************************************************* - * Copyright 2021, 2023 Open Text. - * - * The only warranties for products and services of Open Text - * and its affiliates and licensors ("Open Text") are as may - * be set forth in the express warranty statements accompanying - * such products and services. Nothing herein should be construed - * as constituting an additional warranty. Open Text shall not be - * liable for technical or editorial errors or omissions contained - * herein. The information contained herein is subject to change - * without notice. - *******************************************************************************/ -package com.fortify.cli.ssc.issue_template.cli.cmd; - -import com.fortify.cli.common.cli.cmd.AbstractContainerCommand; - -import picocli.CommandLine.Command; - -@Command( - name = "issue-template", - subcommands = { - SSCIssueTemplateCreateCommand.class, - SSCIssueTemplateDeleteCommand.class, - SSCIssueTemplateDownloadCommand.class, - SSCIssueTemplateGetCommand.class, - SSCIssueTemplateListCommand.class, - SSCIssueTemplateUpdateCommand.class - } -) -public class SSCIssueTemplateCommands extends AbstractContainerCommand { -} diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/performance_indicator/cli/cmd/SSCPerformanceIndicatorCommands.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/performance_indicator/cli/cmd/SSCPerformanceIndicatorCommands.java index 612108ad01..43c8950596 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/performance_indicator/cli/cmd/SSCPerformanceIndicatorCommands.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/performance_indicator/cli/cmd/SSCPerformanceIndicatorCommands.java @@ -13,6 +13,7 @@ package com.fortify.cli.ssc.performance_indicator.cli.cmd; import com.fortify.cli.common.cli.cmd.AbstractContainerCommand; + import picocli.CommandLine.Command; @Command( diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/seed_bundle/cli/cmd/SSCSeedBundleCommands.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/seed_bundle/cli/cmd/SSCSeedBundleCommands.java deleted file mode 100644 index d0c8e9d614..0000000000 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/seed_bundle/cli/cmd/SSCSeedBundleCommands.java +++ /dev/null @@ -1,26 +0,0 @@ -/******************************************************************************* - * Copyright 2021, 2023 Open Text. - * - * The only warranties for products and services of Open Text - * and its affiliates and licensors ("Open Text") are as may - * be set forth in the express warranty statements accompanying - * such products and services. Nothing herein should be construed - * as constituting an additional warranty. Open Text shall not be - * liable for technical or editorial errors or omissions contained - * herein. The information contained herein is subject to change - * without notice. - *******************************************************************************/ -package com.fortify.cli.ssc.seed_bundle.cli.cmd; - -import com.fortify.cli.common.cli.cmd.AbstractContainerCommand; - -import picocli.CommandLine.Command; - -@Command( - name = "seed-bundle", - subcommands = { - SSCSeedBundleUploadCommand.class - } -) -public class SSCSeedBundleCommands extends AbstractContainerCommand { -} diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/activity_feed/cli/cmd/SSCActivityFeedListCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCActivityFeedListCommand.java similarity index 88% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/activity_feed/cli/cmd/SSCActivityFeedListCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCActivityFeedListCommand.java index 53bff73a39..feed22fffc 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/activity_feed/cli/cmd/SSCActivityFeedListCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCActivityFeedListCommand.java @@ -10,15 +10,16 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.activity_feed.cli.cmd; +package com.fortify.cli.ssc.system_state.cli.cmd; import com.fasterxml.jackson.databind.JsonNode; -import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.output.transform.IRecordTransformer; import com.fortify.cli.common.output.transform.fields.RenameFieldsTransformer; import com.fortify.cli.common.rest.query.IServerSideQueryParamGeneratorSupplier; import com.fortify.cli.common.rest.query.IServerSideQueryParamValueGenerator; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCBaseRequestOutputCommand; +import com.fortify.cli.ssc._common.output.cli.mixin.SSCOutputHelperMixins; import com.fortify.cli.ssc._common.rest.SSCUrls; import com.fortify.cli.ssc._common.rest.query.SSCQParamGenerator; import com.fortify.cli.ssc._common.rest.query.SSCQParamValueGenerators; @@ -30,9 +31,9 @@ import picocli.CommandLine.Command; import picocli.CommandLine.Mixin; -@Command(name = OutputHelperMixins.List.CMD_NAME) +@Command(name = SSCOutputHelperMixins.ListActivities.CMD_NAME) @CommandGroup("activity") public class SSCActivityFeedListCommand extends AbstractSSCBaseRequestOutputCommand implements IRecordTransformer, IServerSideQueryParamGeneratorSupplier { - @Getter @Mixin private OutputHelperMixins.List outputHelper; + @Getter @Mixin private SSCOutputHelperMixins.ListActivities outputHelper; @Mixin private SSCQParamMixin qParamMixin; @Getter private IServerSideQueryParamValueGenerator serverSideQueryParamGenerator = new SSCQParamGenerator() .add("userName", SSCQParamValueGenerators::wrapInQuotes) diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/event/cli/cmd/SSCEventListCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCEventListCommand.java similarity index 88% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/event/cli/cmd/SSCEventListCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCEventListCommand.java index 8a330c2528..6dae4e5d46 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/event/cli/cmd/SSCEventListCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCEventListCommand.java @@ -10,15 +10,16 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.event.cli.cmd; +package com.fortify.cli.ssc.system_state.cli.cmd; import com.fasterxml.jackson.databind.JsonNode; -import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.output.transform.IRecordTransformer; import com.fortify.cli.common.output.transform.fields.RenameFieldsTransformer; import com.fortify.cli.common.rest.query.IServerSideQueryParamGeneratorSupplier; import com.fortify.cli.common.rest.query.IServerSideQueryParamValueGenerator; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCBaseRequestOutputCommand; +import com.fortify.cli.ssc._common.output.cli.mixin.SSCOutputHelperMixins; import com.fortify.cli.ssc._common.rest.query.SSCQParamGenerator; import com.fortify.cli.ssc._common.rest.query.SSCQParamValueGenerators; import com.fortify.cli.ssc._common.rest.query.cli.mixin.SSCQParamMixin; @@ -29,9 +30,9 @@ import picocli.CommandLine.Command; import picocli.CommandLine.Mixin; -@Command(name = OutputHelperMixins.List.CMD_NAME) +@Command(name = SSCOutputHelperMixins.ListEvents.CMD_NAME) @CommandGroup("event") public class SSCEventListCommand extends AbstractSSCBaseRequestOutputCommand implements IRecordTransformer, IServerSideQueryParamGeneratorSupplier { - @Getter @Mixin private OutputHelperMixins.List outputHelper; + @Getter @Mixin private SSCOutputHelperMixins.ListEvents outputHelper; @Mixin private SSCQParamMixin qParamMixin; @Getter private IServerSideQueryParamValueGenerator serverSideQueryParamGenerator = new SSCQParamGenerator() .add("userName", SSCQParamValueGenerators::wrapInQuotes) diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobCancelCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobCancelCommand.java similarity index 83% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobCancelCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobCancelCommand.java index ea6668a46b..79d8cfce20 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobCancelCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobCancelCommand.java @@ -10,26 +10,27 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.job.cli.cmd; +package com.fortify.cli.ssc.system_state.cli.cmd; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import com.fasterxml.jackson.databind.node.ObjectNode; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.json.JsonHelper; -import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; import com.fortify.cli.common.output.transform.IActionCommandResultSupplier; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCJsonNodeOutputCommand; +import com.fortify.cli.ssc._common.output.cli.mixin.SSCOutputHelperMixins; import com.fortify.cli.ssc._common.rest.SSCUrls; -import com.fortify.cli.ssc.job.cli.mixin.SSCJobResolverMixin; +import com.fortify.cli.ssc.system_state.cli.mixin.SSCJobResolverMixin; import kong.unirest.UnirestInstance; import lombok.Getter; import picocli.CommandLine.Command; import picocli.CommandLine.Mixin; -@Command(name = OutputHelperMixins.Cancel.CMD_NAME) +@Command(name = SSCOutputHelperMixins.CancelJob.CMD_NAME) @CommandGroup("job") public class SSCJobCancelCommand extends AbstractSSCJsonNodeOutputCommand implements IActionCommandResultSupplier { - @Getter @Mixin private OutputHelperMixins.Cancel outputHelper; + @Getter @Mixin private SSCOutputHelperMixins.CancelJob outputHelper; @Mixin private SSCJobResolverMixin.PositionalParameter jobResolver; @Override diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobGetCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobGetCommand.java similarity index 76% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobGetCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobGetCommand.java index ca1f9140c7..990d51aa2b 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobGetCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobGetCommand.java @@ -10,21 +10,22 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.job.cli.cmd; +package com.fortify.cli.ssc.system_state.cli.cmd; import com.fasterxml.jackson.databind.JsonNode; -import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCJsonNodeOutputCommand; -import com.fortify.cli.ssc.job.cli.mixin.SSCJobResolverMixin; +import com.fortify.cli.ssc._common.output.cli.mixin.SSCOutputHelperMixins; +import com.fortify.cli.ssc.system_state.cli.mixin.SSCJobResolverMixin; import kong.unirest.UnirestInstance; import lombok.Getter; import picocli.CommandLine.Command; import picocli.CommandLine.Mixin; -@Command(name = OutputHelperMixins.Get.CMD_NAME) +@Command(name = SSCOutputHelperMixins.GetJob.CMD_NAME) @CommandGroup("job") public class SSCJobGetCommand extends AbstractSSCJsonNodeOutputCommand { - @Getter @Mixin private OutputHelperMixins.Get outputHelper; + @Getter @Mixin private SSCOutputHelperMixins.GetJob outputHelper; @Mixin private SSCJobResolverMixin.PositionalParameter jobResolver; @Override diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobListCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobListCommand.java similarity index 87% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobListCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobListCommand.java index eab1fcdcad..ff009b0503 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobListCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobListCommand.java @@ -10,12 +10,13 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.job.cli.cmd; +package com.fortify.cli.ssc.system_state.cli.cmd; -import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.rest.query.IServerSideQueryParamGeneratorSupplier; import com.fortify.cli.common.rest.query.IServerSideQueryParamValueGenerator; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCBaseRequestOutputCommand; +import com.fortify.cli.ssc._common.output.cli.mixin.SSCOutputHelperMixins; import com.fortify.cli.ssc._common.rest.SSCUrls; import com.fortify.cli.ssc._common.rest.query.SSCQParamGenerator; import com.fortify.cli.ssc._common.rest.query.SSCQParamValueGenerators; @@ -27,9 +28,9 @@ import picocli.CommandLine.Command; import picocli.CommandLine.Mixin; -@Command(name = OutputHelperMixins.List.CMD_NAME) +@Command(name = SSCOutputHelperMixins.ListJobs.CMD_NAME) @CommandGroup("job") public class SSCJobListCommand extends AbstractSSCBaseRequestOutputCommand implements IServerSideQueryParamGeneratorSupplier { - @Getter @Mixin private OutputHelperMixins.List outputHelper; + @Getter @Mixin private SSCOutputHelperMixins.ListJobs outputHelper; @Mixin private SSCQParamMixin qParamMixin; @Getter private IServerSideQueryParamValueGenerator serverSideQueryParamGenerator = new SSCQParamGenerator() .add("jobClass", SSCQParamValueGenerators::wrapInQuotes) diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobUpdateCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobUpdateCommand.java similarity index 81% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobUpdateCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobUpdateCommand.java index fca0ebfcdf..661bedbae9 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobUpdateCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCJobUpdateCommand.java @@ -10,16 +10,17 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.job.cli.cmd; +package com.fortify.cli.ssc.system_state.cli.cmd; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.node.ObjectNode; -import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.output.transform.IActionCommandResultSupplier; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCJsonNodeOutputCommand; +import com.fortify.cli.ssc._common.output.cli.mixin.SSCOutputHelperMixins; import com.fortify.cli.ssc._common.rest.SSCUrls; -import com.fortify.cli.ssc.job.cli.mixin.SSCJobResolverMixin; -import com.fortify.cli.ssc.job.helper.SSCJobDescriptor; +import com.fortify.cli.ssc.system_state.cli.mixin.SSCJobResolverMixin; +import com.fortify.cli.ssc.system_state.helper.SSCJobDescriptor; import kong.unirest.UnirestInstance; import lombok.Getter; @@ -27,9 +28,9 @@ import picocli.CommandLine.Mixin; import picocli.CommandLine.Option; -@Command(name = OutputHelperMixins.Update.CMD_NAME) +@Command(name = SSCOutputHelperMixins.UpdateJob.CMD_NAME) @CommandGroup("job") public class SSCJobUpdateCommand extends AbstractSSCJsonNodeOutputCommand implements IActionCommandResultSupplier { - @Getter @Mixin private OutputHelperMixins.Update outputHelper; + @Getter @Mixin private SSCOutputHelperMixins.UpdateJob outputHelper; @Mixin private SSCJobResolverMixin.PositionalParameter jobResolver; @Option(names="--priority", required = true) Integer priority; diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/seed_bundle/cli/cmd/SSCSeedBundleUploadCommand.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCSeedBundleUploadCommand.java similarity index 84% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/seed_bundle/cli/cmd/SSCSeedBundleUploadCommand.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCSeedBundleUploadCommand.java index f11490690e..e5ab6c4af1 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/seed_bundle/cli/cmd/SSCSeedBundleUploadCommand.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCSeedBundleUploadCommand.java @@ -10,14 +10,15 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.seed_bundle.cli.cmd; +package com.fortify.cli.ssc.system_state.cli.cmd; import com.fasterxml.jackson.databind.JsonNode; import com.fasterxml.jackson.databind.ObjectMapper; import com.fortify.cli.common.cli.mixin.CommonOptionMixins; -import com.fortify.cli.common.output.cli.mixin.OutputHelperMixins; +import com.fortify.cli.common.cli.util.CommandGroup; import com.fortify.cli.common.output.transform.IActionCommandResultSupplier; import com.fortify.cli.ssc._common.output.cli.cmd.AbstractSSCJsonNodeOutputCommand; +import com.fortify.cli.ssc._common.output.cli.mixin.SSCOutputHelperMixins; import com.fortify.cli.ssc._common.rest.SSCUrls; import kong.unirest.UnirestInstance; @@ -25,9 +26,9 @@ import picocli.CommandLine.Command; import picocli.CommandLine.Mixin; -@Command(name = OutputHelperMixins.Upload.CMD_NAME) +@Command(name = SSCOutputHelperMixins.UploadSeedBundle.CMD_NAME) @CommandGroup("seed-bundle") public class SSCSeedBundleUploadCommand extends AbstractSSCJsonNodeOutputCommand implements IActionCommandResultSupplier { - @Getter @Mixin private OutputHelperMixins.Upload outputHelper; + @Getter @Mixin private SSCOutputHelperMixins.UploadSeedBundle outputHelper; @Mixin private CommonOptionMixins.RequiredFile fileMixin; @Override diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobCommands.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCSystemStateCommands.java similarity index 72% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobCommands.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCSystemStateCommands.java index a265d3f26c..ec87c0d0d1 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/cmd/SSCJobCommands.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/cmd/SSCSystemStateCommands.java @@ -10,20 +10,24 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.job.cli.cmd; +package com.fortify.cli.ssc.system_state.cli.cmd; import com.fortify.cli.common.cli.cmd.AbstractContainerCommand; import picocli.CommandLine.Command; @Command( - name = "job", + name = "system-state", + aliases="state", subcommands = { + SSCActivityFeedListCommand.class, + SSCEventListCommand.class, SSCJobCancelCommand.class, SSCJobGetCommand.class, SSCJobListCommand.class, - SSCJobUpdateCommand.class + SSCJobUpdateCommand.class, + SSCSeedBundleUploadCommand.class } ) -public class SSCJobCommands extends AbstractContainerCommand { +public class SSCSystemStateCommands extends AbstractContainerCommand { } diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/mixin/SSCJobResolverMixin.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/mixin/SSCJobResolverMixin.java similarity index 86% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/mixin/SSCJobResolverMixin.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/mixin/SSCJobResolverMixin.java index b5d026019b..5eb38039de 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/cli/mixin/SSCJobResolverMixin.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/cli/mixin/SSCJobResolverMixin.java @@ -10,11 +10,11 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.job.cli.mixin; +package com.fortify.cli.ssc.system_state.cli.mixin; import com.fortify.cli.common.cli.util.EnvSuffix; -import com.fortify.cli.ssc.job.helper.SSCJobDescriptor; -import com.fortify.cli.ssc.job.helper.SSCJobHelper; +import com.fortify.cli.ssc.system_state.helper.SSCJobDescriptor; +import com.fortify.cli.ssc.system_state.helper.SSCJobHelper; import kong.unirest.UnirestInstance; import lombok.Getter; @@ -35,12 +35,12 @@ public String getJobName(UnirestInstance unirest) { } public static class RequiredOption extends AbstractSSCJobResolverMixin { - @Option(names="--job", required = true, descriptionKey = "fcli.ssc.job.resolver.name") + @Option(names="--job", required = true, descriptionKey = "fcli.ssc.system-state.job.resolver.name") @Getter private String jobName; } public static class PositionalParameter extends AbstractSSCJobResolverMixin { - @EnvSuffix("JOB") @Parameters(index = "0", arity = "1", descriptionKey = "fcli.ssc.job.resolver.name") + @EnvSuffix("JOB") @Parameters(index = "0", arity = "1", descriptionKey = "fcli.ssc.system-state.job.resolver.name") @Getter private String jobName; } } diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/helper/SSCJobDescriptor.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/helper/SSCJobDescriptor.java similarity index 95% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/helper/SSCJobDescriptor.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/helper/SSCJobDescriptor.java index 7cb09719af..5e1ef2eef1 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/helper/SSCJobDescriptor.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/helper/SSCJobDescriptor.java @@ -10,7 +10,7 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.job.helper; +package com.fortify.cli.ssc.system_state.helper; import com.formkiq.graalvm.annotations.Reflectable; import com.fortify.cli.common.json.JsonNodeHolder; diff --git a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/helper/SSCJobHelper.java b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/helper/SSCJobHelper.java similarity index 96% rename from fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/helper/SSCJobHelper.java rename to fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/helper/SSCJobHelper.java index 0d74731e98..86f0f32f8f 100644 --- a/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/job/helper/SSCJobHelper.java +++ b/fcli-core/fcli-ssc/src/main/java/com/fortify/cli/ssc/system_state/helper/SSCJobHelper.java @@ -10,7 +10,7 @@ * herein. The information contained herein is subject to change * without notice. *******************************************************************************/ -package com.fortify.cli.ssc.job.helper; +package com.fortify.cli.ssc.system_state.helper; import com.fasterxml.jackson.databind.JsonNode; import com.fortify.cli.common.json.JsonHelper; diff --git a/fcli-core/fcli-ssc/src/main/resources/com/fortify/cli/ssc/i18n/SSCMessages.properties b/fcli-core/fcli-ssc/src/main/resources/com/fortify/cli/ssc/i18n/SSCMessages.properties index 8161c329f3..3430dfdd2f 100644 --- a/fcli-core/fcli-ssc/src/main/resources/com/fortify/cli/ssc/i18n/SSCMessages.properties +++ b/fcli-core/fcli-ssc/src/main/resources/com/fortify/cli/ssc/i18n/SSCMessages.properties @@ -127,11 +127,6 @@ fcli.ssc.rest.call.transform = This option allows for performing custom transfor data based on a Spring Expression Language (SpEL) expression. For example, this allows for retrieving \ data from sub-properties, or using project selection/projection. Note that the expression operates on \ the raw response, as if --no-transform was specified before evaluating the expression. - - -# fcli ssc activity-feed -fcli.ssc.activity-feed.usage.header = Manage SSC activity feed. -fcli.ssc.activity-feed.list.usage.header = List activity feed entries. # fcli ssc alert fcli.ssc.alert.usage.header = Manage SSC alerts & definitions. @@ -265,12 +260,8 @@ fcli.ssc.attribute.get-definition.usage.header = Get attribute definition detail fcli.ssc.attribute.list-definitions.usage.header = List attribute definitions. fcli.ssc.attribute-definition.resolver.nameOrId = Attribute definition name or id. -# fcli ssc event -fcli.ssc.event.usage.header = Manage SSC system events. -fcli.ssc.event.list.usage.header = List system events. - # fcli ssc issue -fcli.ssc.issue.usage.header = Manage SSC issues (vulnerabilities) and related entities like filter sets and issue groups. +fcli.ssc.issue.usage.header = Manage SSC issues (vulnerabilities) and related entities like issue templates, filters and groups. fcli.ssc.issue.count.usage.header = Count application version vulnerabilities by grouping. fcli.ssc.issue.count.by = Vulnerability grouping type. See 'fcli ssc issue list-groups' for \ allowed values. Default value: ${DEFAULT-VALUE}. @@ -285,34 +276,22 @@ fcli.ssc.issue.filterset.resolver.titleOrId = Filter set title (name) or id. fcli.ssc.issue.get-group.usage.header = Get issue group details. fcli.ssc.issue.list-groups.usage.header = List application version issue groups. fcli.ssc.issue.group.resolver.displayNameOrId = Issue group display name or id. - -# fcli ssc issue-template -fcli.ssc.issue-template.usage.header = Manage SSC issue templates. -fcli.ssc.issue-template.create.usage.header = Create/upload an issue template. -fcli.ssc.issue-template.create.issue-template-file = File containing the issue template definition. -fcli.ssc.issue-template.create.description = Issue template description. -fcli.ssc.issue-template.create.file = Issue template file path. -fcli.ssc.issue-template.create.name = Issue template name. -fcli.ssc.issue-template.create.set-as-default = Set this issue template as the default issue template. -fcli.ssc.issue-template.delete.usage.header = Delete an issue template. -fcli.ssc.issue-template.download.usage.header = Download an issue template. -fcli.ssc.issue-template.download.file = Optional issue template file path. -fcli.ssc.issue-template.get.usage.header = Get issue template details. -fcli.ssc.issue-template.list.usage.header = List issue templates. -fcli.ssc.issue-template.update.usage.header = Update an issue template. -fcli.ssc.issue-template.update.name = Update issue template name. -fcli.ssc.issue-template.update.description = Update issue template description. -fcli.ssc.issue-template.update.set-as-default = Set this issue template as the default issue template. -fcli.ssc.issue-template.resolver.nameOrId = Issue template name or id. - -# fcli ssc job -fcli.ssc.job.usage.header = Manage SSC background jobs. -fcli.ssc.job.cancel.usage.header = Cancel a job. -fcli.ssc.job.get.usage.header = Get job details. -fcli.ssc.job.list.usage.header = List jobs. -fcli.ssc.job.update.usage.header = Update job priority. -fcli.ssc.job.update.priority = New priority for this job. -fcli.ssc.job.resolver.name = Job name. +fcli.ssc.issue.create-template.usage.header = Create/upload an issue template. +fcli.ssc.issue.create-template.issue-template-file = File containing the issue template definition. +fcli.ssc.issue.create-template.description = Issue template description. +fcli.ssc.issue.create-template.file = Issue template file path. +fcli.ssc.issue.create-template.name = Issue template name. +fcli.ssc.issue.create-template.set-as-default = Set this issue template as the default issue template. +fcli.ssc.issue.delete-template.usage.header = Delete an issue template. +fcli.ssc.issue.download-template.usage.header = Download an issue template. +fcli.ssc.issue.download-template.file = Optional issue template file path. +fcli.ssc.issue.get-template.usage.header = Get issue template details. +fcli.ssc.issue.list-templates.usage.header = List issue templates. +fcli.ssc.issue.update-template.usage.header = Update an issue template. +fcli.ssc.issue.update-template.name = Update issue template name. +fcli.ssc.issue.update-template.description = Update issue template description. +fcli.ssc.issue.update-template.set-as-default = Set this issue template as the default issue template. +fcli.ssc.issue.template.resolver.nameOrId = Issue template name or id. # fcli ssc performance-indicator fcli.ssc.performance-indicator.usage.header = (PREVIEW) Manage SSC application version performance indicators. @@ -372,13 +351,21 @@ fcli.ssc.role.get-permission.usage.header = Get role permission details. fcli.ssc.role.list-permissions.usage.header = List role permissions. fcli.ssc.role.permission.resolver.nameOrId = Role permission name or id. -# fcli ssc seed-bundle -fcli.ssc.seed-bundle.usage.header = Manage SSC seed bundles. -fcli.ssc.seed-bundle.upload.usage.header = Upload a seed bundle. -fcli.ssc.seed-bundle.upload.file = Seed bundle to upload. +# fcli ssc system-state +fcli.ssc.system-state.usage.header = View & manage SSC system state (logs, jobs, ...) +fcli.ssc.system-state.list-activities.usage.header = List activity feed entries. +fcli.ssc.system-state.list-events.usage.header = List system events. +fcli.ssc.system-state.cancel-job.usage.header = Cancel a job. +fcli.ssc.system-state.get-job.usage.header = Get job details. +fcli.ssc.system-state.list-jobs.usage.header = List jobs. +fcli.ssc.system-state.update-job.usage.header = Update job priority. +fcli.ssc.system-state.update-job.priority = New priority for this job. +fcli.ssc.system-state.job.resolver.name = Job name. +fcli.ssc.system-state.upload-seed-bundle.usage.header = Upload a seed bundle. +fcli.ssc.system-state.upload-seed-bundle.file = Seed bundle to upload. # fcli ssc token -fcli.ssc.token.usage.header = Manage SSC user tokens. +fcli.ssc.token.usage.header = Manage SSC user tokens & definitions. fcli.ssc.token.create.usage.header = Create a token. fcli.ssc.token.create.expire-in = Expire token after the given time period, which is specified as \ 30m (30 minutes), 2h (2 hours), 1d (1 day). @@ -422,7 +409,6 @@ fcli.ssc.user.resolver.spec = User or LDAP group, accepting user id, entity name fcli.env.default.prefix=FCLI_DEFAULT # Table output columns configuration -fcli.ssc.activity-feed.output.table.options = eventDate,userName,eventType,detailedNote,applicationVersionId,entityId fcli.ssc.alert.output.table.options = id,triggeredDate,alertDefinitionName,userName,alertMessage,applicationAndVersionLabel fcli.ssc.alert.definition.output.table.options = id,name,createdBy,recipientType,monitoredEntityType,triggerDescriptionName fcli.ssc.app.output.table.options = id,name,description @@ -433,13 +419,11 @@ fcli.ssc.artifact.output.table.options = id,scanTypes,lastScanDate,uploadDate,st fcli.ssc.appversion-user.output.table.options = id,entityName,displayName,type,email,isLdap fcli.ssc.attribute.output.table.options = id,category,guid,name,valueString fcli.ssc.attribute.definition.output.table.options = id,category,guid,name,type,required -fcli.ssc.event.output.table.options = eventDate,userName,eventType,detailedNote,applicationVersionId,entityId fcli.ssc.issue.count.output.table.options = cleanName,totalCount,auditedCount fcli.ssc.issue.filter-set.output.table.options = guid,title,defaultFilterSet,description fcli.ssc.issue.group.output.table.options = guid,displayName,entityType,description fcli.ssc.issue.filter.output.table.options = entityType,friendlyFilter,technicalFilter -fcli.ssc.issue-template.output.table.options = id,name,inUse,defaultTemplate,publishVersion,originalFileName,description -fcli.ssc.job.output.table.options = jobName,jobGroup,jobClass,state,cancellable,priority,createTime,startTime,finishTime +fcli.ssc.issue.template.output.table.options = id,name,inUse,defaultTemplate,publishVersion,originalFileName,description fcli.ssc.performance-indicator.output.table.options = id,name,timestamp,valueString fcli.ssc.plugin.output.table.options = id,pluginId,pluginType,pluginName,pluginVersion,pluginState fcli.ssc.report.template.output.table.options = id,name,type,templateDocId,inUse @@ -448,7 +432,10 @@ fcli.ssc.report.template.create-template-config.output.table.options = path fcli.ssc.role.output.table.options = id,name,builtIn,allApplicationRole,description fcli.ssc.role.permission.output.table.options = id,name,description fcli.ssc.session.output.table.options = name,type,url,created,expires,expired -fcli.ssc.seed-bundle.output.table.options = responseCode +fcli.ssc.system-state.activity.output.table.options = eventDate,userName,eventType,detailedNote,applicationVersionId,entityId +fcli.ssc.system-state.event.output.table.options = eventDate,userName,eventType,detailedNote,applicationVersionId,entityId +fcli.ssc.system-state.job.output.table.options = jobName,jobGroup,jobClass,state,cancellable,priority,createTime,startTime,finishTime +fcli.ssc.system-state.seed-bundle.output.table.options = responseCode fcli.ssc.token.output.table.options = id,username,type,creationDate,terminalDate,timeRemaining,description fcli.ssc.token.create.output.table.options = id,username,type,restToken,applicationToken,terminalDate,timeRemaining,description fcli.ssc.token.revoke.output.table.options = responseCode diff --git a/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCActivityFeedSpec.groovy b/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCActivityFeedSpec.groovy index 033b826dac..7fb6880471 100644 --- a/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCActivityFeedSpec.groovy +++ b/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCActivityFeedSpec.groovy @@ -30,7 +30,7 @@ class SSCActivityFeedSpec extends FcliBaseSpec { @Shared @AutoCleanup SSCAppVersionSupplier versionSupplier = new SSCAppVersionSupplier() def "list"() { - def args = "ssc activity-feed list" + def args = "ssc state list-activities" when: def result = Fcli.run(args) then: diff --git a/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCEventSpec.groovy b/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCEventSpec.groovy index 1ba48d245f..7241c88225 100644 --- a/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCEventSpec.groovy +++ b/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCEventSpec.groovy @@ -30,7 +30,7 @@ class SSCEventSpec extends FcliBaseSpec { @Shared @AutoCleanup SSCAppVersionSupplier versionSupplier = new SSCAppVersionSupplier() def "list"() { - def args = "ssc event list" + def args = "ssc state list-events" when: def result = Fcli.run(args) then: diff --git a/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCJobSpec.groovy b/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCJobSpec.groovy index 34515215b1..57cd0b9091 100644 --- a/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCJobSpec.groovy +++ b/fcli-other/fcli-functional-test/src/ftest/groovy/com/fortify/cli/ftest/ssc/SSCJobSpec.groovy @@ -92,7 +92,7 @@ class SSCJobSpec extends FcliBaseSpec { } */ def "list"() { - def args = "ssc job list --store jobs" + def args = "ssc state list-jobs --store jobs" when: def result = Fcli.run(args) then: @@ -106,7 +106,7 @@ class SSCJobSpec extends FcliBaseSpec { def "get.byName"() { Thread.sleep(1000) - def args = "ssc job get ::jobs::get(0).jobName" + def args = "ssc state get-job ::jobs::get(0).jobName" when: def result = Fcli.run(args) then: