sbt idea build project 报错 invalid sha1: expected=<html> [warn] <head> ?

Error while importing sbt project:
[info] Loading settings for project global-plugins from idea.sbt ...
[info] Loading global plugins from D:\SBT\sbt.sbt\plugins
[info] Updating ProjectRef(uri("file:/D:/SBT/sbt/.sbt/plugins/"), "global-plugins")...
[info] Done updating. [info] Loading project definition from D:\IDEA\sbttest\project
[info] Updating ProjectRef(uri("file:/D:/IDEA/sbttest/project/"), "sbttest-build")...
[info] Done updating.
[info] Loading settings for project root from build.sbt ...
[info] Set current project to sbttest (in build file:/D:/IDEA/sbttest/)
[info] sbt server started at local:sbt-server-92123181769dae5e81c2 sbt:sbttest>
[info] Defining Global / sbtStructureOptions, Global / sbtStructureOutputFile, shellPrompt
[info] The new values will be used by no settings or tasks.
[info] Reapplying settings... [info] Set current project to sbttest (in build file:/D:/IDEA/sbttest/)
[info] Applying State transformations org.jetbrains.sbt.CreateTasks from D:/IDEA/IAD/.IntelliJIdea/config/plugins/Scala/launcher/sbt-structure-1.0.jar
[info] Reapplying settings...
[info] Set current project to sbttest (in build file:/D:/IDEA/sbttest/)
[info] Updating ...
[warn] problem while downloading module descriptor: http://mirrors.ibiblio.org/maven2/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom: invalid sha1: expected= [warn]

computed=47abf2c9ebd0dedcc526c0800426f709d8179231 (160357ms)
[warn] module not found: org.apache.flink#flink -streaming-scala;1.7.0
[warn] ==== local: tried
[warn] D:\SBT\sbt.ivy2\local\org.apache.flink\flink-streaming-scala\1.7.0\ivys\ivy.xml
[warn] ==== comp-maven: tried
[warn] http://mvnrepository.com/artifact/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom
[warn] ==== sbt-releases-repo: tried
[warn] http://repo.typesafe.com/typesafe/ivy-releases/org.apache.flink/flink-streaming-scala/1.7.0/ivys/ivy.xml

[warn] ==== sbt-plugins-repo: tried
[warn] http://repo.scala-sbt.org/scalasbt/sbt-plugin-releases/org.apache.flink/flink-streaming-scala/1.7.0/ivys/ivy.xml

