在分析组中添加和删除分析组件

您正在查看 Apigee Edge 文档。
前往 Apigee X 文档
信息

在 Edge for Private Cloud 安装中,您可能需要从现有分析组中移除 Postgres 和 Qpid 服务器,或者将它们添加到分析组中。 本文档介绍了如何在现有 Edge 安装中添加和移除 Postgres 和 Qpid 服务器,包括单 Postgres 安装和主备 Postgres 安装。

如需了解详情,请参阅为 Postgres 设置主备复制

前提条件

能够使用系统管理员凭据进行管理服务器 API 调用。

将现有 Postgres 服务器添加到分析组

添加 Postgres 服务器组件的流程取决于 Postgres 是作为没有复制功能的单个服务器安装的,还是作为启用了主备复制功能的两个服务器安装的。

场景 1:一个 Postgres 服务器,无 Postgres 复制

  1. 确定分析组和消费群组的名称。

    默认情况下,分析组的名称为 axgroup-001,而消费组的名称为 consumer-group-001。在区域的静默配置文件中,您可以使用 AXGROUP 属性设置分析组的名称。

    如果您不确定分析组和消费群组的名称,请使用以下命令显示它们:

    curl -u adminEmail:pword "http://ms-IP:8080/v1/analytics/groups/ax"

    此调用会返回包含分析组名称的响应:

    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ]
      …

    在此示例中,分析组名称为 axgroup-001.

  2. 使用以下 API 确定 postgres-server 组件的 UUID:
    curl http://pg-IP:8084/v1/servers/self

    在以下 API 调用中,将 axgoupnameUUID 替换为上文确定的分析组名称和 UUID。

  3. 使用以下 API 调用将 Postgres 服务器 UUID 添加到 postgres-server 元素:
    curl -v -u adminEmail:pword -X POST -H 'Content-Type: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/servers?uuid=UUID&type=postgres-server&force=true"

    调用和输出示例:

    curl -v -u adminEmail:pword -X POST -H 'Content-Type: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/servers?uuid=8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77&type=postgres-server&force=true"
    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
        "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07"],
        "postgres-server" : ["8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77"]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07"],
        "datastores" : [ ],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }
  4. 使用以下 API 将 Postgres 服务器 UUID 添加到消费群组:
    curl -v -u adminEmail:pword -X POST -H 'Content-Type: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/consumer-groups/consumer-group-001/datastores?uuid=UUID"

    调用和输出示例:

    curl -v -u adminEmail:pword -X POST -H 'Content-Type: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/consumer-groups/consumer-group-001/datastores?uuid=8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77"
    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
        "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07"],
        "postgres-server" : ["8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77"]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07"],
        "datastores" : ["8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77"],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }
  5. 重启所有节点上的所有 edge-postgres-serveredge-qpid-server 组件,以确保这些组件能够获取相应更改:
    /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server restart
    /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server wait_for_ready
    /opt/apigee/apigee-service/bin/apigee-service edge-postgres-server restart
    /opt/apigee/apigee-service/bin/apigee-service edge-postgres-server wait_for_ready

