From dev-return-23009-apmail-geode-dev-archive=geode.apache.org@geode.apache.org Wed May 31 17:20:18 2017 Return-Path: X-Original-To: apmail-geode-dev-archive@minotaur.apache.org Delivered-To: apmail-geode-dev-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E086817D28 for ; Wed, 31 May 2017 17:20:17 +0000 (UTC) Received: (qmail 81308 invoked by uid 500); 31 May 2017 17:20:17 -0000 Delivered-To: apmail-geode-dev-archive@geode.apache.org Received: (qmail 81254 invoked by uid 500); 31 May 2017 17:20:17 -0000 Mailing-List: contact dev-help@geode.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@geode.apache.org Delivered-To: mailing list dev@geode.apache.org Received: (qmail 81243 invoked by uid 99); 31 May 2017 17:20:17 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 31 May 2017 17:20:17 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 4AB0DDFC8B; Wed, 31 May 2017 17:20:17 +0000 (UTC) From: pdxrunner To: dev@geode.apache.org Reply-To: dev@geode.apache.org References: In-Reply-To: Subject: [GitHub] geode pull request #549: GEODE-2203: gfsh status locator/server - Command no... Content-Type: text/plain Message-Id: <20170531172017.4AB0DDFC8B@git1-us-west.apache.org> Date: Wed, 31 May 2017 17:20:17 +0000 (UTC) Github user pdxrunner commented on a diff in the pull request: https://github.com/apache/geode/pull/549#discussion_r119419356 --- Diff: geode-core/src/main/java/org/apache/geode/management/internal/cli/commands/LauncherLifecycleCommands.java --- @@ -771,11 +771,19 @@ public Result statusLocator( CliStrings.STATUS_SERVICE__GFSH_NOT_CONNECTED_ERROR_MESSAGE, LOCATOR_TERM_NAME)); } } else { - final LocatorLauncher locatorLauncher = - new LocatorLauncher.Builder().setCommand(LocatorLauncher.Command.STATUS) - .setBindAddress(locatorHost).setDebug(isDebugging()).setPid(pid) - .setPort(locatorPort).setWorkingDirectory(workingDirectory).build(); - + final LocatorLauncher locatorLauncher; + + if ((locatorHost == null) && (locatorPort == null) && (workingDirectory == null) + && (pid == null)) { + return ResultBuilder.createShellClientErrorResult( + String.format(CliStrings.STATUS_LOCATOR__NO_LOCATOR_SPECIFIED_ERROR_MESSAGE, + getLocatorId(locatorHost, locatorPort), + StringUtils.defaultIfBlank(workingDirectory, SystemUtils.CURRENT_DIRECTORY))); --- End diff -- I thought that the simplification of this argument (don't need the defaultIfBlank call) was in a previous commit, but it seems to have been reverted in your latest commit. --- If your project is set up for it, you can reply to this email and have your reply appear on GitHub as well. If your project does not have this feature enabled and wishes so, or if the feature is enabled but not working, please contact infrastructure at infrastructure@apache.org or file a JIRA ticket with INFRA. ---