public StackId getStackId() {
    return stackId;
  }
Gets the stack to use for generating stack-associated values for a
command. In some cases the cluster's stack is not the correct one to use,
such as when distributing a repository.

@return the stack to use when generating
        stack-specific content for the command.
ambari-server/src/main/java/org/apache/ambari/server/controller/ActionExecutionContext.java