itinycheng / flink-connector-clickhouse

Flink SQL connector for ClickHouse. Support ClickHouseCatalog and read/write primary data, maps, arrays to clickhouse.
Apache License 2.0
373 stars 156 forks source link

没学过java不会编译 #84

Closed ysq5202121 closed 1 year ago

ysq5202121 commented 1 year ago

能不能编译一些特定版本

ysq5202121 commented 1 year ago

class com.google.googlejavaformat.java.RemoveUnusedImports (in unnamed module @0x1736273c) cannot access class com.sun.tools.javac.util.Context (in module jdk.compiler) because module jdk.compiler does not export com.sun.tools.javac.util to unnamed module @0x1736273c 打包报错

ysq5202121 commented 1 year ago

月 06, 2023 12:35:44 上午 com.diffplug.spotless.FormatExceptionPolicyLegacy error 严重: Step 'removeUnusedImports' found problem in 'src\main\java\org\apache\flink\connector\clickhouse\catalog\ClickHouseCatalog.java': null java.lang.reflect.InvocationTargetException at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:119) at java.base/java.lang.reflect.Method.invoke(Method.java:578) at com.diffplug.spotless.java.GoogleJavaFormatStep$State.lambda$constructRemoveUnusedFunction$3(GoogleJavaFormatStep.java:190) at com.diffplug.spotless.java.GoogleJavaFormatStep$State.lambda$createRemoveUnusedImportsOnly$1(GoogleJavaFormatStep.java:167) at com.diffplug.spotless.FormatterFunc.apply(FormatterFunc.java:32) at com.diffplug.spotless.FormatterStepImpl$Standard.format(FormatterStepImpl.java:78) at com.diffplug.spotless.FormatterStep$Strict.format(FormatterStep.java:76) at com.diffplug.spotless.Formatter.compute(Formatter.java:230) at com.diffplug.spotless.PaddedCell.calculateDirtyState(PaddedCell.java:201) at com.diffplug.spotless.PaddedCell.calculateDirtyState(PaddedCell.java:188) at com.diffplug.spotless.maven.SpotlessCheckMojo.process(SpotlessCheckMojo.java:52) at com.diffplug.spotless.maven.AbstractSpotlessMojo.execute(AbstractSpotlessMojo.java:146) at com.diffplug.spotless.maven.AbstractSpotlessMojo.execute(AbstractSpotlessMojo.java:137) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:137) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:210) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:156) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:148) 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:305) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:192) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:105) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:957) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:289) at org.apache.maven.cli.MavenCli.main(MavenCli.java:193) at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104) at java.base/java.lang.reflect.Method.invoke(Method.java:578) 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) at org.codehaus.classworlds.Launcher.main(Launcher.java:47) Caused by: java.lang.IllegalAccessError: class com.google.googlejavaformat.java.RemoveUnusedImports (in unnamed module @0x1736273c) cannot access class com.sun.tools.javac.util.Context (in module jdk.compiler) because module jdk.compiler does not export com.sun.tools.javac.util to unnamed module @0x1736273c at com.google.googlejavaformat.java.RemoveUnusedImports.removeUnusedImports(RemoveUnusedImports.java:187) at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:104) ... 33 more

itinycheng commented 1 year ago

用jdk8或jdk11的环境,切换到要编译的分支版本,然后执行如下命令: ./mvnw clean package -DskipTests

ysq5202121 commented 1 year ago

用jdk8或jdk11的环境,切换到要编译的分支版本,然后执行如下命令: ./mvnw clean package -DskipTests 多谢大佬