场景 2:两个具有主备复制功能的 Postgres 服务器

  1. 确定分析群组和消费群组的名称。

    默认情况下,分析组的名称为 axgroup-001,而消费组的名称为 consumer-group-001。在区域的静默配置文件中,您可以使用 AXGROUP 属性设置分析组的名称。

    如果您不确定分析组和消费群组的名称,请使用以下命令显示它们:

    curl -u adminEmail:pword "http://ms-IP:8080/v1/analytics/groups/ax"

    此调用会返回包含已定义的分析群组名称的响应:

    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ]
      …

    在此示例中,分析组名称为 axgroup-001.

  2. 使用以下 API 调用查找每个主 postgres-server 组件和备用 postgres-server 组件的 UUID:
    curl http://pg-IP:8084/v1/servers/self

    在以下 API 调用中,您需要将 axgoupname 替换为 axgroup-001,并且需要在主服务器上使用在第 2 步中获得的 UUID 来替换 masteruuid,还需要使用在第 2 步中为备用服务器返回的 UUID 来替换 slaveuuid

  3. 使用以下 API 将 Postgres 服务器 UUID 添加到 postgres-server 元素:
    curl -v -u adminEmail:pword -X POST -H 'Content-Type: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/servers?uuid=masteruuid,slaveuuid&type=postgres-server&force=true"

    调用和输出示例:

    curl -v -u adminEmail:pword -X POST -H 'Content-Type: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/servers?uuid=8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77,731c8c43-8c35-4b58-ad1a-f572b69c5f0&type=postgres-server&force=true"
    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
            "qpid-server" : ["54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
            "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0"]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
        "datastores" : [],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }
  4. 使用以下 API 将 Postgres 服务器 UUID 添加到消费群组:
    curl -v -u adminEmail:pword -X POST -H -H 'Content-Type: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/consumer-groups/consumer-group-001/datastores?uuid=masteruuid,slaveuuid"

    调用和输出示例:

    curl -v -u adminEmail:pword -X POST -H 'Content-Type: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/consumer-groups/consumer-group-001/datastores?uuid=8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77,731c8c43-8c35-4b58-ad1a-f572b69c5f0"
    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
            "qpid-server" : ["54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
            "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0"]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
        "datastores" : ["8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0"],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }
  5. 重启所有节点上的所有 edge-postgres-serveredge-qpid-server 组件,以确保这些组件能够获取相应更改:
    /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server restart
    /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server wait_for_ready
    /opt/apigee/apigee-service/bin/apigee-service edge-postgres-server restart
    /opt/apigee/apigee-service/bin/apigee-service edge-postgres-server wait_for_ready

将现有 Qpid 服务器添加到分析组

  1. 使用以下 API 查找分析组名称:
    curl -u adminEmail:pword "http://ms-IP:8080/v1/analytics/groups/ax"

    此命令应返回包含分析组和范围名称的响应:

    [  {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ]
      …

    在此示例中,分析组名称为 axgroup-001.

  2. 使用以下 API 调用来确定要添加到分析组的每个 Qpid 服务器组件的 UUID:
    curl http://qp-IP:8083/v1/servers/self
  3. 使用以下 API 调用将单个 Qpid 服务器 UUID 添加到 qpid-server 元素(根据需要重复添加任意数量的 UUID):
    curl -v -u adminEmail:pword -X POST -H 'Content-Type: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/servers?uuid=qpiduuid&type=qpid-server"

    调用和输出示例:

    curl -v -u adminEmail:pword -X POST -H 'Accept: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/servers?uuid=94c96375-1ca7-412d-9eee-80fda94f6e0&type=qpid-server"
    [  {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
            "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
            "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0"]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
        "datastores" : ["8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f57 ],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }
  4. 使用以下 API 调用将单个 Qpid 服务器 UUID 添加到消费群组的 consumers 元素(根据需要重复添加任意数量的 UUID):
    curl -v -u adminEmail:pword -X POST -H 'Content-Type: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/consumer-groups/consumer-group-001/consumers?uuid=qpiduuid" 

    调用和输出示例:

    curl -v -u adminEmail:pword -X POST -H 'Accept: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001//consumer-groups/consumer-group-001/consumers?uuid=94c96375-1ca7-412d-9eee-80fda94f6e0"
    [  {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
            "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
            "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0"]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07","54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
        "datastores" : ["8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f57 ],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }
  5. 重启所有节点上的所有 edge-qpid-server 组件,以确保这些组件能够获取相应更改:
    /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server restart
    /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server wait_for_ready

从分析组中移除 Postgres 服务器

移除 Postgres 服务器的流程取决于是否已启用 Postgres 复制。

场景 1:一个 Postgres 服务器,无复制

  1. 确定分析群组和消费群组的名称。

    默认情况下,分析组的名称为 axgroup-001,而消费组的名称为 consumer-group-001。在区域的静默配置文件中,您可以使用 AXGROUP 属性设置分析组的名称。

    如果您不确定分析组和消费群组的名称,请使用以下命令显示它们:

    curl -u adminEmail:pword "http://ms-IP:8080/v1/analytics/groups/ax"

    这应该会返回如下所示的响应:

    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
        "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07" ],
        "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77"]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07" ],
        "datastores" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77" ],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }

    在此示例中,分析组名称为 axgroup-001,消费者组名称为 consumer-group-001postgres-server UUID 为 8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77。请注意,此 ID 与 consumer-groups 下的 postgres-serverdatastores 元素相关联。

    使用以下步骤中获得的分析组名称、消费群组名称和 UUID。

  2. 使用以下 API 调用从使用方群组的 datastores 元素中移除 postgres-server UUID:
    curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/consumer-groups/consumergroupname/datastores/UUID"

    调用和输出示例:

    curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/consumer-groups/consumer-group-001/datastores/8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77"
    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
        "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07" ],
        "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77"]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07" ],
        "datastores" : [ ],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }
  3. 使用以下 API 从 postgres-server 元素中移除 postgres-server UUID:
    curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/servers?uuid=UUID&type=postgres-server"

    调用和输出示例:

    curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/servers?uuid=8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77&type=postgres-server"
    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
        "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07" ],
        "postgres-server" : [ ]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07" ],
        "datastores" : [ ],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }
  4. 根据您是替换还是删除 Postgres 服务器,执行以下操作:
    • 如果您要替换 Postgres 服务器,请参阅添加 Postgres 服务器,了解添加 Postgres 服务器的步骤。
    • 如果您要删除 Postgres 服务器,请在所有节点上重启所有 edge-postgres-serveredge-qpid-server 组件,以确保这些组件通过运行以下命令来获取相应更改:
      /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server restart
      /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server wait_for_ready
      /opt/apigee/apigee-service/bin/apigee-service edge-postgres-server restart
      /opt/apigee/apigee-service/bin/apigee-service edge-postgres-server wait_for_ready

