«Не удалось отправить супервизор: не удалось выполнить запрос с кодом состояния 502» при передаче спецификации загрузки на маршрутизатор - PullRequest
0 голосов
/ 20 мая 2019

Я получаю сообщение об ошибке "Не удалось отправить супервизора: не удалось выполнить запрос с кодом состояния 502" , когда я пытаюсь передать спецификацию приема в интерфейс друида (через маршрутизатор). Спецификация приема пищи работает на отдельном сервере друидов.

Я настроил кластер, используя 4 машины-1 для координатора и оверлорда (мастера), 1 для исторического и среднего менеджера (данные), 1 для брокера (запрос) и 1 для маршрутизатора, с отдельным экземпляром для работник зоопарка. В логах нет ошибок.

Характеристики для приема внутрь следующие:

{
  "type": "kafka",
  "dataSchema": {
    "dataSource": "table1",
    "parser": {
      "type": "string",
      "parseSpec": {
        "format": "json",
        "dimensionsSpec": {
          "dimensions": [
           // List of valid dimensions
          ]
        },
        "timestampSpec": {
          "column": "createdOnDate", // In 'YYYY-MM-DD' format
          "format": "iso"
        }
      }
    },
    "granularitySpec": {
      "type": "uniform",
      "segmentGranularity": "MONTH",
      "rollup": false,
      "queryGranularity": "none"
    },
    "metricsSpec": []
  },
  "ioConfig": {
    "type": "kafka",
    "topic": "mongotopic",
    "consumerProperties": {
      "bootstrap.servers": "ip:9092"
    },
    "useEarliestOffset": true
  },
  "tuningConfig": {
    "type": "kafka",
    "forceExtendableShardSpecs": true,
    "maxParseExceptions": 100,
    "maxSavedParseExceptions": 10
  }
}

Содержимое файла common.runtime.properties выглядит следующим образом:

#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements.  See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership.  The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License.  You may obtain a copy of the License at
#
#   http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied.  See the License for the
# specific language governing permissions and limitations
# under the License.
#

#
# Extensions
#

# This is not the full list of Druid extensions, but common ones that people often use. You may need to change this list
# based on your particular setup.
druid.extensions.loadList=["druid-histogram", "druid-datasketches", "druid-lookups-cached-global", "druid-s3-extensions","postgresql-metadata-storage"]

# If you have a different version of Hadoop, place your Hadoop client jar files in your hadoop-dependencies directory
# and uncomment the line below to point to your directory.
#druid.extensions.hadoopDependenciesDir=/my/dir/hadoop-dependencies

#
# Logging
#

# Log all runtime properties on startup. Disable to avoid logging properties on startup:
druid.startup.logging.logProperties=true

#
# Zookeeper
#

druid.zk.service.host=druid-ip:2181
druid.zk.paths.base=/druid

#
# Metadata storage
#

# For Derby server on your Druid Coordinator (only viable in a cluster with a single Coordinator, no fail-over):
#druid.metadata.storage.type=derby
#druid.metadata.storage.connector.connectURI=jdbc:derby://metadata.store.ip:1527/var/druid/metadata.db;create=true
#druid.metadata.storage.connector.host=metadata.store.ip
#druid.metadata.storage.connector.port=1527

# For MySQL (make sure to include the MySQL JDBC driver on the classpath):
#druid.metadata.storage.type=mysql
#druid.metadata.storage.connector.connectURI=jdbc:mysql:///druid
#druid.metadata.storage.connector.user=druid
#druid.metadata.storage.connector.password=druid

# For PostgreSQL (make sure to additionally include the Postgres extension):
druid.metadata.storage.type=postgresql
druid.metadata.storage.connector.connectURI=jdbc:postgresql://db.example.com:5432/druid
druid.metadata.storage.connector.user=user
druid.metadata.storage.connector.password=password

#
# Deep storage
#

# For local disk (only viable in a cluster if this is a network mount):
# druid.storage.type=local
# druid.storage.storageDirectory=var/druid/segments

# For HDFS (make sure to include the HDFS extension and that your Hadoop config files in the cp):
#druid.storage.type=hdfs
#druid.storage.storageDirectory=/druid/segments

# For S3:
druid.storage.type=s3
druid.storage.bucket=valid-bucket
druid.storage.baseKey=druid/segments
druid.s3.accessKey=valid-key
druid.s3.secretKey=valid-secret

#
# Indexing service logs
#

# For local disk (only viable in a cluster if this is a network mount):
#druid.indexer.logs.type=file
#druid.indexer.logs.directory=var/druid/indexing-logs

# For HDFS (make sure to include the HDFS extension and that your Hadoop config files in the cp):
#druid.indexer.logs.type=hdfs
#druid.indexer.logs.directory=/druid/indexing-logs

# For S3:
druid.indexer.logs.type=s3
druid.indexer.logs.s3Bucket=druid-test-1
druid.indexer.logs.s3Prefix=druid/indexing-logs

#
# Service discovery
#

druid.selectors.indexing.serviceName=druid/overlord
druid.selectors.coordinator.serviceName=druid/coordinator

#
# Monitoring
#

druid.monitoring.monitors=["org.apache.druid.java.util.metrics.JvmMonitor"]
druid.emitter=logging
druid.emitter.logging.logLevel=info

# Storage type of double columns
# ommiting this will lead to index double as float at the storage layer

druid.indexing.doubleStorage=double

#
# SQL
#
druid.sql.enable=true

При отправке спецификации на вкладку задачи / супервизора / Отправить супервизора через IP-адрес маршрутизатора (IP: 8888 / unified-console) я получаю Не удалось отправить супервизора: запрос не выполнен с кодом состояния 502 ошибка в пользовательском интерфейсе. Конфигурации Zookeeper, S3 и Postgres действительны. Пользовательский интерфейс отображает 1 менеджера среднего звена и 0 историй, 0 источников данных и 0 сегментов.

1 Ответ

0 голосов
/ 22 мая 2019

Это произошло из-за того, что расширение druid-kafka-indexing-service отсутствовало в списке расширений common.runtime.properties .

...