踩坑:一个"、"引发的 Element 'properties' cannot have character [children],because the type's content type

踩坑:一个”、”引发的 Element ‘properties’ cannot have character [children],because the type’s content type is element

标签(空格分隔): 踩坑


做项目时遇到这个问题:

Element 'properties' cannot have character [children],because the type's content type is element-only.  翻译为:元素 'beans' 必须不含字符 [子级], 因为该类型的内容类型为“仅元素"。

贴上代码块:

  <properties>
    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
    <maven.compiler.source>1.7</maven.compiler.source>
    <maven.compiler.target>1.7</maven.compiler.target>、
    <hadoop.version>2.6.0-cdh5.7.0</hadoop.version>
  </properties>

配置文件中的properties节点下面只能是元素节点,不能有字符或文本存在。经过检查,发现自己不知道什么时候不小心在配置文件中打了一个顿号,所以导致错误。
去掉多加的点即可解决。

我好像瞎了。

不过最惊喜的是,改完这个地方,弄了一晚上的hadoop-client依赖居然下载好了!

猜你喜欢

转载自blog.csdn.net/japson_iot/article/details/80519231