[warn] ==== ali1: tried
[warn] http://maven.aliyun.com/nexus/content/groups/public/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom
[warn] ==== ali2: tried
[warn] https://oss.sonatype.org/content/repositories/snapshots/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom
[warn] ==== store_0: tried
[warn] https://repository.apache.org/content/repositories/snapshots/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom
[warn] ==== store_1: tried
[warn] http://mirrors.ibiblio.org/maven2/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom
[warn] ==== store_2: tried
[warn] http://repo2.maven.org/maven2/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom
[warn] ==== maven-central: tried
[warn] http://repo1.maven.org/maven2/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom
[warn] ==== Apach : tried
[warn] https://repository.apache.org/content/repositories/snapshots/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom
[warn] ==== velvia maven: tried
[warn] http://dl.bintray.com/velvia/maven/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom
[warn] ==== ali: tried
[warn] https://maven.aliyun.com/repository/public/org/apache/flink/flink-streaming-scala/1.7.0/flink-streaming-scala-1.7.0.pom
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: UNRESOLVED DEPENDENCIES ::
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn] :: org.apache.flink#flink-streaming-scala;1.7.0: not found
[warn] ::::::::::::::::::::::::::::::::::::::::::::::
[warn]
[warn] Note: Unresolved dependencies path:
[warn] org.apache.flink:flink-streaming-scala:1.7.0 (D:\IDEA\sbttest\build.sbt#L35)
[warn] +- sbttest:sbttest_2.11:0.1
[error] sbt.librarymanagement.ResolveException: unresolved dependency: org.apache.flink#flink-streaming-scala;1.7.0: not found
[error] at sbt.internal.librarymanagement.IvyActions$.resolveAndRetrieve(IvyActions.scala:332)
[error] at sbt.internal.librarymanagement.IvyActions$.$anonfun$updateEither$1(IvyActions.scala:208)
[error] at sbt.internal.librarymanagement.IvySbt$Module.$anonfun$withModule$1(Ivy.scala:239)
[error] at sbt.internal.librarymanagement.IvySbt.$anonfun$withIvy$1(Ivy.scala:204)
[error] at sbt.internal.librarymanagement.IvySbt.sbt$internal$librarymanagement$IvySbt$$action$1(Ivy.scala:70)
[error] at sbt.internal.librarymanagement.IvySbt$$anon$3.call(Ivy.scala:77)
[error] at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:95)
[error] at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:80)
[error] at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:99)
[error] at xsbt.boot.Using$.withResource(Using.scala:10)
[error] at xsbt.boot.Using$.apply(Using.scala:9)
[error] at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:60)
[error] at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:50)
[error] at xsbt.boot.Locks$.apply0(Locks.scala:31)
[error] at xsbt.boot.Locks$.apply(Locks.scala:28)
[error] at sbt.internal.librarymanagement.IvySbt.withDefaultLogger(Ivy.scala:77)
[error] at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:199)
[error] at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:196)
[error] at sbt.internal.librarymanagement.IvySbt$Module.withModule(Ivy.scala:238)
[error] at sbt.internal.librarymanagement.IvyActions$.updateEither(IvyActions.scala:193)
[error] at sbt.librarymanagement.ivy.IvyDependencyResolution.update(IvyDependencyResolution.scala:20)
[error] at sbt.librarymanagement.DependencyResolution.update(DependencyResolution.scala:56)
[error] at sbt.internal.LibraryManagement$.resolve$1(LibraryManagement.scala:45)
[error] at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$12(LibraryManagement.scala:93)
[error] at sbt.util.Tracked$.$anonfun$lastOutput$1(Tracked.scala:68)
[error] at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$19(LibraryManagement.scala:106)
[error] at scala.util.control.Exception$Catch.apply(Exception.scala:224)
[error] at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$11(LibraryManagement.scala:106)
[error] at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$11$adapted(LibraryManagement.scala:89)
[error] at sbt.util.Tracked$.$anonfun$inputChanged$1(Tracked.scala:149)
[error] at sbt.internal.LibraryManagement$.cachedUpdate(LibraryManagement.scala:120)
[error] at sbt.Classpaths$.$anonfun$updateTask$5(Defaults.scala:2556)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:44)
[error] at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:40)
[error] at sbt.std.Transform$$anon$4.work(System.scala:67)
[error] at sbt.Execute.$anonfun$submit$2(Execute.scala:269)
[error] at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error] at sbt.Execute.work(Execute.scala:278)
[error] at sbt.Execute.$anonfun$submit$1(Execute.scala:269)
[error] at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:178)
[error] at sbt.CompletionService$$anon$2.call(CompletionService.scala:37)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error] at java.lang.Thread.run(Thread.java:748)
[error] sbt.librarymanagement.ResolveException: unresolved dependency: org.apache.flink#flink-streaming-scala;1.7.0: not found
[error] at sbt.internal.librarymanagement.IvyActions$.resolveAndRetrieve(IvyActions.scala:332)
[error] at sbt.internal.librarymanagement.IvyActions$.$anonfun$updateEither$1(IvyActions.scala:208)
[error] at sbt.internal.librarymanagement.IvySbt$Module.$anonfun$withModule$1(Ivy.scala:239)
[error] at sbt.internal.librarymanagement.IvySbt.$anonfun$withIvy$1(Ivy.scala:204)
[error] at sbt.internal.librarymanagement.IvySbt.sbt$internal$librarymanagement$IvySbt$$action$1(Ivy.scala:70)
[error] at sbt.internal.librarymanagement.IvySbt$$anon$3.call(Ivy.scala:77)
[error] at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:95)
[error] at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:80)
[error] at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:99)
[error] at xsbt.boot.Using$.withResource(Using.scala:10)
[error] at xsbt.boot.Using$.apply(Using.scala:9)
[error] at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:60)
[error] at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:50)
[error] at xsbt.boot.Locks$.apply0(Locks.scala:31)
[error] at xsbt.boot.Locks$.apply(Locks.scala:28)
[error] at sbt.internal.librarymanagement.IvySbt.withDefaultLogger(Ivy.scala:77)
[error] at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:199)
[error] at sbt.internal.librarymanagement.IvySbt.withIvy(Ivy.scala:196)
[error] at sbt.internal.librarymanagement.IvySbt$Module.withModule(Ivy.scala:238)
[error] at sbt.internal.librarymanagement.IvyActions$.updateEither(IvyActions.scala:193)
[error] at sbt.librarymanagement.ivy.IvyDependencyResolution.update(IvyDependencyResolution.scala:20)
[error] at sbt.librarymanagement.DependencyResolution.update(DependencyResolution.scala:56)
[error] at sbt.internal.LibraryManagement$.resolve$1(LibraryManagement.scala:45)
[error] at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$12(LibraryManagement.scala:93)
[error] at sbt.util.Tracked$.$anonfun$lastOutput$1(Tracked.scala:68)
[error] at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$19(LibraryManagement.scala:106)
[error] at scala.util.control.Exception$Catch.apply(Exception.scala:224)
[error] at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$11(LibraryManagement.scala:106)
[error] at sbt.internal.LibraryManagement$.$anonfun$cachedUpdate$11$adapted(LibraryManagement.scala:89)
[error] at sbt.util.Tracked$.$anonfun$inputChanged$1(Tracked.scala:149)
[error] at sbt.internal.LibraryManagement$.cachedUpdate(LibraryManagement.scala:120)
[error] at sbt.Classpaths$.$anonfun$updateTask$5(Defaults.scala:2556)
[error] at scala.Function1.$anonfun$compose$1(Function1.scala:44)
[error] at sbt.internal.util.$tilde$greater.$anonfun$$u2219$1(TypeFunctions.scala:40)
[error] at sbt.std.Transform$$anon$4.work(System.scala:67)
[error] at sbt.Execute.$anonfun$submit$2(Execute.scala:269)
[error] at sbt.internal.util.ErrorHandling$.wideConvert(ErrorHandling.scala:16)
[error] at sbt.Execute.work(Execute.scala:278)
[error] at sbt.Execute.$anonfun$submit$1(Execute.scala:269)
[error] at sbt.ConcurrentRestrictions$$anon$4.$anonfun$submitValid$1(ConcurrentRestrictions.scala:178)
[error] at sbt.CompletionService$$anon$2.call(CompletionService.scala:37)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
[error] at java.util.concurrent.FutureTask.run(FutureTask.java:266)
[error] at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
[error] at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
[error] at java.lang.Thread.run(Thread.java:748)
error sbt.librarymanagement.ResolveException: unresolved dependency: org.apache.flink#flink-streaming-scala;1.7.0: not found
error sbt.librarymanagement.ResolveException: unresolved dependency: org.apache.flink#flink-streaming-scala;1.7.0: not found
[error] Total time: 178 s, completed 2019-6-19 8:35:29
[info] shutting down server
Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=512M; support was removed in 8.0
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
IDEA安装导入sbt依赖库时失败!尝试了三天依然无法成功导入,求大神指点!!!
dump project structure from sbt 一直无法成功. sbt shell中显示[info] Loading settings for project global-plugins from idea.sbt scala 2.11.8 sbt 1.3.4 请问怎么解决呢?
Intellij 导入git项目sbt报错
![图片说明](https://img-ask.csdn.net/upload/201708/21/1503299221_866858.jpg) 如图,在build.sbt中导入了typesafa相关包,结果在import sbt项目的时候报错如上 万谢
sbt报错scala.runtime in compiler mirror not found
用sbt编译kafka manager工程时报错如下信息: [info] Loading project definition from E:\workspace\idea\kafka-manager-master\project error: error while loading <root>, error in opening zip file scala.reflect.internal.MissingRequirementError: object scala.runtime in compiler mirror not found. at scala.reflect.internal.MissingRequirementError$.signal(MissingRequirementError.scala:16) at scala.reflect.internal.MissingRequirementError$.notFound(MissingRequirementError.scala:17) at scala.reflect.internal.Mirrors$RootsBase.getModuleOrClass(Mirrors.scala:48) at scala.reflect.internal.Mirrors$RootsBase.getModuleOrClass(Mirrors.scala:40) at scala.reflect.internal.Mirrors$RootsBase.getModuleOrClass(Mirrors.scala:61) at scala.reflect.internal.Mirrors$RootsBase.getPackage(Mirrors.scala:172) at scala.reflect.internal.Mirrors$RootsBase.getRequiredPackage(Mirrors.scala:175) at scala.reflect.internal.Definitions$DefinitionsClass.RuntimePackage$lzycompute(Definitions.scala:183) at scala.reflect.internal.Definitions$DefinitionsClass.RuntimePackage(Definitions.scala:183) at scala.reflect.internal.Definitions$DefinitionsClass.RuntimePackageClass$lzycompute(Definitions.scala:184) at scala.reflect.internal.Definitions$DefinitionsClass.RuntimePackageClass(Definitions.scala:184) at scala.reflect.internal.Definitions$DefinitionsClass.AnnotationDefaultAttr$lzycompute(Definitions.scala:1024) at scala.reflect.internal.Definitions$DefinitionsClass.AnnotationDefaultAttr(Definitions.scala:1023) at scala.reflect.internal.Definitions$DefinitionsClass.syntheticCoreClasses$lzycompute(Definitions.scala:1153) at scala.reflect.internal.Definitions$DefinitionsClass.syntheticCoreClasses(Definitions.scala:1152) at scala.reflect.internal.Definitions$DefinitionsClass.symbolsNotPresentInBytecode$lzycompute(Definitions.scala:1196) at scala.reflect.internal.Definitions$DefinitionsClass.symbolsNotPresentInBytecode(Definitions.scala:1196) at scala.reflect.internal.Definitions$DefinitionsClass.init(Definitions.scala:1261) at scala.tools.nsc.Global$Run.<init>(Global.scala:1290) at sbt.compiler.Eval$$anon$1.<init>(Eval.scala:141) at sbt.compiler.Eval.run$lzycompute$1(Eval.scala:141) at sbt.compiler.Eval.run$1(Eval.scala:141) at sbt.compiler.Eval.unlinkAll$1(Eval.scala:144) at sbt.compiler.Eval.evalCommon(Eval.scala:153) at sbt.compiler.Eval.evalDefinitions(Eval.scala:122) at sbt.EvaluateConfigurations$.evaluateDefinitions(EvaluateConfigurations.scala:271) at sbt.EvaluateConfigurations$.evaluateSbtFile(EvaluateConfigurations.scala:109) at sbt.Load$.sbt$Load$$loadSettingsFile$1(Load.scala:775) at sbt.Load$$anonfun$sbt$Load$$memoLoadSettingsFile$1$1.apply(Load.scala:781) at sbt.Load$$anonfun$sbt$Load$$memoLoadSettingsFile$1$1.apply(Load.scala:780) at scala.collection.MapLike$class.getOrElse(MapLike.scala:128) at scala.collection.AbstractMap.getOrElse(Map.scala:58) at sbt.Load$.sbt$Load$$memoLoadSettingsFile$1(Load.scala:780) at sbt.Load$$anonfun$loadFiles$1$2.apply(Load.scala:788) at sbt.Load$$anonfun$loadFiles$1$2.apply(Load.scala:788) at scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:244) at scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:244) at scala.collection.mutable.ResizableArray$class.foreach(ResizableArray.scala:59) at scala.collection.mutable.ArrayBuffer.foreach(ArrayBuffer.scala:47) at scala.collection.TraversableLike$class.map(TraversableLike.scala:244) at scala.collection.AbstractTraversable.map(Traversable.scala:105) at sbt.Load$.loadFiles$1(Load.scala:788) at sbt.Load$.discoverProjects(Load.scala:799) at sbt.Load$.discover$1(Load.scala:585) at sbt.Load$.sbt$Load$$loadTransitive(Load.scala:633) at sbt.Load$$anonfun$loadUnit$1.sbt$Load$$anonfun$$loadProjects$1(Load.scala:482) at sbt.Load$$anonfun$loadUnit$1$$anonfun$40.apply(Load.scala:485) at sbt.Load$$anonfun$loadUnit$1$$anonfun$40.apply(Load.scala:485) at sbt.Load$.timed(Load.scala:1025) at sbt.Load$$anonfun$loadUnit$1.apply(Load.scala:485) at sbt.Load$$anonfun$loadUnit$1.apply(Load.scala:459) at sbt.Load$.timed(Load.scala:1025) at sbt.Load$.loadUnit(Load.scala:459) at sbt.Load$$anonfun$25$$anonfun$apply$14.apply(Load.scala:311) at sbt.Load$$anonfun$25$$anonfun$apply$14.apply(Load.scala:310) at sbt.BuildLoader$$anonfun$componentLoader$1$$anonfun$apply$4$$anonfun$apply$5$$anonfun$apply$6.apply(BuildLoader.scala:91) at sbt.BuildLoader$$anonfun$componentLoader$1$$anonfun$apply$4$$anonfun$apply$5$$anonfun$apply$6.apply(BuildLoader.scala:90) at sbt.BuildLoader.apply(BuildLoader.scala:140) at sbt.Load$.loadAll(Load.scala:365) at sbt.Load$.loadURI(Load.scala:320) at sbt.Load$.load(Load.scala:316) at sbt.Load$.load(Load.scala:305) at sbt.Load$$anonfun$4.apply(Load.scala:146) at sbt.Load$$anonfun$4.apply(Load.scala:146) at sbt.Load$.timed(Load.scala:1025) at sbt.Load$.apply(Load.scala:146) at sbt.Load$.defaultLoad(Load.scala:39) at sbt.BuiltinCommands$.liftedTree1$1(Main.scala:496) at sbt.BuiltinCommands$.doLoadProject(Main.scala:496) at sbt.BuiltinCommands$$anonfun$loadProjectImpl$2.apply(Main.scala:488) at sbt.BuiltinCommands$$anonfun$loadProjectImpl$2.apply(Main.scala:488) at sbt.Command$$anonfun$applyEffect$1$$anonfun$apply$2.apply(Command.scala:59) at sbt.Command$$anonfun$applyEffect$1$$anonfun$apply$2.apply(Command.scala:59) at sbt.Command$$anonfun$applyEffect$2$$anonfun$apply$3.apply(Command.scala:61) at sbt.Command$$anonfun$applyEffect$2$$anonfun$apply$3.apply(Command.scala:61) at sbt.Command$.process(Command.scala:93) at sbt.MainLoop$$anonfun$1$$anonfun$apply$1.apply(MainLoop.scala:96) at sbt.MainLoop$$anonfun$1$$anonfun$apply$1.apply(MainLoop.scala:96) at sbt.State$$anon$1.process(State.scala:184) at sbt.MainLoop$$anonfun$1.apply(MainLoop.scala:96) at sbt.MainLoop$$anonfun$1.apply(MainLoop.scala:96) at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:17) at sbt.MainLoop$.next(MainLoop.scala:96) at sbt.MainLoop$.run(MainLoop.scala:89) at sbt.MainLoop$$anonfun$runWithNewLog$1.apply(MainLoop.scala:68) at sbt.MainLoop$$anonfun$runWithNewLog$1.apply(MainLoop.scala:63) at sbt.Using.apply(Using.scala:24) at sbt.MainLoop$.runWithNewLog(MainLoop.scala:63) at sbt.MainLoop$.runAndClearLast(MainLoop.scala:46) at sbt.MainLoop$.runLoggedLoop(MainLoop.scala:30) at sbt.MainLoop$.runLogged(MainLoop.scala:22) at sbt.StandardMain$.runManaged(Main.scala:57) at sbt.xMain.run(Main.scala:29) at xsbt.boot.Launch$$anonfun$run$1.apply(Launch.scala:109) at xsbt.boot.Launch$.withContextLoader(Launch.scala:128) at xsbt.boot.Launch$.run(Launch.scala:109) at xsbt.boot.Launch$$anonfun$apply$1.apply(Launch.scala:35) at xsbt.boot.Launch$.launch(Launch.scala:117) at xsbt.boot.Launch$.apply(Launch.scala:18) at xsbt.boot.Boot$.runImpl(Boot.scala:41) at xsbt.boot.Boot$.main(Boot.scala:17) at xsbt.boot.Boot.main(Boot.scala) [error] scala.reflect.internal.MissingRequirementError: object scala.runtime in compiler mirror not found. [error] Use 'last' for the full log. Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=768M; support was removed in 8.0
运行 sbt 时报错,是什么问题?
-VirtualBox:~/Android/jvm$ sbt [info] Loading project definition from /home/ng/AndroidToolChain/jvm-toxcore-c/project java.lang.NullPointerException at java.base/java.util.regex.Matcher.getTextLength(Matcher.java:1770) at java.base/java.util.regex.Matcher.reset(Matcher.java:416) at java.base/java.util.regex.Matcher.<init>(Matcher.java:253) at java.base/java.util.regex.Pattern.matcher(Pattern.java:1133) at java.base/java.util.regex.Pattern.split(Pattern.java:1261) at java.base/java.util.regex.Pattern.split(Pattern.java:1334) at sbt.IO$.pathSplit(IO.scala:797) at sbt.IO$.parseClasspath(IO.scala:912) at sbt.compiler.CompilerArguments.extClasspath(CompilerArguments.scala:66) at sbt.compiler.MixedAnalyzingCompiler$.withBootclasspath(MixedAnalyzingCompiler.scala:188) at sbt.compiler.MixedAnalyzingCompiler$.searchClasspathAndLookup(MixedAnalyzingCompiler.scala:166) at sbt.compiler.MixedAnalyzingCompiler$.apply(MixedAnalyzingCompiler.scala:176) at sbt.compiler.IC$.incrementalCompile(IncrementalCompiler.scala:138) at sbt.Compiler$.compile(Compiler.scala:152) at sbt.Compiler$.compile(Compiler.scala:138) at sbt.Defaults$.sbt$Defaults$$compileIncrementalTaskImpl(Defaults.scala:860) at sbt.Defaults$$anonfun$compileIncrementalTask$1.apply(Defaults.scala:851) at sbt.Defaults$$anonfun$compileIncrementalTask$1.apply(Defaults.scala:849) at scala.Function1$$anonfun$compose$1.apply(Function1.scala:47) at sbt.$tilde$greater$$anonfun$$u2219$1.apply(TypeFunctions.scala:40) at sbt.std.Transform$$anon$4.work(System.scala:63) at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:228) at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:228) at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:17) at sbt.Execute.work(Execute.scala:237) at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:228) at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:228) at sbt.ConcurrentRestrictions$$anon$4$$anonfun$1.apply(ConcurrentRestrictions.scala:159) at sbt.CompletionService$$anon$2.call(CompletionService.scala:28) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:515) at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264) at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1128) at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628) at java.base/java.lang.Thread.run(Thread.java:835) ``` ```
用idea+sbt构建scala项目是出现的问题
用idea+sbt,创建一个scala项目,然后idea的控制台直接报错,如下图所示: ![图片说明](https://img-ask.csdn.net/upload/201711/25/1511581280_348398.png) 然后idea最后指出的log日志内容如下: ``` Error during sbt execution: java.lang.RuntimeException: Expected one of local, maven-local, maven-central, scala-tools-releases, scala-tools-snapshots, sonatype-oss-releases, sonatype-oss-snapshots, jcenter, got 'local '. java.lang.RuntimeException: Expected one of local, maven-local, maven-central, scala-tools-releases, scala-tools-snapshots, sonatype-oss-releases, sonatype-oss-snapshots, jcenter, got 'local '. at xsbti.Predefined.toValue(Predefined.java:28) at xsbt.boot.Repository$Predefined$.apply(LaunchConfiguration.scala:114) at xsbt.boot.ConfigurationParser$$anonfun$getRepositories$1.apply(ConfigurationParser.scala:197) at xsbt.boot.ConfigurationParser$$anonfun$getRepositories$1.apply(ConfigurationParser.scala:196) at scala.collection.TraversableLike$$anonfun$map$1.apply(TraversableLike.scala:244) at scala.collection.immutable.List.foreach(List.scala:318) at org.apache.ivy.core.RelativeUrlResolver.map(RelativeUrlResolver.java:244) at scala.collection.AbstractTraversable.map(Traversable.scala:105) at xsbt.boot.ConfigurationParser.getRepositories(ConfigurationParser.scala:196) at xsbt.boot.ConfigurationParser$$anonfun$4.apply(ConfigurationParser.scala:71) at xsbt.boot.ConfigurationParser$$anonfun$processSection$1.apply(ConfigurationParser.scala:109) at xsbt.boot.ConfigurationParser.process(ConfigurationParser.scala:110) at xsbt.boot.ConfigurationParser.processSection(ConfigurationParser.scala:109) at xsbt.boot.ConfigurationParser.xsbt$boot$ConfigurationParser$$apply(ConfigurationParser.scala:49) at xsbt.boot.ConfigurationParser$$anonfun$apply$3.apply(ConfigurationParser.scala:47) at xsbt.boot.Using$.withResource(Using.scala:10) at xsbt.boot.Using$.apply(Using.scala:9) at xsbt.boot.Configuration$$anonfun$parse$1.apply(Configuration.scala:21) at xsbt.boot.Using$.withResource(Using.scala:10) at xsbt.boot.Using$.apply(Using.scala:9) at xsbt.boot.Configuration$.parse$fcb646c(Configuration.scala:21) at xsbt.boot.Launch$.apply(Launch.scala:18) at xsbt.boot.Boot$.runImpl(Boot.scala:41) at xsbt.boot.Boot$.main(Boot.scala:17) at xsbt.boot.Boot.main(Boot.scala) Java HotSpot(TM) 64-Bit Server VM warning: ignoring option MaxPermSize=512m; support was removed in 8.0 ``` 想请问,这是什么问题? 一创建sbt项目,就报这个错。
sbt assembly 报错,请大侠帮忙
> assembly [error] Not a valid command: assembly [error] Not a valid project ID: assembly [error] Expected ':' (if selecting a configuration) [error] Not a valid key: assembly [error] assembly [error]
使用spark自带的sbt编译工具打包失败
小菜目前刚学spark,安装spark的操作系统环境是ubuntu 12.0.4。安装的scala是scala-2.9.1.final.tgz。配置好环境变量后,通过git clone git://github.com/aparch/spark.git下载spark源代码后,执行命令sbt/sbt update complie,出现信息如下: NOTE: The sbt/sbt script has been relocated to build/sbt. Please update references to point to the new location. Invoking 'build/sbt update compile' now ... /root/spark/build/sbt-launch-lib.bash: line 84: java: command not found 查了半天不知道是什么原因,恳请各位大侠帮忙看看。
play framework问题,请各位高手帮帮忙
PS D:\IDEA\svn\Rock\talkWeb> .\activator clean stage [info] Loading project definition from D:\IDEA\svn\Rock\talkWeb\project [info] Set current project to talkWeb (in build file:/D:/IDEA/svn/Rock/talkWeb/) [success] Total time: 0 s, completed 2017-4-11 14:38:44 [info] Packaging D:\IDEA\svn\Rock\talkWeb\target\scala-2.11\talkweb_2.11-1.0-SNAPSHOT-sources.jar ... [info] Done packaging. [info] Updating {file:/D:/IDEA/svn/Rock/talkWeb/}root... [info] Resolving org.apache.ws.commons#XmlSchema;1.1 ... [error] public: bad revision found in https://repo1.maven.org/maven2/org/apache/ws/commons/XmlSchema/1.1/XmlSchema-1.1.pom: expected='1.1 found='SNAPSHOT' [info] Resolving jline#jline;2.12.1 ... [warn] [FAILED ] javax.resource#connector;1.0!connector.jar: (0ms) [warn] ==== local: tried [warn] C:\Users\talk\.ivy2\local\javax.resource\connector\1.0\jars\connector.jar [warn] ==== activator-launcher-local: tried [warn] D:\IDEA\svn\Rock\talkWeb\repository\javax.resource\connector\1.0\jars\connector.jar [warn] ==== public: tried [warn] https://repo1.maven.org/maven2/javax/resource/connector/1.0/connector-1.0.jar [warn] ==== typesafe-releases: tried [warn] https://repo.typesafe.com/typesafe/releases/javax/resource/connector/1.0/connector-1.0.jar [warn] ==== typesafe-ivy-releasez: tried [warn] https://repo.typesafe.com/typesafe/ivy-releases/javax.resource/connector/1.0/jars/connector.jar [warn] :::::::::::::::::::::::::::::::::::::::::::::: [warn] :: UNRESOLVED DEPENDENCIES :: [warn] :::::::::::::::::::::::::::::::::::::::::::::: [warn] :: org.apache.ws.commons#XmlSchema;1.1: java.text.ParseException: inconsistent module descriptor file found in 'https://repo1.maven.org/maven2/org/apache/ws/commons/XmlSchema/1.1/XmlSchema-1.1.pom': bad revision: expected='1.1' found='SNAPSHOT'; [warn] :::::::::::::::::::::::::::::::::::::::::::::: [warn] :::::::::::::::::::::::::::::::::::::::::::::: [warn] :: FAILED DOWNLOADS :: [warn] :: ^ see resolution messages for details ^ :: [warn] :::::::::::::::::::::::::::::::::::::::::::::: [warn] :: javax.resource#connector;1.0!connector.jar [warn] :::::::::::::::::::::::::::::::::::::::::::::: [warn] [warn] Note: Unresolved dependencies path: [warn] org.apache.ws.commons:XmlSchema:1.1 [warn] +- org.codehaus.xfire:xfire-core:1.2.6 [warn] +- org.codehaus.xfire:xfire-aegis:1.2.6 [warn] +- org.codehaus.xfire:xfire-annotations:1.2.6 [warn] +- org.codehaus.xfire:xfire-java5:1.2.6 [warn] +- org.codehaus.xfire:xfire-jaxb2:1.2.6 [warn] +- org.codehaus.xfire:xfire-generator:1.2.6 [warn] +- org.codehaus.xfire:xfire-jaxws:1.2.6 [warn] +- org.codehaus.xfire:xfire-all:1.2.+ (D:\IDEA\svn\Rock\talkWeb\build.sbt#L9-27) [warn] +- talkweb:talkweb_2.11:1.0-SNAPSHOT [info] Wrote D:\IDEA\svn\Rock\talkWeb\target\scala-2.11\talkweb_2.11-1.0-SNAPSHOT.pom sbt.ResolveException: unresolved dependency: org.apache.ws.commons#XmlSchema;1.1: java.text.ParseException: inconsistent module descriptor file found in 'https://repo1.maven.org/maven2/org/apache/ws/commons/XmlSchema/1.1/XmlSchema-1.1.pom': bad revision: expected='1.1' found='SNAPSHOT'; download failed: javax.resource#connector;1.0!connector.jar at sbt.IvyActions$.sbt$IvyActions$$resolve(IvyActions.scala:291) at sbt.IvyActions$$anonfun$updateEither$1.apply(IvyActions.scala:188) at sbt.IvyActions$$anonfun$updateEither$1.apply(IvyActions.scala:165) at sbt.IvySbt$Module$$anonfun$withModule$1.apply(Ivy.scala:155) at sbt.IvySbt$Module$$anonfun$withModule$1.apply(Ivy.scala:155) at sbt.IvySbt$$anonfun$withIvy$1.apply(Ivy.scala:132) at sbt.IvySbt.sbt$IvySbt$$action$1(Ivy.scala:57) at sbt.IvySbt$$anon$4.call(Ivy.scala:65) at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:93) at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:78) at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:97) at xsbt.boot.Using$.withResource(Using.scala:10) at xsbt.boot.Using$.apply(Using.scala:9) at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:58) at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:48) at xsbt.boot.Locks$.apply0(Locks.scala:31) at xsbt.boot.Locks$.apply(Locks.scala:28) at sbt.IvySbt.withDefaultLogger(Ivy.scala:65) at sbt.IvySbt.withIvy(Ivy.scala:127) at sbt.IvySbt.withIvy(Ivy.scala:124) at sbt.IvySbt$Module.withModule(Ivy.scala:155) at sbt.IvyActions$.updateEither(IvyActions.scala:165) at sbt.Classpaths$$anonfun$sbt$Classpaths$$work$1$1.apply(Defaults.scala:1369) at sbt.Classpaths$$anonfun$sbt$Classpaths$$work$1$1.apply(Defaults.scala:1365) at sbt.Classpaths$$anonfun$doWork$1$1$$anonfun$87.apply(Defaults.scala:1399) at sbt.Classpaths$$anonfun$doWork$1$1$$anonfun$87.apply(Defaults.scala:1397) at sbt.Tracked$$anonfun$lastOutput$1.apply(Tracked.scala:37) at sbt.Classpaths$$anonfun$doWork$1$1.apply(Defaults.scala:1402) at sbt.Classpaths$$anonfun$doWork$1$1.apply(Defaults.scala:1396) at sbt.Tracked$$anonfun$inputChanged$1.apply(Tracked.scala:60) at sbt.Classpaths$.cachedUpdate(Defaults.scala:1419) at sbt.Classpaths$$anonfun$updateTask$1.apply(Defaults.scala:1348) at sbt.Classpaths$$anonfun$updateTask$1.apply(Defaults.scala:1310) at scala.Function1$$anonfun$compose$1.apply(Function1.scala:47) at sbt.$tilde$greater$$anonfun$$u2219$1.apply(TypeFunctions.scala:40) at sbt.std.Transform$$anon$4.work(System.scala:63) at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:226) at sbt.Execute$$anonfun$submit$1$$anonfun$apply$1.apply(Execute.scala:226) at sbt.ErrorHandling$.wideConvert(ErrorHandling.scala:17) at sbt.Execute.work(Execute.scala:235) at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:226) at sbt.Execute$$anonfun$submit$1.apply(Execute.scala:226) at sbt.ConcurrentRestrictions$$anon$4$$anonfun$1.apply(ConcurrentRestrictions.scala:159) at sbt.CompletionService$$anon$2.call(CompletionService.scala:28) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511) at java.util.concurrent.FutureTask.run(FutureTask.java:266) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at java.lang.Thread.run(Thread.java:745) [error] (*:update) sbt.ResolveException: unresolved dependency: org.apache.ws.commons#XmlSchema;1.1: java.text.ParseException: inconsistent module descriptor file found in 'https://repo1.maven.org/maven2/org/apache/ws/commons/XmlSchema/1.1/XmlSchema-1.1.pom': bad revision: expected='1.1' found='SNAPSHOT'; [error] download failed: javax.resource#connector;1.0!connector.jar [error] Total time: 22 s, completed 2017-4-11 14:39:06
Jar在spark-shell上运行报错:主类找不到
scala IntelliJ的项目,sbt打好包在spark-shell上运行后报错:主类找不到;使用了两个中文分词包(ansj_seg-2.0.8.jar,nlp-lang-0.3.jar),但是已经加入到 External libraries里去了;打包没问题,运行报错 ![![图片说明](https://img-ask.csdn.net/upload/201601/26/1453780626_723163.jpg)![图片说明](https://img-ask.csdn.net/upload/201601/26/1453780648_659305.jpg) spark-shell 提交命令: [gaohui@hadoop-1-2 test]$ spark-submit --master yarn --driver-memory 5G --num-executors 20 --executor-cores 16 --executor-memory 10G --conf spark.serializer=org.apache.spark.serializer.KryoSerializer --class NLP_V6.Nlp_test --jars /home/gaohui/test/NLP_v6_test.jar /home/gaohui/test/NLP_v6_test.jar 报错图片: ![图片说明](https://img-ask.csdn.net/upload/201601/26/1453780776_603750.jpg)
一个简单的统计字母行号的代码打包后使用spark-submit提交会报错
主函数源码如下: ![图片说明](https://img-ask.csdn.net/upload/201612/17/1481978873_100458.png) 使用sbt compile和sbt package进行打包,过程如下: ![图片说明](https://img-ask.csdn.net/upload/201612/17/1481978939_871343.png) 使用spark-submit提交,出现报错如下图: ![图片说明](https://img-ask.csdn.net/upload/201612/17/1481978973_973617.png) 这个该怎么解决?
intellij idea修改scal代码再次运行就报错
Error:scalac: Error: Could not find an output directory for D:\IdeaProjects\scala\src\main\scala\Scala.scala in List((d:\IdeaProjects\scala\target\scala-2.11\resource_managed\test,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\test\resources,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\target\scala-2.11\resource_managed\main,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\main\resources,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\target\scala-2.11\src_managed\test,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\test\scala-2.11,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\test\scala,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\test\java,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\target\scala-2.11\src_managed\main,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\main\scala-2.11,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\main\scala,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\main\java,d:\IdeaProjects\scala\target\scala-2.11\classes)) scala.reflect.internal.FatalError: Could not find an output directory for D:\IdeaProjects\scala\src\main\scala\Scala.scala in List((d:\IdeaProjects\scala\target\scala-2.11\resource_managed\test,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\test\resources,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\target\scala-2.11\resource_managed\main,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\main\resources,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\target\scala-2.11\src_managed\test,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\test\scala-2.11,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\test\scala,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\test\java,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\target\scala-2.11\src_managed\main,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\main\scala-2.11,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\main\scala,d:\IdeaProjects\scala\target\scala-2.11\classes), (d:\IdeaProjects\scala\src\main\java,d:\IdeaProjects\scala\target\scala-2.11\classes)) at scala.tools.nsc.settings.MutableSettings$OutputDirs.outputDirFor(MutableSettings.scala:311) at scala.tools.nsc.backend.jvm.BytecodeWriters$class.outputDirectory(BytecodeWriters.scala:26) at scala.tools.nsc.backend.jvm.GenASM.outputDirectory(GenASM.scala:23) at scala.tools.nsc.backend.jvm.BytecodeWriters$class.getFile(BytecodeWriters.scala:41) at scala.tools.nsc.backend.jvm.GenASM.getFile(GenASM.scala:23) at scala.tools.nsc.backend.jvm.GenASM$JBuilder.writeIfNotTooBig(GenASM.scala:531) at scala.tools.nsc.backend.jvm.GenASM$JMirrorBuilder.genMirrorClass(GenASM.scala:2835) at scala.tools.nsc.backend.jvm.GenASM$AsmPhase.emitFor$1(GenASM.scala:193) at scala.tools.nsc.backend.jvm.GenASM$AsmPhase.run(GenASM.scala:203) at scala.tools.nsc.Global$Run.compileUnitsInternal(Global.scala:1500) at scala.tools.nsc.Global$Run.compileUnits(Global.scala:1487) at scala.tools.nsc.Global$Run.compileSources(Global.scala:1482) at scala.tools.nsc.Global$Run.compile(Global.scala:1580) at xsbt.CachedCompiler0.run(CompilerInterface.scala:126) at xsbt.CachedCompiler0.run(CompilerInterface.scala:102) at xsbt.CompilerInterface.run(CompilerInterface.scala:27) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at sbt.compiler.AnalyzingCompiler.call(AnalyzingCompiler.scala:102) at sbt.compiler.AnalyzingCompiler.compile(AnalyzingCompiler.scala:48) at sbt.compiler.AnalyzingCompiler.compile(AnalyzingCompiler.scala:41) at org.jetbrains.jps.incremental.scala.local.IdeaIncrementalCompiler.compile(IdeaIncrementalCompiler.scala:29) at org.jetbrains.jps.incremental.scala.local.LocalServer.compile(LocalServer.scala:26) at org.jetbrains.jps.incremental.scala.remote.Main$.make(Main.scala:62) at org.jetbrains.jps.incremental.scala.remote.Main$.nailMain(Main.scala:20) at org.jetbrains.jps.incremental.scala.remote.Main.nailMain(Main.scala) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:606) at com.martiansoftware.nailgun.NGSession.run(NGSession.java:319) Information:2015/4/24 10:39 - Compilation completed with 1 error and 0 warnings in 600ms
scala ide for eclipse搭建spark源码阅读环境报错
git bash下载spark源码 sbt eclipse 以existing maven project导入scala ide for eclipse报了scala version、project依赖missing等错误,还剩not found:type EventBatch无法解决 在eclipse里update project,错误会消失,但每次build错误就又会出现,导致一直无法build success。。。。。。 请教大神报错原因及如何解决!!!
spark程序使用scalac先编译再使用scala运行和打成jar包使用spark-submit提交运行有什么区别?
第一种方式:先使用scalac命令 编译,再使用scala命令运行 第二种方式:先使用sbt打包,然后再使用spark-submit提交运行spark 这两种方式有什么区别?各有什么优劣势?先谢谢大家了 ~
IDEA 2018.2 使用gradle 构建, java + scala 的项目, 编译不通过,无法运行
**下面是编译异常的日志:** ``` org.gradle.api.tasks.TaskExecutionException: Execution failed for task ':common:compileScala'. at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions(ExecuteActionsTaskExecuter.java:103) at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute(ExecuteActionsTaskExecuter.java:73) at org.gradle.api.internal.tasks.execution.OutputDirectoryCreatingTaskExecuter.execute(OutputDirectoryCreatingTaskExecuter.java:51) at org.gradle.api.internal.tasks.execution.SkipUpToDateTaskExecuter.execute(SkipUpToDateTaskExecuter.java:59) at org.gradle.api.internal.tasks.execution.ResolveTaskOutputCachingStateExecuter.execute(ResolveTaskOutputCachingStateExecuter.java:54) at org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute(ValidatingTaskExecuter.java:59) at org.gradle.api.internal.tasks.execution.SkipEmptySourceFilesTaskExecuter.execute(SkipEmptySourceFilesTaskExecuter.java:101) at org.gradle.api.internal.tasks.execution.FinalizeInputFilePropertiesTaskExecuter.execute(FinalizeInputFilePropertiesTaskExecuter.java:44) at org.gradle.api.internal.tasks.execution.CleanupStaleOutputsExecuter.execute(CleanupStaleOutputsExecuter.java:91) at org.gradle.api.internal.tasks.execution.ResolveTaskArtifactStateTaskExecuter.execute(ResolveTaskArtifactStateTaskExecuter.java:62) at org.gradle.api.internal.tasks.execution.SkipTaskWithNoActionsExecuter.execute(SkipTaskWithNoActionsExecuter.java:59) at org.gradle.api.internal.tasks.execution.SkipOnlyIfTaskExecuter.execute(SkipOnlyIfTaskExecuter.java:54) at org.gradle.api.internal.tasks.execution.ExecuteAtMostOnceTaskExecuter.execute(ExecuteAtMostOnceTaskExecuter.java:43) at org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute(CatchExceptionTaskExecuter.java:34) at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker$1.run(DefaultTaskGraphExecuter.java:256) at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:336) at org.gradle.internal.progress.DefaultBuildOperationExecutor$RunnableBuildOperationWorker.execute(DefaultBuildOperationExecutor.java:328) at org.gradle.internal.progress.DefaultBuildOperationExecutor.execute(DefaultBuildOperationExecutor.java:199) at org.gradle.internal.progress.DefaultBuildOperationExecutor.run(DefaultBuildOperationExecutor.java:110) at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:249) at org.gradle.execution.taskgraph.DefaultTaskGraphExecuter$EventFiringTaskWorker.execute(DefaultTaskGraphExecuter.java:238) at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker.processTask(DefaultTaskPlanExecutor.java:123) at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker.access$200(DefaultTaskPlanExecutor.java:79) at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker$1.execute(DefaultTaskPlanExecutor.java:104) at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker$1.execute(DefaultTaskPlanExecutor.java:98) at org.gradle.execution.taskgraph.DefaultTaskExecutionPlan.execute(DefaultTaskExecutionPlan.java:663) at org.gradle.execution.taskgraph.DefaultTaskExecutionPlan.executeWithTask(DefaultTaskExecutionPlan.java:597) at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor$TaskExecutorWorker.run(DefaultTaskPlanExecutor.java:98) at org.gradle.internal.concurrent.ExecutorPolicy$CatchAndRecordFailures.onExecute(ExecutorPolicy.java:63) at org.gradle.internal.concurrent.ManagedExecutorImpl$1.run(ManagedExecutorImpl.java:46) at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142) at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617) at org.gradle.internal.concurrent.ThreadFactoryImpl$ManagedThreadRunnable.run(ThreadFactoryImpl.java:55) at java.lang.Thread.run(Thread.java:745) Caused by: org.gradle.api.internal.tasks.compile.CompilationFailedException: javac returned nonzero exit code at org.gradle.api.internal.tasks.scala.ZincScalaCompiler$Compiler.execute(ZincScalaCompiler.java:83) at org.gradle.api.internal.tasks.scala.ZincScalaCompiler.execute(ZincScalaCompiler.java:52) at org.gradle.api.internal.tasks.scala.ZincScalaCompiler.execute(ZincScalaCompiler.java:38) at org.gradle.api.internal.tasks.compile.daemon.AbstractDaemonCompiler$CompilerRunnable.run(AbstractDaemonCompiler.java:87) at org.gradle.workers.internal.DefaultWorkerServer.execute(DefaultWorkerServer.java:36) at org.gradle.workers.internal.WorkerDaemonServer.execute(WorkerDaemonServer.java:46) at org.gradle.workers.internal.WorkerDaemonServer.execute(WorkerDaemonServer.java:30) 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:497) at org.gradle.process.internal.worker.request.WorkerAction.run(WorkerAction.java:100) 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:497) at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:35) at org.gradle.internal.dispatch.ReflectionDispatch.dispatch(ReflectionDispatch.java:24) at org.gradle.internal.remote.internal.hub.MessageHubBackedObjectConnection$DispatchWrapper.dispatch(MessageHubBackedObjectConnection.java:146) at org.gradle.internal.remote.internal.hub.MessageHubBackedObjectConnection$DispatchWrapper.dispatch(MessageHubBackedObjectConnection.java:128) at org.gradle.internal.remote.internal.hub.MessageHub$Handler.run(MessageHub.java:404) ... 6 more Caused by: javac returned nonzero exit code at sbt.compiler.JavaCompiler$JavaTool0.compile(JavaCompiler.scala:97) at sbt.compiler.JavaTool$class.apply(JavaCompiler.scala:54) at sbt.compiler.JavaCompiler$JavaTool0.apply(JavaCompiler.scala:84) at sbt.compiler.JavaCompiler$class.compile(JavaCompiler.scala:35) at sbt.compiler.JavaCompiler$JavaTool0.compile(JavaCompiler.scala:84) at sbt.compiler.JavaCompiler$class.compileWithReporter(JavaCompiler.scala:40) at sbt.compiler.JavaCompiler$JavaTool0.compileWithReporter(JavaCompiler.scala:84) at sbt.compiler.AggressiveCompile$$anonfun$3$$anonfun$compileJava$1$1.apply$mcV$sp(AggressiveCompile.scala:121) at sbt.compiler.AggressiveCompile$$anonfun$3$$anonfun$compileJava$1$1.apply(AggressiveCompile.scala:121) at sbt.compiler.AggressiveCompile$$anonfun$3$$anonfun$compileJava$1$1.apply(AggressiveCompile.scala:121) at sbt.compiler.AggressiveCompile.sbt$compiler$AggressiveCompile$$timed(AggressiveCompile.scala:168) at sbt.compiler.AggressiveCompile$$anonfun$3.compileJava$1(AggressiveCompile.scala:120) at sbt.compiler.AggressiveCompile$$anonfun$3.apply(AggressiveCompile.scala:142) at sbt.compiler.AggressiveCompile$$anonfun$3.apply(AggressiveCompile.scala:84) at sbt.inc.IncrementalCompile$$anonfun$doCompile$1.apply(Compile.scala:66) at sbt.inc.IncrementalCompile$$anonfun$doCompile$1.apply(Compile.scala:64) at sbt.inc.IncrementalCommon.cycle(IncrementalCommon.scala:32) at sbt.inc.Incremental$$anonfun$1.apply(Incremental.scala:72) at sbt.inc.Incremental$$anonfun$1.apply(Incremental.scala:71) at sbt.inc.Incremental$.manageClassfiles(Incremental.scala:99) at sbt.inc.Incremental$.compile(Incremental.scala:71) at sbt.inc.IncrementalCompile$.apply(Compile.scala:54) at sbt.compiler.AggressiveCompile.compile2(AggressiveCompile.scala:159) at sbt.compiler.AggressiveCompile.compile1(AggressiveCompile.scala:68) at com.typesafe.zinc.Compiler.compile(Compiler.scala:207) at com.typesafe.zinc.Compiler.compile(Compiler.scala:189) at com.typesafe.zinc.Compiler.compile(Compiler.scala:180) at com.typesafe.zinc.Compiler.compile(Compiler.scala:171) at org.gradle.api.internal.tasks.scala.ZincScalaCompiler$Compiler.execute(ZincScalaCompiler.java:81) ... 26 more ``` IDEA 的 scala 插件版本 2018.2.11 gradle 版本:5.1 JDK 版本 1.8.0_45 scala 依赖的版本 2.11.8
sbt启动出错,求解决。
安装了sbt,当运行时出现下列错误,有谁知道如何解决 [root@Spark ~]# sbt sbt-version java.lang.NoClassDefFoundError: scala/reflect/internal/Trees at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:763) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:467) at java.net.URLClassLoader.access$100(URLClassLoader.java:73) at java.net.URLClassLoader$1.run(URLClassLoader.java:368) at java.net.URLClassLoader$1.run(URLClassLoader.java:362) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:361) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at java.lang.ClassLoader.defineClass1(Native Method) at java.lang.ClassLoader.defineClass(ClassLoader.java:763) at java.security.SecureClassLoader.defineClass(SecureClassLoader.java:142) at java.net.URLClassLoader.defineClass(URLClassLoader.java:467) at java.net.URLClassLoader.access$100(URLClassLoader.java:73) at java.net.URLClassLoader$1.run(URLClassLoader.java:368) at java.net.URLClassLoader$1.run(URLClassLoader.java:362) at java.security.AccessController.doPrivileged(Native Method) at java.net.URLClassLoader.findClass(URLClassLoader.java:361) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) at java.lang.Class.forName0(Native Method) at java.lang.Class.forName(Class.java:348) at xsbt.boot.Pre$.xsbt$boot$Pre$$classMissing$1(Pre.scala:66) at xsbt.boot.Pre$$anonfun$getMissing$1.apply(Pre.scala:67) at scala.collection.TraversableLike$$anonfun$filter$1.apply(TraversableLike.scala:264) at scala.collection.immutable.List.foreach(List.scala:318) at org.apache.ivy.core.RelativeUrlResolver.filter(RelativeUrlResolver.java:263) at scala.collection.AbstractTraversable.filter(Traversable.scala:105) at xsbt.boot.Pre$.getMissing$d83f809$3a8a6f87(Pre.scala:67) at xsbt.boot.Launch.checkLoader$2accd70c(Launch.scala:185) at xsbt.boot.Launch.xsbt$boot$Launch$$provider$1(Launch.scala:249) at xsbt.boot.Launch$$anonfun$xsbt$boot$Launch$$getScalaProvider0$2.apply(Launch.scala:252) at xsbt.boot.Launch$$anonfun$xsbt$boot$Launch$$getScalaProvider0$2.apply(Launch.scala:251) at scala.Option.flatMap(Option.scala:170) at xsbt.boot.Launch.xsbt$boot$Launch$$getScalaProvider0(Launch.scala:251) at xsbt.boot.Launch$$anon$3.call(Launch.scala:240) at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:45) at xsbt.boot.Locks$.apply0(Locks.scala:31) at xsbt.boot.Locks$.apply(Locks.scala:28) at xsbt.boot.Launch.locked(Launch.scala:238) at xsbt.boot.Launch.getScalaProvider(Launch.scala:240) at xsbt.boot.Launch$$anonfun$1.apply(Launch.scala:141) at xsbt.boot.Cache.newEntry(Cache.scala:16) at xsbt.boot.Cache.apply(Cache.scala:11) at xsbt.boot.Launch.getScala(Launch.scala:144) at xsbt.boot.Launch.getScala(Launch.scala:143) at xsbt.boot.Launch.xsbt$boot$Launch$$getAppProvider0(Launch.scala:219) at xsbt.boot.Launch$$anon$2.call(Launch.scala:196) at xsbt.boot.Locks$GlobalLock.withChannel$1(Locks.scala:93) at xsbt.boot.Locks$GlobalLock.xsbt$boot$Locks$GlobalLock$$withChannelRetries$1(Locks.scala:78) at xsbt.boot.Locks$GlobalLock$$anonfun$withFileLock$1.apply(Locks.scala:97) at xsbt.boot.Using$.withResource(Using.scala:10) at xsbt.boot.Using$.apply(Using.scala:9) at xsbt.boot.Locks$GlobalLock.ignoringDeadlockAvoided(Locks.scala:58) at xsbt.boot.Locks$GlobalLock.withLock(Locks.scala:48) at xsbt.boot.Locks$.apply0(Locks.scala:31) at xsbt.boot.Locks$.apply(Locks.scala:28) at xsbt.boot.Launch.locked(Launch.scala:238) at xsbt.boot.Launch.app(Launch.scala:147) at xsbt.boot.Launch.app(Launch.scala:145) at xsbt.boot.Launch$.run(Launch.scala:102) at xsbt.boot.Launch$$anonfun$apply$1.apply(Launch.scala:35) at xsbt.boot.Launch$.launch(Launch.scala:117) at xsbt.boot.Launch$.apply(Launch.scala:18) at xsbt.boot.Boot$.runImpl(Boot.scala:41) at xsbt.boot.Boot$.main(Boot.scala:17) at xsbt.boot.Boot.main(Boot.scala) Caused by: java.lang.ClassNotFoundException: scala.reflect.internal.Trees at java.net.URLClassLoader.findClass(URLClassLoader.java:381) at java.lang.ClassLoader.loadClass(ClassLoader.java:424) at java.lang.ClassLoader.loadClass(ClassLoader.java:357) ... 69 more Error during sbt execution: java.lang.NoClassDefFoundError: scala/reflect/internal/Trees
intellij创建scala项目没有scala选项
为什么我新建scala那一步,在new project里面左侧选择scala,右侧就是没有scala的选项呢,只有SBT\Activator\IDEA这三个选项 ![图片说明](https://img-ask.csdn.net/upload/201709/25/1506321594_567550.jpg)
求助大神Scala独立应用编程sbt安装问题?
sbt-version验证一直出现java:未找到命令或者Java:not found,sbt文本文件内容是 SBT_OPTS="-Xms512M -Xmx1536M -Xss1M -XX:+CMSClassUnloadingEnabled -XX:MaxPermSize=256M" java $SBT_OPTS -jar `dirname $0`/sbt-launch.jar "$@"
Java:带有package的代码如何访问不带package的class?
我有一些C++源代码,通过CMake+SWIG的方式生成了Java代码接口,但是CMake没有相关的命令指定把生成的Java代码放在某个package里。所以生成的代码都如下所示没有package: ``` /* ---------------------------------------------------------------------------- * This file was automatically generated by SWIG (http://www.swig.org). * Version 4.0.0 * * Do not make changes to this file unless you know what you are doing--modify * the SWIG interface file instead. * ----------------------------------------------------------------------------- */ public class Posit_32_2_t { private transient long swigCPtr; protected transient boolean swigCMemOwn; protected Posit_32_2_t(long cPtr, boolean cMemoryOwn) { swigCMemOwn = cMemoryOwn; swigCPtr = cPtr; } ...... ``` 现在我要在Scala代码里调用这些Java类,可是如果我的Scala声明了package,那么sbt编译的时候就报错说找不到SWIG生成的Java。如果不加package,那么Scala代码又无法区分。这要如何解决?
Hive on Spark下无法处理Parquet表
我在使用Hive on Spark时,在搭建过程中不段踩坑,网上资料也有,但都是千篇一律,点到为止,欲言又止,明明在说却又故意不说清楚的那种,看着让人很蛋疼. 过程是这样的,我在Spark的官网查到,要使用Hive on Spark必须有一个不包含一个Hive的Spark部署包,而官网上的都是带Hive的,那么就只剩一个办法了,自己编译 编译的方法有很多种,官方只要介绍有三种,一种是Spark自带的make-distribution.sh编译工具,第二种是使用Maven编译,第三那种是使用SBT去编译,我一开始选择了Spark自带的make-distribution.sh编译工具,编译过程是令人发疯的,不断报错,不断报错,最后还是让我编译成功了,我的方法是,报错了,重新指令指令编译,不断重复次步骤. 我在用make-distribution.sh编译工具时的指令如下: ./make-distribution.sh --name "hadoop2-without-hive" --tgz "-Pyarn,hadoop-provided,hadoop-2.6,parquet-provided" 但是编译出来的spark-assembly-*.jar 包只有106M,然后安装部署spark后,却连启动都报错,我就去上网找资料,但是在网上找的资料是,有人通过make-distribution.sh编译工具编译,但是他竟然成功了,完全没报错?????有人也是通过make-distribution.sh编译工具编译的,结果跟我一样,也是报错,他后来才用Maven编译,成功了,没办法,我通过make-distribution.sh编译不成功只能也用Maven编译,后来确实也编译成功了,安装,运行一点问题都没有,我用Maven编译的指令如下: mvn -Phadoop-2.6 -Pyarn -Dhadoop.version=2.6.5 -Dyarn.version=2.6.5 -Dscala-2.10 -DskipTests clean package 当我以为一切都搞定了的时候,问题又来了,因为我需要用到将Hive中的数据以parquet格式进行存储,到了这时它又报错了,报错信息如下: Caused by: java.io.IOException: java.lang.reflect.InvocationTargetException Caused by: java.lang.reflect.InvocationTargetException Caused by: java.lang.NoSuchMethodError:org.apache.parquet.schema.Types$MessageTypeBuilder.addFields([Lorg/apache/parquet/schema/Type;)Lorg/apache/parquet/schema/Types$BaseGroupBuilder; 然后我就去找资料,百度,Google,Bing都找过了,愣是没找到问题在哪里,我就懵逼了,到底这个问题怎么解决啊? 求前辈赐教
相见恨晚的超实用网站
搞学习 知乎:www.zhihu.com 简答题:http://www.jiandati.com/ 网易公开课:https://open.163.com/ted/ 网易云课堂:https://study.163.com/ 中国大学MOOC:www.icourse163.org 网易云课堂:study.163.com 哔哩哔哩弹幕网:www.bilibili.com 我要自学网:www.51zxw
花了20分钟,给女朋友们写了一个web版群聊程序
参考博客 [1]https://www.byteslounge.com/tutorials/java-ee-html5-websocket-example
爬虫福利二 之 妹子图网MM批量下载
爬虫福利一:27报网MM批量下载    点击 看了本文,相信大家对爬虫一定会产生强烈的兴趣,激励自己去学习爬虫,在这里提前祝:大家学有所成! 目标网站:妹子图网 环境:Python3.x 相关第三方模块:requests、beautifulsoup4 Re:各位在测试时只需要将代码里的变量 path 指定为你当前系统要保存的路径,使用 python xxx.py 或IDE运行即可。
字节跳动视频编解码面经
引言 本文主要是记录一下面试字节跳动的经历。 三四月份投了字节跳动的实习(图形图像岗位),然后hr打电话过来问了一下会不会opengl,c++,shador,当时只会一点c++,其他两个都不会,也就直接被拒了。 七月初内推了字节跳动的提前批,因为内推没有具体的岗位,hr又打电话问要不要考虑一下图形图像岗,我说实习投过这个岗位不合适,不会opengl和shador,然后hr就说秋招更看重基础。我当时
Java学习的正确打开方式
在博主认为,对于入门级学习java的最佳学习方法莫过于视频+博客+书籍+总结,前三者博主将淋漓尽致地挥毫于这篇博客文章中,至于总结在于个人,实际上越到后面你会发现学习的最好方式就是阅读参考官方文档其次就是国内的书籍,博客次之,这又是一个层次了,这里暂时不提后面再谈。博主将为各位入门java保驾护航,各位只管冲鸭!!!上天是公平的,只要不辜负时间,时间自然不会辜负你。 何谓学习?博主所理解的学习,它
程序员必须掌握的核心算法有哪些?
由于我之前一直强调数据结构以及算法学习的重要性,所以就有一些读者经常问我,数据结构与算法应该要学习到哪个程度呢?,说实话,这个问题我不知道要怎么回答你,主要取决于你想学习到哪些程度,不过针对这个问题,我稍微总结一下我学过的算法知识点,以及我觉得值得学习的算法。这些算法与数据结构的学习大多数是零散的,并没有一本把他们全部覆盖的书籍。下面是我觉得值得学习的一些算法以及数据结构,当然,我也会整理一些看过
大学四年自学走来,这些私藏的实用工具/学习网站我贡献出来了
大学四年,看课本是不可能一直看课本的了,对于学习,特别是自学,善于搜索网上的一些资源来辅助,还是非常有必要的,下面我就把这几年私藏的各种资源,网站贡献出来给你们。主要有:电子书搜索、实用工具、在线视频学习网站、非视频学习网站、软件下载、面试/求职必备网站。 注意:文中提到的所有资源,文末我都给你整理好了,你们只管拿去,如果觉得不错,转发、分享就是最大的支持了。 一、电子书搜索 对于大部分程序员...
linux系列之常用运维命令整理笔录
本博客记录工作中需要的linux运维命令,大学时候开始接触linux,会一些基本操作,可是都没有整理起来,加上是做开发,不做运维,有些命令忘记了,所以现在整理成博客,当然vi,文件操作等就不介绍了,慢慢积累一些其它拓展的命令,博客不定时更新 顺便拉下票,我在参加csdn博客之星竞选,欢迎投票支持,每个QQ或者微信每天都可以投5票,扫二维码即可,http://m234140.nofollow.ax.
比特币原理详解
一、什么是比特币 比特币是一种电子货币,是一种基于密码学的货币,在2008年11月1日由中本聪发表比特币白皮书,文中提出了一种去中心化的电子记账系统,我们平时的电子现金是银行来记账,因为银行的背后是国家信用。去中心化电子记账系统是参与者共同记账。比特币可以防止主权危机、信用风险。其好处不多做赘述,这一层面介绍的文章很多,本文主要从更深层的技术原理角度进行介绍。 二、问题引入 假设现有4个人...
Python 基础(一):入门必备知识
目录1 标识符2 关键字3 引号4 编码5 输入输出6 缩进7 多行8 注释9 数据类型10 运算符10.1 常用运算符10.2 运算符优先级 1 标识符 标识符是编程时使用的名字,用于给变量、函数、语句块等命名,Python 中标识符由字母、数字、下划线组成,不能以数字开头,区分大小写。 以下划线开头的标识符有特殊含义,单下划线开头的标识符,如:_xxx ,表示不能直接访问的类属性,需通过类提供
这30个CSS选择器,你必须熟记(上)
关注前端达人,与你共同进步CSS的魅力就是让我们前端工程师像设计师一样进行网页的设计,我们能轻而易举的改变颜色、布局、制作出漂亮的影音效果等等,我们只需要改几行代码,不需...
国产开源API网关项目进入Apache孵化器:APISIX
点击蓝色“程序猿DD”关注我回复“资源”获取独家整理的学习资料!近日,又有一个开源项目加入了这个Java开源界大名鼎鼎的Apache基金会,开始进行孵化器。项目名称:AP...
程序员接私活怎样防止做完了不给钱?
首先跟大家说明一点,我们做 IT 类的外包开发,是非标品开发,所以很有可能在开发过程中会有这样那样的需求修改,而这种需求修改很容易造成扯皮,进而影响到费用支付,甚至出现做完了项目收不到钱的情况。 那么,怎么保证自己的薪酬安全呢? 我们在开工前,一定要做好一些证据方面的准备(也就是“讨薪”的理论依据),这其中最重要的就是需求文档和验收标准。一定要让需求方提供这两个文档资料作为开发的基础。之后开发
网页实现一个简单的音乐播放器(大佬别看。(⊙﹏⊙))
今天闲着无事,就想写点东西。然后听了下歌,就打算写个播放器。 于是乎用h5 audio的加上js简单的播放器完工了。 欢迎 改进 留言。 演示地点跳到演示地点 html代码如下`&lt;!DOCTYPE html&gt; &lt;html&gt; &lt;head&gt; &lt;title&gt;music&lt;/title&gt; &lt;meta charset="utf-8"&gt
Python十大装B语法
Python 是一种代表简单思想的语言,其语法相对简单,很容易上手。不过,如果就此小视 Python 语法的精妙和深邃,那就大错特错了。本文精心筛选了最能展现 Python 语法之精妙的十个知识点,并附上详细的实例代码。如能在实战中融会贯通、灵活使用,必将使代码更为精炼、高效,同时也会极大提升代码B格,使之看上去更老练,读起来更优雅。 1. for - else 什么?不是 if 和 else 才
数据库优化 - SQL优化
前面一篇文章从实例的角度进行数据库优化,通过配置一些参数让数据库性能达到最优。但是一些“不好”的SQL也会导致数据库查询变慢,影响业务流程。本文从SQL角度进行数据库优化,提升SQL运行效率。 判断问题SQL 判断SQL是否有问题时可以通过两个表象进行判断: 系统级别表象 CPU消耗严重 IO等待严重 页面响应时间过长
2019年11月中国大陆编程语言排行榜
2019年11月2日,我统计了某招聘网站,获得有效程序员招聘数据9万条。针对招聘信息,提取编程语言关键字,并统计如下: 编程语言比例 rank pl_ percentage 1 java 33.62% 2 c/c++ 16.42% 3 c_sharp 12.82% 4 javascript 12.31% 5 python 7.93% 6 go 7.25% 7
通俗易懂地给女朋友讲:线程池的内部原理
餐厅的约会 餐盘在灯光的照耀下格外晶莹洁白,女朋友拿起红酒杯轻轻地抿了一小口,对我说:“经常听你说线程池,到底线程池到底是个什么原理?”我楞了一下,心里想女朋友今天是怎么了,怎么突然问出这么专业的问题,但做为一个专业人士在女朋友面前也不能露怯啊,想了一下便说:“我先给你讲讲我前同事老王的故事吧!” 大龄程序员老王 老王是一个已经北漂十多年的程序员,岁数大了,加班加不动了,升迁也无望,于是拿着手里
经典算法(5)杨辉三角
杨辉三角 是经典算法,这篇博客对它的算法思想进行了讲解,并有完整的代码实现。
编写Spring MVC控制器的14个技巧
本期目录 1.使用@Controller构造型 2.实现控制器接口 3.扩展AbstractController类 4.为处理程序方法指定URL映射 5.为处理程序方法指定HTTP请求方法 6.将请求参数映射到处理程序方法 7.返回模型和视图 8.将对象放入模型 9.处理程序方法中的重定向 10.处理表格提交和表格验证 11.处理文件上传 12.在控制器中自动装配业务类 ...
腾讯算法面试题:64匹马8个跑道需要多少轮才能选出最快的四匹?
昨天,有网友私信我,说去阿里面试,彻底的被打击到了。问了为什么网上大量使用ThreadLocal的源码都会加上private static?他被难住了,因为他从来都没有考虑过这个问题。无独有偶,今天笔者又发现有网友吐槽了一道腾讯的面试题,我们一起来看看。 腾讯算法面试题:64匹马8个跑道需要多少轮才能选出最快的四匹? 在互联网职场论坛,一名程序员发帖求助到。二面腾讯,其中一个算法题:64匹
面试官:你连RESTful都不知道我怎么敢要你?
面试官:了解RESTful吗? 我:听说过。 面试官:那什么是RESTful? 我:就是用起来很规范,挺好的 面试官:是RESTful挺好的,还是自我感觉挺好的 我:都挺好的。 面试官:… 把门关上。 我:… 要干嘛?先关上再说。 面试官:我说出去把门关上。 我:what ?,夺门而去 文章目录01 前言02 RESTful的来源03 RESTful6大原则1. C-S架构2. 无状态3.统一的接
求小姐姐抠图竟遭白眼?痛定思痛,我决定用 Python 自力更生!
点击蓝色“Python空间”关注我丫加个“星标”,每天一起快乐的学习大家好,我是 Rocky0429,一个刚恰完午饭,正在用刷网页浪费生命的蒟蒻...一堆堆无聊八卦信息的网页内容慢慢使我的双眼模糊,一个哈欠打出了三斤老泪,就在此时我看到了一张图片:是谁!是谁把我女朋友的照片放出来的!awsl!太好看了叭...等等,那个背景上的一堆鬼画符是什么鬼?!真是看不下去!叔叔婶婶能忍,隔壁老王的三姨妈的四表...
为啥国人偏爱Mybatis,而老外喜欢Hibernate/JPA呢?
关于SQL和ORM的争论,永远都不会终止,我也一直在思考这个问题。昨天又跟群里的小伙伴进行了一番讨论,感触还是有一些,于是就有了今天这篇文。 声明:本文不会下关于Mybatis和JPA两个持久层框架哪个更好这样的结论。只是摆事实,讲道理,所以,请各位看官勿喷。 一、事件起因 关于Mybatis和JPA孰优孰劣的问题,争论已经很多年了。一直也没有结论,毕竟每个人的喜好和习惯是大不相同的。我也看
SQL-小白最佳入门sql查询一
不要偷偷的查询我的个人资料,即使你再喜欢我,也不要这样,真的不好;
项目中的if else太多了,该怎么重构?
介绍 最近跟着公司的大佬开发了一款IM系统,类似QQ和微信哈,就是聊天软件。我们有一部分业务逻辑是这样的 if (msgType = "文本") { // dosomething } else if(msgType = "图片") { // doshomething } else if(msgType = "视频") { // doshomething } else { // doshom...
致 Python 初学者
欢迎来到“Python进阶”专栏!来到这里的每一位同学,应该大致上学习了很多 Python 的基础知识,正在努力成长的过程中。在此期间,一定遇到了很多的困惑,对未来的学习方向感到迷茫。我非常理解你们所面临的处境。我从2007年开始接触 python 这门编程语言,从2009年开始单一使用 python 应对所有的开发工作,直至今天。回顾自己的学习过程,也曾经遇到过无数的困难,也曾经迷茫过、困惑过。开办这个专栏,正是为了帮助像我当年一样困惑的 Python 初学者走出困境、快速成长。希望我的经验能真正帮到你
“狗屁不通文章生成器”登顶GitHub热榜,分分钟写出万字形式主义大作
一、垃圾文字生成器介绍 最近在浏览GitHub的时候,发现了这样一个骨骼清奇的雷人项目,而且热度还特别高。 项目中文名:狗屁不通文章生成器 项目英文名:BullshitGenerator 根据作者的介绍,他是偶尔需要一些中文文字用于GUI开发时测试文本渲染,因此开发了这个废话生成器。但由于生成的废话实在是太过富于哲理,所以最近已经被小伙伴们给玩坏了。 他的文风可能是这样的: 你发现,...
程序员:我终于知道post和get的区别
是一个老生常谈的话题,然而随着不断的学习,对于以前的认识有很多误区,所以还是需要不断地总结的,学而时习之,不亦说乎
《程序人生》系列-这个程序员只用了20行代码就拿了冠军
你知道的越多,你不知道的越多 点赞再看,养成习惯GitHub上已经开源https://github.com/JavaFamily,有一线大厂面试点脑图,欢迎Star和完善 前言 这一期不算《吊打面试官》系列的,所有没前言我直接开始。 絮叨 本来应该是没有这期的,看过我上期的小伙伴应该是知道的嘛,双十一比较忙嘛,要值班又要去帮忙拍摄年会的视频素材,还得搞个程序员一天的Vlog,还要写BU...
相关热词 c#处理浮点数 c# 生成字母数字随机数 c# 动态曲线 控件 c# oracle 开发 c#选择字体大小的控件 c# usb 批量传输 c#10进制转8进制 c#转base64 c# 科学计算 c#下拉列表获取串口
立即提问