当前位置: 首页 > news >正文

淄博网站建设开发惠州百度seo找谁

淄博网站建设开发,惠州百度seo找谁,wordpress点击图片,狠狠做网站Flink on yarn 加载失败plugins失效问题解决 flink版本:1.13.6 1. 问题 flink 任务运行在yarn集群,plugins加载失效,导致通过扩展资源获取任务参数失效 2. 问题定位 yarn容器的jar包及插件信息,jar包是正常上传 源码定位 加载plugins入口,TaskMana…

Flink on yarn 加载失败plugins失效问题解决

flink版本:1.13.6

1. 问题

flink 任务运行在yarn集群,plugins加载失效,导致通过扩展资源获取任务参数失效

2. 问题定位

  1. yarn容器的jar包及插件信息,jar包是正常上传
    在这里插入图片描述

  2. 源码定位
    加载plugins入口,TaskManagerRunner.class
    PluginUtils.createPluginManagerFromRootFolder
    在这里插入图片描述
    源码加载扩展资源参数入口TaskManagerRunner.class
    ExternalResourceUtils.createStaticExternalResourceInfoProviderFromConfig
    在这里插入图片描述
    日志信息
    在这里插入图片描述
    定位PluginConfig源码
    在这里插入图片描述

3. 方案

重写覆盖集群的PluginConfig.java,优先从configurtaion获取

/** 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.*/package org.apache.flink.core.plugin;import com.alibaba.fastjson.JSON;
import org.apache.commons.lang3.StringUtils;
import org.apache.flink.configuration.*;import org.slf4j.Logger;
import org.slf4j.LoggerFactory;import java.io.File;
import java.nio.file.Path;
import java.util.Arrays;
import java.util.Objects;
import java.util.Optional;/** Stores the configuration for plugins mechanism. */
@SuppressWarnings("OptionalUsedAsFieldOrParameterType")
public class PluginConfig {private static final Logger LOG = LoggerFactory.getLogger(PluginConfig.class);private static final String PUPU_FLINK_PLUGINS_DIR = "flink_plugins_dir";private final Optional<Path> pluginsPath;private final String[] alwaysParentFirstPatterns;private PluginConfig(Optional<Path> pluginsPath, String[] alwaysParentFirstPatterns) {pluginsPath.ifPresent(path -> LOG.info("pluginsPath: {}", path));LOG.info("alwaysParentFirstPatterns: {}", Arrays.stream(alwaysParentFirstPatterns).toArray());this.pluginsPath = pluginsPath;this.alwaysParentFirstPatterns = alwaysParentFirstPatterns;}public Optional<Path> getPluginsPath() {return pluginsPath;}public String[] getAlwaysParentFirstPatterns() {return alwaysParentFirstPatterns;}public static PluginConfig fromConfiguration(Configuration configuration) {return new PluginConfig(getPluginsDir(configuration).map(File::toPath),CoreOptions.getPluginParentFirstLoaderPatterns(configuration));}public static Optional<File> getPluginsDir(Configuration configuration) {String pluginsDir = configuration.get(ConfigOptions.key(PUPU_FLINK_PLUGINS_DIR).stringType().defaultValue(null));if (StringUtils.isBlank(pluginsDir)) {pluginsDir =System.getenv().getOrDefault(ConfigConstants.ENV_FLINK_PLUGINS_DIR,ConfigConstants.DEFAULT_FLINK_PLUGINS_DIRS);}File pluginsDirFile = new File(pluginsDir);if (!pluginsDirFile.isDirectory()) {LOG.warn("The plugins directory [{}] does not exist.", pluginsDirFile);return Optional.empty();}return Optional.of(pluginsDirFile);}}
http://www.hkea.cn/news/41474/

相关文章:

  • 绵阳网站建设 经开区网络教学平台
  • wordpress阅读量没改7个湖北seo网站推广策略
  • 网站建设成功案例方案找培训机构的平台
  • 园林绿化网站建设百度关键词优化公司
  • 个人如何建设网站网络营销方式有哪些分类
  • 北京做百度网站建设电商平台如何推广运营
  • 电脑个人网站怎么做网络销售新手入门
  • 海口网站建设 小黄网络手机百度搜索
  • 太原百度网站建设网站应该如何进行优化
  • 烟台市做网站uc浏览网页版进入
  • 工程信息网站哪家做的较好提高工作效率心得体会
  • 建站平台入口徐州网站设计
  • 出口手工艺品网站建设方案站长统计app下载
  • 提升学历骗局武汉搜索引擎排名优化
  • wordpress+park主题上海全国关键词排名优化
  • 潍坊最早做网站的公司短链接生成网址
  • 东莞化工网站建设爱站网ip反域名查询
  • 做网站赚钱 2017哈尔滨关键词排名工具
  • 建设的网站首页微信怎么做推广
  • 建设网站导航百度信息流推广和搜索推广
  • 深圳室内设计公司招聘信息流广告优化
  • 旅游网站首页四种营销模式
  • 负责网站建设如何在百度发广告推广
  • 联通的网站是谁做的营销的主要目的有哪些
  • 衡阳微信网站地推的方法和技巧
  • 南阳做网站公司哪家好自动发外链工具
  • 潍坊网站制作最低价格网络营销案例有哪些
  • 做网站有谁做谷歌seo视频教程
  • 资深的网站推广完美日记网络营销策划书
  • 90设计网站免费素材网站seo培训