场景 2:两个具有主备复制功能的 Postgres 服务器

  1. 使用以下 API 查找当前注册的分析组名称和 Postgres 服务器 UUID:

    curl -u adminEmail:pword "http://ms-IP:8080/v1/analytics/groups/ax"

    此调用会返回如下所示的响应:

    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
            "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
            "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0"]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
        "datastores" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0" ],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }

    在此示例中,分析组名称为 axgroup-001postgres-server UUID 为 8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77731c8c43-8c35-4b58-ad1a-f572b69c5f0。请注意,postgres-serverdatastores 元素具有相同的值。

    在后续步骤中,使用在此步骤中获得的分析组名称、消费群组名称和 UUID。

  2. 使用以下 API 从消费者组的 datastores 元素中移除 postgres-server UUID(请注意,在 API 中,主 UUID 和从 UUID 以英文逗号分隔,但在上述分析组调用的输出中,它们将以英文冒号分隔):
    curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/consumer-groups/consumergroupname/datastores/masteruuid,slaveuuid"

    调用和输出示例:

    curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/consumer-groups/consumer-group-001/datastores/8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77,731c8c43-8c35-4b58-ad1a-f572b69c5f0"
    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
            "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
            "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0"]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
        "datastores" : [ ],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }
  3. 使用以下 API 从 postgres-server 元素中移除 postgres-server UUID:
    curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/servers?uuid=masteruuid,slaveuuid&type=postgres-server"

    调用和输出示例:

    curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/servers?uuid=8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77,731c8c43-8c35-4b58-ad1a-f572b69c5f0&type=postgres-server"
    [ {
      "name" : "axgroup-001",
      "properties" : {
      },
      "scopes" : [ "example~prod", "example~test" ],
      "uuids" : {
        "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
        "postgres-server" : [ ]
      },
      "consumer-groups" : [ {
        "name" : "consumer-group-001",
        "consumers" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
        "datastores" : [ ],
        "properties" : {
        }
      } ],
      "data-processors" : {
      }
  4. 根据您是替换还是删除 Postgres 服务器,执行以下操作:
    • 如果您要替换 Postgres 服务器,请参阅添加 Postgres 服务器,了解添加 Postgres 服务器的步骤。
    • 如果您要删除 Postgres 服务器,请在所有节点上重启所有 edge-postgres-serveredge-qpid-server 组件,以确保这些组件通过运行以下命令来获取相应更改:
      /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server restart
      /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server wait_for_ready
      /opt/apigee/apigee-service/bin/apigee-service edge-postgres-server restart
      /opt/apigee/apigee-service/bin/apigee-service edge-postgres-server wait_for_ready

    从分析组中移除 Qpid 服务器

    1. 使用以下 API 查找当前已注册的 Qpid 服务器 UUID:
      curl -u adminEmail:pword "http://ms-IP:8080/v1/analytics/groups/ax"
      此命令应返回以下格式的响应:
      [  {
        "name" : "axgroup-001",
        "properties" : {
        },
        "scopes" : [ "example~prod", "example~test" ],
        "uuids" : {
              "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
              "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0"]
        },
        "consumer-groups" : [ {
          "name" : "consumer-group-001",
          "consumers" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
          "datastores" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0" ],
          "properties" : {
          }
        } ],
        "data-processors" : {
        }

      在此示例中,分析组名称为 axgroup-001,Qpid 服务器 UUID 为 94c96375-1ca7-412d-9eee-80fda94f6e054a96375-33a7-4fba-6bfa-80fda94f6e07。 请注意,qpid-serverconsumers 元素具有相同的值。

      在后续步骤中,使用在此步骤中获得的分析组名称、消费群组名称和 UUID。

    2. 使用以下 API 调用从消费者组的 consumers 元素中移除单个 qpid-server UUID(根据需要重复多次):
      curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/consumer-groups/consumer-group-001/consumers/qpiduuid"

      调用和输出示例:

      curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/consumer-groups/consumer-group-001/consumers/94c96375-1ca7-412d-9eee-80fda94f6e0"
      [  {
        "name" : "axgroup-001",
        "properties" : {
        },
        "scopes" : [ "example~prod", "example~test" ],
        "uuids" : {
              "qpid-server" : [ "94c96375-1ca7-412d-9eee-80fda94f6e07", "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
              "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0"]
        },
        "consumer-groups" : [ {
          "name" : "consumer-group-001",
          "consumers" : [ "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
          "datastores" : ["8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f57 ],
          "properties" : {
          }
        } ],
        "data-processors" : {
        }
    3. 使用以下 API 调用从 qpid-server 元素中移除单个 qpid-server UUID(根据需要重复多次):
      curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://ms-IP:8080/v1/analytics/groups/ax/axgroupname/servers?uuid=qpiduuid&type=qpid-server"

      调用和输出示例:

      curl -v -u adminEmail:pword -X DELETE -H 'Accept: application/json' "http://localhost:8080/v1/analytics/groups/ax/axgroup-001/servers?uuid=94c96375-1ca7-412d-9eee-80fda94f6e0&type=qpid-server"
      [  {
        "name" : "axgroup-001",
        "properties" : {
        },
        "scopes" : [ "example~prod", "example~test" ],
        "uuids" : {
              "qpid-server" : ["54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
              "postgres-server" : [ "8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f572b69c5f0"]
        },
        "consumer-groups" : [ {
          "name" : "consumer-group-001",
          "consumers" : [ "54a96375-33a7-4fba-6bfa-80fda94f6e07" ],
          "datastores" : ["8ee86b70-5b33-44b6-b2f8-1b0ec0ec8d77:731c8c43-8c35-4b58-ad1a-f57 ],
          "properties" : {
          }
        } ],
        "data-processors" : {
        }
    4. 重启所有节点上的所有 edge-qpid-server 组件,以确保这些组件能够获取相应更改:
      /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server restart
      /opt/apigee/apigee-service/bin/apigee-service edge-qpid-server wait_for_ready