@Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }

    ExecutionCommandWrapper wrapper = (ExecutionCommandWrapper) o;

    if (executionCommand != null && wrapper.executionCommand != null) {
      return executionCommand.equals(wrapper.executionCommand);
    } else {
      return getJson().equals(wrapper.getJson());
    }
  }
Gets the type of command by deserializing the JSON and invoking
{@link ExecutionCommand#getCommandType()}.

@return
ambari-server/src/main/java/org/apache/ambari/server/actionmanager/ExecutionCommandWrapper.java